Corona Standalone
XML Scene (.scn) format
SCN files are the main Corona scene descriptors. They include other files with geometry/materials/configuration, define camera, geometry, render elements, and more. The document root element must be of type “scene”. All element and attribute names are case-insensitive.
Last updated 13 January 2026
Overview
SCN files are the main Corona scene descriptors. They include other files with geometry/materials/configuration, define camera, geometry, render elements, and more. The document root element must be of type “scene”. All element and attribute names are case-insensitive.
Camera definition is only required node. Everything else is optional and will stay at defaults if not defined. The basic syntax is:
<code><span class="line"><span><scene></span></span>
<span class="line"><span> <camera class="[string]">...</camera></span></span>
<span class="line"><span> *<confFile>[filename]</confFile></span></span>
<span class="line"><span> *<mtlLib>[filename]</mtlLib></span></span>
<span class="line"><span> ?<sun>...</sun></span></span>
<span class="line"><span> ?<environment>[map]|[RGB]</environment></span></span>
<span class="line"><span> ?<globalMedium>[string]</globalMedium> </span></span>
<span class="line"><span> *<geometryGroup>...</geometryGroup></span></span>
<span class="line"><span> *<renderElement>...</renderElement></span></span>
<span class="line"><span> ?<renderSelected>...</renderSelected> </span></span>
<span class="line"><span></scene></span></span></code>
Camera definition
- If the camera is animated, all values must be animated, and have the same number of steps.
- Different camera parameters are available, based on the camera class:
<code><span class="line"><span><camera class="[string]">...</camera></span></span></code>
Perspective camera
- FOV is always horizontal FOV specified in degrees.
- There are 3 different ways to define the basic geometry of the camera:
First option is to use origin and target points together with the “roll” vector (a vector pointing upwards - usually 0 0 1 for Z-up or 0 1 0 for Y-up) that rotates the camera around the origin-target axis:
<code><span class="line"><span><camera class="perspective"></span></span>
<span class="line"><span> <origin>[XYZ]|[animXYZ]</origin></span></span>
<span class="line"><span> <target>[XYZ]|[animXYZ]</target></span></span>
<span class="line"><span> <roll>[XYZ]|[animXYZ]</roll></span></span>
<span class="line"><span> <fov>[float]</fov></span></span>
<span class="line"><span></camera></span></span></code>
Second option is to input the camera transformation matrix directly. The matrix transforms from the world space to the camera space. The camera is centered arount point 0 0 0 in the camera space space, looking in the negative Z axis with Y axis being roll:
Note: this method does not work in current version (15.03.2018), but will be re-introduced.
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><camera class="perspective"></span><span data-v-c2b1f83f="" class="line"> <transform>[TM]|[animTM]</transform></span><span data-v-c2b1f83f="" class="line"> <fov>[float]</fov></span><span data-v-c2b1f83f="" class="line"></camera></span></code>
Last option is to specify origin and target points together with xVect and yVect vectors. Those specify the translation in the camera plane in the image x and y direction. This allows creating tilt-shift camera effects:
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><camera class="perspective"></span><span data-v-c2b1f83f="" class="line"> <origin>[XYZ]|[animXYZ]</origin></span><span data-v-c2b1f83f="" class="line"> <target>[XYZ]|[animXYZ]</target></span><span data-v-c2b1f83f="" class="line"> <xVect>[XYZ]|[animXYZ]</xVect></span><span data-v-c2b1f83f="" class="line"> <yVect>[XYZ]|[animXYZ]</yVect></span><span data-v-c2b1f83f="" class="line"> <fov>float</fov></span><span data-v-c2b1f83f="" class="line"></camera> </span></code>
There are also other, optional parameters:
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line">?<filmWidth>[float]</filmWidth></span><span data-v-c2b1f83f="" class="line">?<focalDist>[float]</focalDist></span><span data-v-c2b1f83f="" class="line">?<fstop>[float]</fstop></span><span data-v-c2b1f83f="" class="line">?<bokehPolygonal></span><span data-v-c2b1f83f="" class="line"> <blades>[int]</blades></span><span data-v-c2b1f83f="" class="line"> <rotation>[float]</rotation></span><span data-v-c2b1f83f="" class="line"></bokehPolygonal></span></code>
- Specifying fStop, focalDist, filmWidth, or bokehPolygonal enables the depth of field effect.
Corona 2+
Since Corona 2, it is also possible to specify:
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line">?<focalLengthForDof>[float]</focalLengthForDof></span><span data-v-c2b1f83f="" class="line">?<lens></span><span data-v-c2b1f83f="" class="line"> <centerBias>[float]</centerBias></span><span data-v-c2b1f83f="" class="line"> <vignetting>[float]</vignetting></span><span data-v-c2b1f83f="" class="line"> <anamorphic>[float]</anamorphic></span><span data-v-c2b1f83f="" class="line"></lens></span><span data-v-c2b1f83f="" class="line">?<lensDistortion></span><span data-v-c2b1f83f="" class="line"> <cubicAmount>[float]</cubicAmount></span><span data-v-c2b1f83f="" class="line"></lensDistortion></span></code>
- The valid range of centerBias is [-5, 5], for vignetting it is [-3, 3] and for anamorphic (-1, 1).
Ortho camera
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><camera class="ortho"></span><span data-v-c2b1f83f="" class="line">either:</span><span data-v-c2b1f83f="" class="line"> <origin>[XYZ]|[animXYZ]</origin></span><span data-v-c2b1f83f="" class="line"> <target>[XYZ]|[animXYZ]</target></span><span data-v-c2b1f83f="" class="line"> <roll>[XYZ]|[animXYZ]</roll></span><span data-v-c2b1f83f="" class="line"> </span><span data-v-c2b1f83f="" class="line">or:</span><span data-v-c2b1f83f="" class="line"> <transform>[TM]|[animTM]</transform></span><span data-v-c2b1f83f="" class="line"> <width>[float]</width></span><span data-v-c2b1f83f="" class="line"></camera></span></code>
Spherical camera
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><camera class="spherical"></span><span data-v-c2b1f83f="" class="line"> <origin>[XYZ]|[animXYZ]</origin></span><span data-v-c2b1f83f="" class="line"> <target>[XYZ]|[animXYZ]</target></span><span data-v-c2b1f83f="" class="line"> <roll>[XYZ]|[animXYZ]</roll></span><span data-v-c2b1f83f="" class="line"></camera></span></code>
Cylindrical camera
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><camera class="cylindrical"></span><span data-v-c2b1f83f="" class="line"> <origin>[XYZ]|[animXYZ]</origin></span><span data-v-c2b1f83f="" class="line"> <target>[XYZ]|[animXYZ]</target></span><span data-v-c2b1f83f="" class="line"> <roll>[XYZ]|[animXYZ]</roll></span><span data-v-c2b1f83f="" class="line"> <height>[float]</height></span><span data-v-c2b1f83f="" class="line"></camera></span></code>
Cube map camera
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><camera class="cubemap"></span><span data-v-c2b1f83f="" class="line"> <origin>[XYZ]|[animXYZ]</origin></span><span data-v-c2b1f83f="" class="line"> <target>[XYZ]|[animXYZ]</target></span><span data-v-c2b1f83f="" class="line"> <roll>[XYZ]|[animXYZ]</roll></span><span data-v-c2b1f83f="" class="line"></camera></span></code>
Additional optional parameters for all types
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"> ?<region></span><span data-v-c2b1f83f="" class="line"> <startX>[float]</startX></span><span data-v-c2b1f83f="" class="line"> <startY>[float]</startY></span><span data-v-c2b1f83f="" class="line"> <endX>[float]</endX></span><span data-v-c2b1f83f="" class="line"> <endY>[float]</endY></span><span data-v-c2b1f83f="" class="line"> ?<originalAspectRatio>[float]</originalAspectRatio></span><span data-v-c2b1f83f="" class="line"> </region></span><span data-v-c2b1f83f="" class="line"> ?<minT>[float]</minT></span><span data-v-c2b1f83f="" class="line"> ?<maxT>[float]</maxT></span><span data-v-c2b1f83f="" class="line"></camera></span></code>
region | Remaps the image from the entire image plane to just a region specified by its start/end coordinates. This is different from the image region functionality: when using values inside the 0 0 1 1 region, this zooms into the image, without changing resolution or creating black borders. The values can also go beyond the 0-1 interval to create a shift effect. |
region | Remaps the image from the entire image plane to just a region specified by its start/end coordinates. This is different from the image region functionality: when using values inside the 0 0 1 1 region, this zooms into the image, without changing resolution or creating black borders. The values can also go beyond the 0-1 interval to create a shift effect. |
minT, maxT | Specifies the minimal/maximal intersection distance - if specified, any objects closer/further to the camera will be ignored by primary rays, creating a slice effect |
Stereo/Virtual Reality options
Spherical, cube map, and perspective camera can also optionally specify vr tag to enable the stereo rendering mode:
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line">?<vr></span><span data-v-c2b1f83f="" class="line"> <eyeSeparation>[float]</eyeSeparation></span><span data-v-c2b1f83f="" class="line"> ?<frontOffset>[float]</frontOffset></span><span data-v-c2b1f83f="" class="line"> ?<convergenceDistance>[float]</convergenceDistance></span><span data-v-c2b1f83f="" class="line"></vr></span></code>
Geometry group
Defines a group of one or more geometric objects to be inserted in the scene. Usually single scene object in 3D studio maps to single geometry group. A group in inserted in the scene as an “instance”. Single group can be inserted in the scene multiple times when multiple instances are defined, with different transformation matrices and materials. This saves memory and makes it possible for example to create large forests.
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><geometryGroup></span><span data-v-c2b1f83f="" class="line"> +<object class="[string]">...</object></span><span data-v-c2b1f83f="" class="line"> +<instance></span><span data-v-c2b1f83f="" class="line"> +<material>[string]</material></span><span data-v-c2b1f83f="" class="line"> +<transform name="[string]">[TM]|[animTM]</transform></span><span data-v-c2b1f83f="" class="line"> </instance></span><span data-v-c2b1f83f="" class="line"></geometryGroup></span></code>
- One or more materials can be present. Order matters - material ID “n” of an object is resolved using n-th material in each instance.
- One or more transform nodes can be present. Each represents single instance with given set of materials. Order does not matter. Optional name parameter, if present, is used for include/exclude stuff.
Sphere object
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><geometryGroup></span><span data-v-c2b1f83f="" class="line"> <object class="sphere"></span><span data-v-c2b1f83f="" class="line"> <materialId>[int]</materialId></span><span data-v-c2b1f83f="" class="line"> </object> </span><span data-v-c2b1f83f="" class="line"></goemetryGroup></span></code>
Inserts a single sphere with given material ID at point 0 0 0 with radius of 1. A transformation matrix of the whole geometry group is used to properly position the sphere.
File include objects
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><geometryGroup></span><span data-v-c2b1f83f="" class="line"> <object class="file">[filename]</object> </span><span data-v-c2b1f83f="" class="line"></goemetryGroup></span></code>
Parses additional file (.obj or .cgeo) and inserts it into this geometry group.
Global medium
Sets the scene global medium to a specified material. Only the volumetric properties of the material will be used to replace the default medium in the scene.
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><globalMedium></span><span data-v-c2b1f83f="" class="line"> [material]</span><span data-v-c2b1f83f="" class="line"></globalMedium></span></code>
Render selected
Activates the “render selected” mode. Only included/non-excluded objects will be rendered, rest of the scene will be black. The included/excluded strings are names of instances in geometryGroup → instance → transform
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><renderSelected>[includeList]</renderSelected></span></code>
Sun
Activates the sun in the scene and sets its position (specified as dirTo, vector pointing towards the sun from the scene origin), and optionally other parameters. Parameter dirUp specifies the direction to zenith (by default vector (0,0,1)), available since Corona 2.
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><sun></span><span data-v-c2b1f83f="" class="line"> <dirTo>[XYZ]</dirTo></span><span data-v-c2b1f83f="" class="line"> ?<dirUp>[XYZ]</dirUp></span><span data-v-c2b1f83f="" class="line"> ?<colorMode>constantWhite|realistic|realisticTextured</colorMode></span><span data-v-c2b1f83f="" class="line"> ?<colorMult>[RGB]</colorMult></span><span data-v-c2b1f83f="" class="line"> ?<turbidity>[float]</turbidity></span><span data-v-c2b1f83f="" class="line"> ?<sizeMult>[float]</sizeMult></span><span data-v-c2b1f83f="" class="line"> ?<visibleDirect>[bool]</visibleDirect></span><span data-v-c2b1f83f="" class="line"> ?<visibleReflect>[bool]</visibleReflect></span><span data-v-c2b1f83f="" class="line"> ?<visibleRefract>[bool]</visibleRefract></span><span data-v-c2b1f83f="" class="line"> ?<includeExclude>[includeList]</includeExclude></span><span data-v-c2b1f83f="" class="line"></sun></span></code>
where sizeMult is between 0.1 to 64 and turbidity is between 1.7 to 10.
Environment
Sets scene environment to a constant color or a map.
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><environment>[RGB]|[map]</environment></span></code>
Materials
Parses mtl library, saves material names so instances can reference them later:
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><mtllib>[filename]</mtllib></span></code>
Configuration file
Immediately parses a configuration (.conf) file with given filename.
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><conffile>[filename]</conffile></span></code>
Render Elements
Each renderElement node specifies a new render element to be displayed in the VFB during rendering and saved afterward. Type of the elementis specified with the “class” attribute and its name (displayed in the VFB) is specified with “instanceName” attribute:
<code data-v-c2b1f83f=""><span data-v-c2b1f83f="" class="line"><renderElement class="[string]" instanceName="[string]"></span><span data-v-c2b1f83f="" class="line">... (optional parameters, see below)</span><span data-v-c2b1f83f="" class="line"></renderElement></span></code>
Class | Description |
|---|
Class | Description |
|---|---|
alpha | Same as the built-in alpha channel |
virtualBeauty | Duplicate of the beauty channel. Does not actually allocate extra memory. Can optionally have a different denoising amount value specified:
|
renderStamp | Shows the render stamp only |
shadows | Inverted Shadows from all lights |
sourceColor | The input color of the surface before any shading, read from texture/solid color. The node value specifies which component is displayed. It is one of these values: diffuse, translucency, reflect, refract, opacity |
normalsDotProduct | Displays cosine of angle between incident ray and surface shading normal. Useful for debugging. |
normalsDiscrepancy | Displays the difference between shading and geometry normals on a surface. Useful for debugging. |
primitiveCoords | Displays local primitive coordinates. Useful for debugging. |
mapCoords | Displays mapping coordinates of a surface. Node value is a single int specifying which channel is displayed. |
samplingFocus | Shows the concentration of samples per pixel in the image. Visualizes what the adaptivity algorithms do, with brighter areas representing more samples used in the area. Has two optional parameters:
|
velocity | Shows the geometry velocity either in world or in camera space. Has optional parameters:
|
worldPosition | Displays position of surface point in world coordinates. |
albedo | Total surface reflectivity - sum of all possible SourceColor channels. Surfaces with near-100% albedo are displayed with red tint. |
normals | Visualization of the surface normals. The node value specifies what type of normals to display: it either equals shading, or geometry. |
normalMap | Creates a normal map from difference between shading and geometry normals. |
components | Displays selected components of the shaded result. Multiple components can be selected for the single element, in that case they are added up in the result. They are specified as:
The allowed string values are emission and {diffuse, translucency, reflect, refract, volumetric}×{direct, indirect} (any combination of one prefix and one suffix - e.g. DiffuseDirect, ReflectIndirect) |
rawComponent | “Raw” component - direct and indirect illumination not affected by the surface color. It is equal to direct+indirect Components element divided by corresponding SourceColor. Only shows results for one component at time. The parameter specifies which one, and can be one of these values: diffuse, translucency, reflect, refract. |
id | Displays IDs visualized as colors based on selected factors. The possible element values are: primitive, instance, geometryGroup, material. |
zDepth | Displays the distance of objects from the camera. Has 2 child nodes that specify the minimal (mapped to black) and maximal (mapped to white) distances:
|
texmap | Renders a map in a separate buffer. The map is specified as the sole child of the element. |
BloomGlare | Separated Bloom and Glare effect. |
LightSelect | Lighting from a selected subset of lights. The subset is specified with:
- individual lights are named by their “name” (same as include list), plus there is option to include sun and sky separately (since they have no source node). |