This function can be used to set the position of the sun for hill shading on 2D maps. The sun is the light source used for hill shading. This does not apply to aerial maps (FS_MAP_VIEW_MODE_AERIAL).

Syntax
bool fsMapViewSetMapHillShadeSunPosition(
    FsContext ctx,
    FsTextureId id,
    float fAzimuth,
    float fElevation
);
Members
ParametersDescription
ctxA value of type FsContext provided as an argument of the gauge callback.
idThe MapView render ID as returned by the function fsMapViewCreate.
fAzimuthThe azimuth of the sun, in degrees measured clockwise from true north. Defaults to 315 degrees (northwest) on map creation.
fElevationThe elevation of the sun, in degrees above the horizon. Defaults to 45 degrees on map creation.
Return Values

Returns false if:

  • no texture matches the given MapView ID
  • the ctx is invalid

Otherwise it will return true.

Remarks

N/A

0/255