Template Port | This node provides access to the Template Engine from within the scene logic |
In most cases Templates are filled and controlled by Ventuz Director or the Ventuz Remoting interface. But sometimes it makes life much easier to control them independently of the Director from within the scene logic.
Imagine you want to build a sponsor banner element that changes its image automatically based on a Timer node. For this, the TemplatePort node is the perfect choice. You just need to build a simple image Template, create a valid TemplateData string and bind it to the Data property of the TemplatePort node.
The Data property can handle different data formats. Read about the supported Data Formats of the Template Engine for more information.
You can easily get a sample TemplateData copy of an existing Template in the Scene Data editor read the test templates and transitions in the Ventuz Designer page for more information.
The Template Port Node is only able to properly load a template embedded in a scene with a single 3D Layer. All other layer types are ignored and if there is more than one 3D Layer only the first one will be used and validated.
Apart from TemplateData you can also easily activate URLs. If a URL is recognized in the Data property, an internal Assethost scene is activated that can handle the following resources:
The Template Port node shows two verbs in the Property Editor Browse and Paste Data that allow you to add sample data for testing.
After setting the Data property it depends on the Automatic property if the template is cued and taken automatically or manually cued and/or taken by the user.
JumpIn and JumpOut define whether the TemplateEngine jumps to the Present or End point without playing the transition defined in the Animation.
Transitions to a Template can consist of Multi Takes. To ignore these Multi Takes, enable the SingleTake property.
When the Release property is enabled the loaded Scene will be released in the memory after the Template is taken off air and therefore not needed anymore. Note that it will take some time to load the Scene again on the next take, so you should only use this if you are sure that the Template in that Scene is only used once.
Count indicates the amount of takes available, if no or an invalid Data is set the property shows the default value 0. Current shows the current state of the template -1 means that a template is cueing. Duration provides the duration of the transition from the present template to the next one. Descripton gives the user defined description of the template.
The output events Cued and Taken indicate successful cue and take actions. Whenever one of these actions causes an error, the Failed event is fired.