cesium-native  0.41.0
CesiumRasterOverlays::RasterOverlayOptions Struct Reference

Options for loading raster overlays. More...

#include <CesiumRasterOverlays/RasterOverlay.h>

Public Attributes

int32_t maximumSimultaneousTileLoads = 20
 The maximum number of overlay tiles that may simultaneously be in the process of loading.
 
int64_t subTileCacheBytes = 16 * 1024 * 1024
 The maximum number of bytes to use to cache sub-tiles in memory. More...
 
int32_t maximumTextureSize = 2048
 The maximum pixel size of raster overlay textures, in either direction. More...
 
double maximumScreenSpaceError = 2.0
 The maximum number of pixels of error when rendering this overlay. This is used to select an appropriate level-of-detail. More...
 
CesiumGltf::Ktx2TranscodeTargets ktx2TranscodeTargets
 For each possible input transmission format, this struct names the ideal target gpu-compressed pixel format to transcode to.
 
std::function< void(const RasterOverlayLoadFailureDetails &)> loadErrorCallback
 A callback function that is invoked when a raster overlay resource fails to load. More...
 
bool showCreditsOnScreen = false
 Whether or not to display the credits on screen.
 
std::any rendererOptions
 Arbitrary data that will be passed to prepareRasterInLoadThread, for example, data to control the per-raster overlay client-specific texture properties. More...
 
std::optional< CesiumGeospatial::Ellipsoidellipsoid = std::nullopt
 The ellipsoid used for this raster overlay.
 

Detailed Description

Options for loading raster overlays.

Definition at line 35 of file RasterOverlay.h.

Member Data Documentation

◆ loadErrorCallback

std::function<void(const RasterOverlayLoadFailureDetails&)> CesiumRasterOverlays::RasterOverlayOptions::loadErrorCallback

A callback function that is invoked when a raster overlay resource fails to load.

Raster overlay resources include a Cesium ion asset endpoint or any resources required for raster overlay metadata.

This callback is invoked by the RasterOverlayCollection when an error occurs while it is creating a tile provider for this RasterOverlay. It is always invoked in the main thread.

Definition at line 95 of file RasterOverlay.h.

◆ maximumScreenSpaceError

double CesiumRasterOverlays::RasterOverlayOptions::maximumScreenSpaceError = 2.0

The maximum number of pixels of error when rendering this overlay. This is used to select an appropriate level-of-detail.

When this property has its default value, 2.0, it means that raster overlay images will be sized so that, when zoomed in closest, a single pixel in the raster overlay maps to approximately 2x2 pixels on the screen.

Definition at line 76 of file RasterOverlay.h.

◆ maximumTextureSize

int32_t CesiumRasterOverlays::RasterOverlayOptions::maximumTextureSize = 2048

The maximum pixel size of raster overlay textures, in either direction.

Images created by this overlay will be no more than this number of pixels in either direction. This may result in reduced raster overlay detail in some cases. For example, in a QuadtreeRasterOverlayTileProvider, this property will limit the number of quadtree tiles that may be mapped to a given geometry tile. The selected quadtree level for a geometry tile is reduced in order to stay under this limit.

Definition at line 66 of file RasterOverlay.h.

◆ rendererOptions

std::any CesiumRasterOverlays::RasterOverlayOptions::rendererOptions

Arbitrary data that will be passed to prepareRasterInLoadThread, for example, data to control the per-raster overlay client-specific texture properties.

This object is copied and given to background texture preparation threads, so it must be inexpensive to copy.

Definition at line 110 of file RasterOverlay.h.

◆ subTileCacheBytes

int64_t CesiumRasterOverlays::RasterOverlayOptions::subTileCacheBytes = 16 * 1024 * 1024

The maximum number of bytes to use to cache sub-tiles in memory.

This is used by provider types, such as QuadtreeRasterOverlayTileProvider, that have an underlying tiling scheme that may not align with the tiling scheme of the geometry tiles on which the raster overlay tiles are draped. Because a single sub-tile may overlap multiple geometry tiles, it is useful to cache loaded sub-tiles in memory in case they're needed again soon. This property controls the maximum size of that cache.

Definition at line 53 of file RasterOverlay.h.


The documentation for this struct was generated from the following file: