fsMapViewCreate

This function can be used to create an initial MapView for later user. Note that there is a limit to how many MapView objects you can create, and you can only have up to nine at any one time. Trying to create more than that will cause issues.

 

Syntax
FsTextureId fsMapViewCreate(
    FsContext ctx,
    unsigned uSizeX,
    unsigned uSizeY,
    FsRenderImageFlags iRenderImageFlags
    )

 

Members
Parameters Description
ctx A value of type FsContext provided as an argument of the gauge callback.
uSizeX Sets the default width. See fsMapViewSetSize for more information.
uSizeY Sets the default height. See fsMapViewSetSize for more information.
iRenderImageFlags Permits you to use specific render flags to change how the image is rendered. See the Remarks below for details.

 

 

Return Values

Returns the MapView ID which must be used to identify a MapView if further function calls. If the MapView creation fails, the function will return a value <0.

 

 

Remarks

When using this function you can set 1 or more render flags for the iRenderImageFlags parameter. These can be bitwise OR'd together to create a bitmask that will be used when rendering, for example:

FS_RENDER_IMAGE_REPEATX | FS_RENDER_IMAGE_FLIPY

The available flags are as follows:

Flags Description
FS_RENDER_IMAGE_REPEATX The image should be repeated along the X axis.
FS_RENDER_IMAGE_REPEATY The image should be repeated along the Y axis.
FS_RENDER_IMAGE_FLIPY The image should be flipped along the Y axis.
FS_RENDER_IMAGE_PREMULTIPLIED The image should be considered as having pre-multiplied alpha.
FS_RENDER_IMAGE_NEAREST The image should be rendered using "nearest neighbour" interpolation instead of the default bilinear interpolation (thus giving a more pixelated effect).

 

 

See Also