Interface: TakeScreenshotOptions
Captures the current configuration from a separate camera. Invalid options reject the promise with a TypeError. An unavailable capture resolves to null.
Example
await window.mimeeqApp.utils.takeScreenshot({
format: 'png',
size: { width: 1600, height: 800 },
camera: { position: [0, 10, 0.001], target: [0, 0, 0] },
projection: 'orthographic',
fit: { occupancy: 0.85 },
});
Properties
background?
optionalbackground?:string
Background color, such as '#ebebeb'. A white PNG background renders transparent.
Example
await window.mimeeqApp.utils.takeScreenshot({ background: '#ebebeb' });
camera?
optionalcamera?:ScreenshotCamera
Viewpoint to apply to the screenshot camera. Omit to use the current view angle.
Example
await window.mimeeqApp.utils.takeScreenshot({ camera: { alpha: 1, beta: 0.5, radius: 6 } });
fit?
optionalfit?:boolean| {occupancy?:number; }
Fit visible product content while keeping the viewing angle. Occupancy is in (0, 1].
Example
await window.mimeeqApp.utils.takeScreenshot({ fit: { occupancy: 0.8 } });
format?
optionalformat?:"png"|"jpg"|"jpeg"
Image format. Defaults to PNG.
Example
await window.mimeeqApp.utils.takeScreenshot({ format: 'jpg' });
orthoExtents?
optionalorthoExtents?:ScreenshotOrthoExtents
Set the orthographic bounds directly. Use with orthographic projection and fit disabled.
Example
await window.mimeeqApp.utils.takeScreenshot({
projection: 'orthographic',
orthoExtents: { left: -4, right: 4, bottom: -2, top: 2 },
});
projection?
optionalprojection?:CameraProjectionMode
Projection of the screenshot camera. Defaults to perspective.
Example
await window.mimeeqApp.utils.takeScreenshot({ projection: 'orthographic' });
returnProjection?
optionalreturnProjection?:boolean
Include projection data alongside the image. Defaults to false.
Example
await window.mimeeqApp.utils.takeScreenshot({ returnProjection: true });
size?
optionalsize?:Dimensions
Positive integer pixel dimensions. Omit to use the standard screenshot size.
Example
await window.mimeeqApp.utils.takeScreenshot({ size: { width: 1600, height: 800 } });
withDimensions?
optionalwithDimensions?:boolean
Include the product dimension overlay. Defaults to false.
Example
await window.mimeeqApp.utils.takeScreenshot({ withDimensions: true });