WLJS LogoWLJS Notebook

Rasterize

Wolfram Kernel
Rasterize[expression_, opts___]

rasterizes any expression into an Image using frontend as it is rendered in a cell.

Requires Desktop App for rasterizing (no available in server mode). It literally takes a screenshot of a specific area.

Blocking function. Avoid using it in timers like SetTimeout, external event handlers such as InputButton or Button, or within AsyncFunction. Use RasterizeAsync instead.

Options

"Window"

By the default it uses CurrentWindow.

"ExposureTime"

Sets the time in seconds for possible async processes to settle down on displayed expression before the rasterization. By the default is 1.

"ImageUpscaling"

Upscales the render canvas by _Integer times. Default value is 1 (no upscaling, it renders as it is)

Application

Can be used to export graphics to raster format try

Rasterize[x+y]

And then you can freely export it to an image file

Export["image.png", %]

On this page