On this page
fsMapViewSetWeatherRadarColorAlphaEnabled
This function can be used to enable the use of alpha channel values for rain rate colors set by fsMapViewSetWeatherRadarRainColors. Applies to weather radar maps in the horizontal (FS_MAP_VIEW_WEATHER_RADAR_MODE_HORIZONTAL) and vertical (FS_MAP_VIEW_WEATHER_RADAR_MODE_VERTICAL) mode. By default, this is disabled and alpha values are ignored (set to 1). For alpha blending information, see Remarks.
Syntax
bool fsMapViewSetWeatherRadarColorAlphaEnabled(
FsContext ctx,
FsTextureId id,
bool bEnabled
);Members
| Parameters | Description |
|---|---|
ctx | A value of type FsContext provided as an argument of the gauge callback. |
id | The MapView render ID as returned by the function fsMapViewCreate. |
bEnabled | Whether the alpha channel should be enabled or not. |
Return Values
Returns false if:
- no texture matches the given MapView ID
- the
ctxis invalid
Otherwise it will return true.
Remarks
In order to get correct alpha blending (for rain rate colors with alpha values different than 0 and 1), the map view must be created with the FS_RENDER_IMAGE_PREMULTIPLIED image flag.
