The exporter JavaScript global object. Provides access to the project export directory.
More...
|
| void | cleanExportDir () |
| | Removes all files from the project export directory. More...
|
| |
| String | getExportDir () |
| | Returns the path of the project export directory. More...
|
| |
| bool | exportToQuicktime (String &codecName, int startFrame, int lastFrame, bool withSound, int resX, int resY, String &dstPath, String &displayModule, bool generateThumbnail, int thumbnailFrame) |
| | Returns true if a scene was exported to a QuickTime in the specified directory. This method only supports the default quicktime export or the openH264 codec. For ProRes export, use the exporter.exportMovie function instead. More...
|
| |
| void | exportOGLToQuicktime (String &fileName, String &dstPath, int startFrame=-1, int lastFrame=-1, int resX=-1, int resY=-1) |
| | Export OGL frames to a QuickTime movie. Without QuickTime it will try to fallback to other supported formats. More...
|
| |
| void | exportMovie (QScriptValue ¶ms) |
| |
|
| QScriptValue | exportGIF (QScriptValue ¶ms) |
| | Render the scene and export an animated GIF from its rendering. More...
|
| |
| QScriptValue | exportToProRes (QScriptValue ¶ms) |
| | Render the scene and export a ProRes movie. More...
|
| |
The exporter JavaScript global object. Provides access to the project export directory.
The example below writes the palette list to a file.
var exportFile = exportDir + "paletteList.txt";
var logFile =
new File(exportFile);
logFile.writeLine("");
for (i = 0; i < numPalettes; ++i)
{
logFile.writeLine(paletteName);
}
◆ cleanExportDir
| void exporter::cleanExportDir |
( |
| ) |
|
|
slot |
Removes all files from the project export directory.
◆ exportGIF()
| QScriptValue exportGIF |
( |
QScriptValue & |
params | ) |
|
Render the scene and export an animated GIF from its rendering.
try
{
displayName : "",
startFame : 1,
stopFrame : 10,
resX : 1024,
resY : 554,
loop : true });
if(res)
else
MessageBox.information('The GIF export has failed);
exporter.
exportGIF({ fileName :
"C:/myPath/animated2.gif", stopFrame : 5, dith : 0 });
}
catch (err)
{
}
- Parameters
-
| params | : An export parameters object with following properties:
| Property | Type | Description |
| fileName | String | The complete file path to the generated animated GIF. |
| displayName | String | (Optional) The display node name. The default display is used if the property isn't specified or if it is an empty string. |
| startFrame | int | (Optional) The first frame to be exported. The first frame of the scene if the property isn't specified or if it is set to 0. |
| stopFrame | int | (Optional) The last frame to be exported. The last frame of the scene if the property isn't specified or if it is set to 0. |
| resX | int | (Optional) The horizontal pixel resolution. The x resolution of the scene if 0 or not specified. |
| resY | int | (Optional) The vertical pixel resolution. The y resolution of the scene if 0 or not specified. |
| dith | int | (Optional) The dithering to use. exporter.None if not specified. |
| loop | bool | (Optional) Set the animation to loop. true by default. |
|
| Dithering | Value |
| exporter.None | 0 |
| exporter.Diffusion | 1 |
| exporter.Pattern | 2 |
- Returns
- Returns true if a scene was exported as an animated GIF. Throw an error if there was an invalid dithering property.
◆ exportMovie
| void exporter::exportMovie |
( |
QScriptValue & |
params | ) |
|
|
slot |
Render the scene and export it using the codec passed in parameter.
var filename = scene.currentProjectPathRemapped() + "/frames/my-export.mov";
try
{
codec : "openH264",
startFrame: 1,
dstPath: filename,
resX: 1920,
resY: 1080
})
}
catch (err)
{
}
- Parameters
-
| params | : An export parameters object with following properties:
| Property | Type | Description |
| dstPath | String | The output file location. |
| startFrame | int | (Optional) The start range of playback, default value is the start of the playback toolbar, or if -1. |
| lastFrame | int | (Optional) The end range of playback, default value is the stop of the playback toolbar, or if -1. |
| withSound | bool | (Optional) Whether or not the movie will have sound, default value is true. |
| stereo | bool | (Optional) Whether or not the movie will have stereo sound, default value is true. Used only in prores codecs. |
| audioSampleRate | int | (Optional) The audio samples per second to be used, default value is 22050. Only used in prores codecs |
| codec | int,string | (Optional) The codec of the movie, default value is "" |
| withAlpha | bool | (Optional) Whether or not the movie will have alpha, default value is true (used only when codec supports an alpha channel). Only used in prores codecs |
| resX | int | (Optional) The horizontal resolution, default value the preview resolution, or if -1. |
| resY | int | (Optional) The vertical resolution default value is the preview resolution, or if -1. |
| displayModule | String | (Optional) The display module, default is empty string. |
| thumbnail | bool | (Optional) Generate a thumbnail. Not available for prores. |
| thumbnailFrame | int | (Optional) Which frame to use as thumbnail. Not available for prores. |
|
| Codecs | Value | Description |
| "" | "" | Apple Quicktime |
| "openH264" | "openH264" | Open H264 codec |
| exporter.prores422 | 0 | Apple ProRes 422 |
| exporter.prores422HQ | 1 | Apple ProRes 422 HQ |
| exporter.prores422LT | 2 | Apple ProRes 422 LT |
| exporter.prores422Proxy | 3 | Apple ProRes 422 Proxy |
| exporter.prores4444 | 4 | Apple ProRes 4444 |
| exporter.prores4444XQ | 5 | Apple ProRes 4444 XQ |
◆ exportOGLToQuicktime
| void exporter::exportOGLToQuicktime |
( |
String & |
fileName, |
|
|
String & |
dstPath, |
|
|
int |
startFrame = -1, |
|
|
int |
lastFrame = -1, |
|
|
int |
resX = -1, |
|
|
int |
resY = -1 |
|
) |
| |
|
slot |
Export OGL frames to a QuickTime movie. Without QuickTime it will try to fallback to other supported formats.
- Parameters
-
| fileName | : The output file name. |
| dstPath | : The output file location. |
| startFrame | : The start range of playback, default to playback toolbar start if -1. |
| lastFrame | : The end range of playback, default to playback toolbar stop if -1. |
| resX | : The horizontal resolution, default to preview resolution if -1. |
| resY | : The vertical resolution default to preview resolution if -1. |
◆ exportToProRes()
| QScriptValue exportToProRes |
( |
QScriptValue & |
params | ) |
|
Render the scene and export a ProRes movie.
try
{
if (res)
else
startFrame : 1,
withSound : true,
stereo : true,
audioSampleRate : 22050,
withAlpha : true,
}
catch (err)
{
}
- Parameters
-
| params | : An export parameters object with following properties:
| Property | Type | Description |
| dstPath | String | The output file location. |
| startFrame | int | (Optional) The start range of playback, default value is the start of the playback toolbar, or if -1. |
| lastFrame | int | (Optional) The end range of playback, default value is the stop of the playback toolbar, or if -1. |
| withSound | bool | (Optional) Whether or not the movie will have sound, default value is true. |
| stereo | bool | (Optional) Whether or not the movie will have stereo sound, default value is true. |
| audioSampleRate | int | (Optional) The audio samples per second to be used, default value is 22050. |
| codec | int | (Optional) The codec of the movie, default value is exporter.prores4444 |
| withAlpha | bool | (Optional) Whether or not the movie will have alpha, default value is true (used only when codec supports an alpha channel). |
| resX | int | (Optional) The horizontal resolution, default value the preview resolution, or if -1. |
| resY | int | (Optional) The vertical resolution default value is the preview resolution, or if -1. |
| displayModule | String | (Optional) The display module, default is empty string. |
|
| Codecs | Value | Description |
| exporter.prores422 | 0 | Apple ProRes 422 |
| exporter.prores422HQ | 1 | Apple ProRes 422 HQ |
| exporter.prores422LT | 2 | Apple ProRes 422 LT |
| exporter.prores422Proxy | 3 | Apple ProRes 422 Proxy |
| exporter.prores4444 | 4 | Apple ProRes 4444 |
| exporter.prores4444XQ | 5 | Apple ProRes 4444 XQ |
- Returns
- Returns true if a scene was successfully exported to a ProRes movie file in the specified directory.
◆ exportToQuicktime
| bool exporter::exportToQuicktime |
( |
String & |
codecName, |
|
|
int |
startFrame, |
|
|
int |
lastFrame, |
|
|
bool |
withSound, |
|
|
int |
resX, |
|
|
int |
resY, |
|
|
String & |
dstPath, |
|
|
String & |
displayModule, |
|
|
bool |
generateThumbnail, |
|
|
int |
thumbnailFrame |
|
) |
| |
|
slot |
Returns true if a scene was exported to a QuickTime in the specified directory. This method only supports the default quicktime export or the openH264 codec. For ProRes export, use the exporter.exportMovie function instead.
- Parameters
-
| codecName | : The codec to use. If the value is "openH264", the openH264 codec will be used. Any other value will use the Quicktime format. |
| startFrame | : The start range of playback, default to playback toolbar start if -1. |
| lastFrame | : The end range of playback, default to playback toolbar stop if -1. |
| withSound | : Whether or not the movie will have sound. |
| resX | : The horizontal resolution, default to preview resolution if -1. |
| resY | : The vertical resolution default to preview resolution if -1. |
| dstPath | : The output file location. |
| displayModule | : The display module. |
| generateThumbnail | : Whether or not to generate a thumbnail for the QuickTime. |
| thumbnailFrame | : The frame to use for the thumbnail. |
- Returns
- Returns true if a scene was exported to a QuickTime in the specified directory.
◆ getExportDir
| String exporter::getExportDir |
( |
| ) |
|
|
slot |
Returns the path of the project export directory.
- Returns
- Returns the path of the project export directory.