TalanSoft Toolkits  201707
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Groups Pages
List of all members
iImageMap Struct Referenceabstract
Inheritance diagram for iImageMap:
iUnknown

Detailed Description

Image map interface.

Pages

virtual void SetMaxNumPages (tU32 anMax)=0
 Set the maximum number of pages. {Property}. More...
 
virtual tU32 GetMaxNumPages () const =0
 Get the maximum number of pages. {Property}. More...
 
virtual void SetPageSize (tU32 anSize)=0
 Set the resolution of a page. More...
 
virtual tU32 GetPageSize () const =0
 Get the resolution of a page. {Property}. More...
 
virtual void SetPageMipMaps (tU32 anNumMipMaps)=0
 Set the number of mipmaps of a page. {Property}. More...
 
virtual tU32 GetPageMipMaps () const =0
 Get the number of mipmaps of a page. {Property}. More...
 
virtual void SetComputeMipMapsPerPage (tBool abComputeMipMapsPerPage)=0
 Set whether the mipmaps are computed for the whole page after an image has been added. That is regardless of whether the image added had mipmap itself. More...
 
virtual tBool GetComputeMipMapsPerPage () const =0
 Get whether the mipmaps are computed for the whole page after an image has been added. {Property}. More...
 
virtual void SetPageFormat (iHString *ahspFormat)=0
 Set the page format. {Property}. More...
 
virtual iHStringGetPageFormat () const =0
 Get the page format. {Property}. More...
 
virtual tU32 GetNumPages () const =0
 Get the number of pages in the image map. {Property}. More...
 
virtual iTextureGetPage (tU32 anIndex) const =0
 Get the specified page in the image map. {Property}. More...
 

Map

virtual void Clear ()=0
 Clear the image map. More...
 
virtual void SetDefaultImageBlendMode (eBlendMode aMode)=0
 Set the default blend mode. {Property}. More...
 
virtual eBlendMode GetDefaultImageBlendMode () const =0
 Get the default blend mode. {Property}. More...
 
virtual void SetDefaultImageFilter (tBool abFiltering)=0
 Set the default filtering. {Property}. More...
 
virtual tBool GetDefaultImageFilter () const =0
 Get the default filtering. {Property}. More...
 
virtual tU32 GetNumImages () const =0
 Get the number of images. {Property}. More...
 
virtual iOverlayGetImage (tU32 anIndex) const =0
 Get the image at the specified index. {Property}. More...
 
virtual tU32 GetImageIndex (iOverlay *apImage) const =0
 Get the index of the image at the specified index. {Property}. More...
 
virtual iOverlayGetImageFromName (iHString *ahspName) const =0
 Get the first image with the given name. {Property}. More...
 
virtual iOverlayAddImage (iHString *ahspName, iBitmap2D *apBitmap)=0
 Add an image to the image map. More...
 
virtual iOverlayAddImageFromResource (iHString *ahspName, iHString *ahspRes)=0
 Add an image to the image map loading from a resource. More...
 
virtual iOverlayAddImageFromIconSet (iHString *ahspName, iHString *ahspFolder, iHString *ahspRes, tU32 anMaxRes, tU32 anMinRes)=0
 Add an image to the image map loading from a icon set folder. More...
 
virtual tBool RemoveImage (iOverlay *apImage)=0
 Remove an image from the image map. More...
 

Serialize

virtual tBool GetShouldSerialize () const =0
 Get whether the image map has been modified since the last serialize read. {Property}. More...
 
virtual tBool Serialize (ni::iFile *apFile, tImageMapSerializeFlags aFlags)=0
 Serialize the image map to/from the specified file. More...
 

Additional Inherited Members

- Public Member Functions inherited from iUnknown
virtual tBool IsOK () const =0
 Check if the object is valid. More...
 
virtual tI32 AddRef ()=0
 Signal that one more reference of the object has been created. More...
 
virtual tI32 Release ()=0
 Release a reference of the object. More...
 
virtual void DeleteThis ()=0
 Bypass any reference counting and delete this object. More...
 
virtual void Invalidate ()=0
 Invalidate the object. More...
 
virtual iUnknownQueryInterface (const tUUID &aIID)=0
 Query an interface. More...
 
virtual void ListInterfaces (iMutableCollection *apLst, tU32 anFlags) const =0
 Fill a UUID list containing the UUIDs of the implemented interfaces. More...
 
virtual tI32 SetNumRefs (tI32 anNumRefs)=0
 Set the reference counter directly. More...
 
virtual tI32 GetNumRefs () const =0
 Get the number of references to this object. More...
 

Member Function Documentation

virtual void SetMaxNumPages ( tU32  anMax)
pure virtual

Set the maximum number of pages. {Property}.

Remarks
Zero, the default value, means no limit.
virtual tU32 GetMaxNumPages ( ) const
pure virtual

Get the maximum number of pages. {Property}.

virtual void SetPageSize ( tU32  anSize)
pure virtual

Set the resolution of a page.

Remarks
Default is 1024 or the maximum texture size on the current hardware. {Property}
virtual tU32 GetPageSize ( ) const
pure virtual

Get the resolution of a page. {Property}.

virtual void SetPageMipMaps ( tU32  anNumMipMaps)
pure virtual

Set the number of mipmaps of a page. {Property}.

Remarks
Reset by set page size if the number of mipmaps is != 0 (the default)
virtual tU32 GetPageMipMaps ( ) const
pure virtual

Get the number of mipmaps of a page. {Property}.

virtual void SetComputeMipMapsPerPage ( tBool  abComputeMipMapsPerPage)
pure virtual

Set whether the mipmaps are computed for the whole page after an image has been added. That is regardless of whether the image added had mipmap itself.

Remarks
Default is eFalse. {Property}
virtual tBool GetComputeMipMapsPerPage ( ) const
pure virtual

Get whether the mipmaps are computed for the whole page after an image has been added. {Property}.

virtual void SetPageFormat ( iHString ahspFormat)
pure virtual

Set the page format. {Property}.

Remarks
The default is R8G8B8A8
virtual iHString* GetPageFormat ( ) const
pure virtual

Get the page format. {Property}.

virtual tU32 GetNumPages ( ) const
pure virtual

Get the number of pages in the image map. {Property}.

virtual iTexture* GetPage ( tU32  anIndex) const
pure virtual

Get the specified page in the image map. {Property}.

virtual void Clear ( )
pure virtual

Clear the image map.

virtual void SetDefaultImageBlendMode ( eBlendMode  aMode)
pure virtual

Set the default blend mode. {Property}.

virtual eBlendMode GetDefaultImageBlendMode ( ) const
pure virtual

Get the default blend mode. {Property}.

virtual void SetDefaultImageFilter ( tBool  abFiltering)
pure virtual

Set the default filtering. {Property}.

virtual tBool GetDefaultImageFilter ( ) const
pure virtual

Get the default filtering. {Property}.

virtual tU32 GetNumImages ( ) const
pure virtual

Get the number of images. {Property}.

virtual iOverlay* GetImage ( tU32  anIndex) const
pure virtual

Get the image at the specified index. {Property}.

virtual tU32 GetImageIndex ( iOverlay apImage) const
pure virtual

Get the index of the image at the specified index. {Property}.

virtual iOverlay* GetImageFromName ( iHString ahspName) const
pure virtual

Get the first image with the given name. {Property}.

virtual iOverlay* AddImage ( iHString ahspName,
iBitmap2D apBitmap 
)
pure virtual

Add an image to the image map.

Returns
An new image packed in the image map, if failed returns NULL.
Remarks
The returned overlay is owned by the image map, when the image map is released or invalidated the overlay will be invalidated.
virtual iOverlay* AddImageFromResource ( iHString ahspName,
iHString ahspRes 
)
pure virtual

Add an image to the image map loading from a resource.

Parameters
ahspNameis the name of the image, if the name isnt not specified the resource path is used as name.
ahspResis the path of the resource.
Returns
An new image packed in the image map, if failed returns NULL.
Remarks
The returned overlay is owned by the image map, when the image map is released or invalidated the overlay will be invalidated.
virtual iOverlay* AddImageFromIconSet ( iHString ahspName,
iHString ahspFolder,
iHString ahspRes,
tU32  anMaxRes,
tU32  anMinRes 
)
pure virtual

Add an image to the image map loading from a icon set folder.

Parameters
ahspNameis the name of the image, if the name isnt not specified the resource path is used as name.
ahspFolderis the base folder name.
ahspResis the path of the resource.
anMaxResis the maximum icon resolution to use.
anMinResis the minimum icon resolution to use.
Returns
An new image packed in the image map, if failed returns NULL.
Remarks
The returned overlay is owned by the image map, when the image map is released or invalidated the overlay will be invalidated.
This method will try to load all mip map levels from several folders, up to maxres down to minres, missing versions will be generated automatically.
The path for the images is folder/[res]x[res]/res
virtual tBool RemoveImage ( iOverlay apImage)
pure virtual

Remove an image from the image map.

Remarks
Removing an image will invalidate the overlay and repack the cache, this operation should be considered slow.
virtual tBool GetShouldSerialize ( ) const
pure virtual

Get whether the image map has been modified since the last serialize read. {Property}.

virtual tBool Serialize ( ni::iFile apFile,
tImageMapSerializeFlags  aFlags 
)
pure virtual

Serialize the image map to/from the specified file.