Transition override: <transition>
XML location & structure
<cu3er>
<slides>
<slide>
<transition ... />
<slide>
<slide>
<transition ... />
</slides>
</cu3er>
Overview
The content of the CU3ER is defined in the <slides> node where each <slide> node defines a particular slide and each <transition /> node defines a 3D transition between two slides nearby. The last <transition /> node defines a 3D transition between the last and the first slide.
In case you have set a transition template - set of 3D transition instructions common for each 3D transition, you can override its properties and customize each particular 3D transition further.
As you may notice (in the example at the top), there’s no <transition/> node between the second and the third slide in the example above! In this case, transition properties are defined by the transition template leaving you an option to include 3D <transition/> node only if you need custom settings per 3D transition.
Remember, the content of the CU3ER is defined in the <slides> node where each <slide> node defines a particular slide and each <transition /> node defines a 3D transition between two slides nearby. The last <transition /> node defines a 3D transition between the last and the first slide.
Available attributes are the same as in the transition template, which means you can override any of these:
- num - number of slices each transition consists of
- slicing - direction of cube slicing - horizontal or vertical
- direction - transition direction / cubes rotation direction -left, right, up, down
- shader - transition shading type - none, flat, phong
- light_position - if “shader” is set other than 'none', use this attribute to define x, y & z light position for shading
- cube_color - during transition, some other cube faces (beside your slide faces) will most likely become visible for a short period of time and you can define their color here
- z_multiplier - z offset enables jo-jo effect of the cubes on z axis during transition
- duration - time (needed) for each sliced cube transition
- delay – time each cube will wait before starting transition. Please, notice that 'delay' is a cumulative value, which means it’s increasing gradually as all preceding delays are added to the delay of the cube already displayed. Now take a look at the example below.
Please, notice the difference between the
Example
<transition num="4" direction="up" z_multiplier="4" />
XML Reference
| Attribute | Default Value | Type | description |
|---|---|---|---|
| num | 1 | number | number of slices each transition consists of |
| slicing | horizontal | string | direction of cube slicing - horizontal or vertical |
| direction | left | string | transition direction / cubes rotation direction -left, right, up, down |
| duration | 0.5 | number | time (needed) for each sliced cube transition (in seconds) |
| delay | 0.1 | number | time each cube will wait before starting transition (in seconds) |
| shader | none | string | transition shading type - none, flat, phong |
| light_position | 0, 0, -100 | numbers | use this attribute to define x, y & z light position for shading (works only if shader is not set to "none") |
| cube_color | 0x333333 | hex number | cube faces color |
| z_multiplier | 2 | number | bezierTrough effect over "z" axis during transition |