Method ExportImageFromScript
ExportImageFromScript(string, string, HandingType, double, double, double, double, double, double, AltitudeType, double, bool, bool, ViewMode, string, int, int, string, bool, int, int)
Exports an image representing a block created from a given script.
Declaration
public void ExportImageFromScript(string catalogFilename, string script, Scene.Object.HandingType handingType, double dimensionX, double dimensionY, double dimensionZ, double positionX, double positionY, double altitude, Scene.Object.AltitudeType altitudeType, double oxyAngle, bool opened, bool zoomAdjusted, Scene.ViewMode viewMode, string imageFilename, int imageWidth, int imageHeight, string backgroundColor = "255,255,255", bool transparent = true, int jpegQuality = 80, int antialiasing = 1)
Parameters
Type | Name | Description |
---|---|---|
string | catalogFilename | Filename of the catalog which contains the item. |
string | script | Script that defines the block. |
Scene.Object.HandingType | handingType | Handing of the block. |
double | dimensionX | Width of the block, in the scene measurement units. |
double | dimensionY | Depth of the block, in the scene measurement units. |
double | dimensionZ | Height of the block, in the scene measurement units. |
double | positionX | Position (on the X axis) of the block in the scene, in scene measurement units. |
double | positionY | Position (on the Y axis) of the block in the scene, in scene measurement units. |
double | altitude | Altitude (position on the Z axis) of the block in the scene, in scene measurement units. |
Scene.Object.AltitudeType | altitudeType | Specifies how the given altitude should be treated. |
double | oxyAngle | Specifies the rotation angle of the object in the horizontal plane, in degrees. |
bool | opened | Indicates whether the block should be represented in its open visual state. |
bool | zoomAdjusted | Indicates whether the zoom should be adjusted before the generation of the image. See ZoomAdjusted() for details on how the zoom is adjusted. |
Scene.ViewMode | viewMode | Specifies which view mode to use for the image generation. |
string | imageFilename | Filename of the file to create. |
int | imageWidth | |
int | imageHeight | |
string | backgroundColor | |
bool | transparent | |
int | jpegQuality | |
int | antialiasing |
Remarks
See ExportImage(string, int, int, bool, string, int, int) for details on the rest of parameters.
This method is similar to the ExportCatalogImageFromScript(string, string, HandingType, double, double, double, bool, ViewMode, string, int, int, string, bool, int, int) except that it uses the current scene and not an empty scene created for the image generation purpose. This way, prior to launching of this function, it is be possible to load a scene already containing objects (we call such that scene a studio scene) so that the object resulting from the script appears in some environment and not alone.