KitchenDraw SDK 2
Show / Hide Table of Contents

Method ExportImageForObjects

ExportImageForObjects(IEnumerable<Object>, ViewMode, string, int, int, IEnumerable<Object>, bool, bool, bool, string, int, int)

Exports an image containing objects from the given list. Camera position is calculated automatically. One of the object's may be darkened - this allows to emphasize it on the exported image.

Declaration
public void ExportImageForObjects(IEnumerable<Scene.Object> objects, Scene.ViewMode viewMode, string filename, int imageWidth, int imageHeight, IEnumerable<Scene.Object> darkenedObjects = null, bool includeComponents = true, bool includeHostedObjects = true, bool transparent = true, string backgroundColor = "255,255,255", int jpegQuality = 80, int antialiasing = 1)
Parameters
Type Name Description
IEnumerable<Scene.Object> objects

Objects that should be shown on the image

Scene.ViewMode viewMode

Render mode for the image

string filename

Output image filename

int imageWidth

Output image width in pixels

int imageHeight

Output image height in pixels

IEnumerable<Scene.Object> darkenedObjects

Objects to be rendered darkened. May be null.

bool includeComponents

Also export components of the objects from the list.

bool includeHostedObjects

Also export objects hosted by the objects from the list.

bool transparent

Whether the background of the output image should be transparent or not.

string backgroundColor

Background color as string, in the "R,G,B" format.

int jpegQuality

JPEG quality (for JPEG images), 0 is the worst quality, 100 is the best.

int antialiasing

Antialiasing level. 0 means no antialiasing, 3 means best.

In this article
Back to top Generated by DocFX