Viewport size is an important factor in testing the performance of CesiumJS. But most of our performance testing is done in Sandcastle (as recommended by the Performance Testing Guide), where we do not have precise control over the viewport size.
Viewport size affects performance in two significant ways:
Larger viewports will require more tiles to be loaded. This can be significant for high-density building and photogrammetry tilesets.
Larger viewports place more of a burden on the fragment shader. This is significant for rendering atmosphere and voxels.
The current Sandcastle displays a dynamic viewport, which will be resized based on various factors:
User screen size
User adjustments to the width of the code window
Whether developer tools are open
If we allow the user to set a fixed viewport size in a Sandcastle, performance-related issues will become more reproducible and testable.
We already have a "View As Thumbnail" option which sets a fixed small viewport. This could potentially be extended to allow custom sizes, BUT
Sandcastle may not be the best place for robust performance testing, because of the extra weight of Sandcastle itself. A simple HTML page with a minimal viewer might give more meaningful numbers.
Viewport size is an important factor in testing the performance of CesiumJS. But most of our performance testing is done in Sandcastle (as recommended by the Performance Testing Guide), where we do not have precise control over the viewport size.
Viewport size affects performance in two significant ways:
The current Sandcastle displays a dynamic viewport, which will be resized based on various factors:
If we allow the user to set a fixed viewport size in a Sandcastle, performance-related issues will become more reproducible and testable.