Difference between revisions of "My first: Custom portrait"

From Divinity Engine Wiki
Jump to: navigation, search
m
Line 9: Line 9:
 
In order to render character portraits, we will need a photobooth level. The photobooth level is a level that contains photobooths for each character for which an icon is rendered. Each photobooth consists of a background plane, lights, a point trigger and a spectator trigger. The spectator trigger is the camera from which the icon will be rendered.
 
In order to render character portraits, we will need a photobooth level. The photobooth level is a level that contains photobooths for each character for which an icon is rendered. Each photobooth consists of a background plane, lights, a point trigger and a spectator trigger. The spectator trigger is the camera from which the icon will be rendered.
  
First, we will open the ''SYS_NPC_Portrait_A'' level, which is inherited from the Shared project. We could create a photobooth level from scratch, but using an existing one is easier because it allows us to copy an existing photobooth.
+
First, we will open the ''SYS_NPC_Portrait_A'' level, which is inherited from the Shared project. We could create a photobooth level from scratch, but using an existing one is easier, as it allows us to copy an existing photobooth.
  
 
<br />
 
<br />
 
[[File:Step1_OpenPhotoboothLevel.png|none]]
 
[[File:Step1_OpenPhotoboothLevel.png|none]]
 
<sub>Opening the ''SYS_NPC_Portrait_A'' level</sub>
 
<sub>Opening the ''SYS_NPC_Portrait_A'' level</sub>
 +
 +
 +
To open the photobooth level, check the "Show Inherited Levels" toggle <span style="color:#FCFF27">(1)</span>. Then, navigate to the "SYS" folder <span style="color:#FCFF27">(2)</span> and select (or double click) the ''SYS_NPC_Portrait_A'' level <span style="color:#FCFF27">(3)</span>. With the level selected, click "Select" to load <span style="color:#FCFF27">(4)</span>.
 +
 +
Next, we need to set the level as our project's default photobooth level.
  
 
<br />
 
<br />
 
[[File:Step2_ConfigureProjectProperties.png|none]]
 
[[File:Step2_ConfigureProjectProperties.png|none]]
 
<sub>Setting the photobooth level for this project</sub>
 
<sub>Setting the photobooth level for this project</sub>
 +
 +
 +
To set the photobooth level of your project, go to the [[Project settings window]] (under Project > Project Settings...) and navigate to the "General" tab <span style="color:#FCFF27">(1)</span>.
 +
 +
In the general tab, click the [...] button next to "Photo Booth Level" <span style="color:#FCFF27">(2)</span> and select your photobooth level (''SYS_NPC_Portrait_A''). If the level is set correctly, hit "Save" back in the project settings window <span style="color:#FCFF27">(3)</span>.
 +
 +
We can now render portraits for our level. However, the portrait texture atlas will be empty, as we have not yet defined any templates to render.
  
 
<br />
 
<br />
 
=== Step 2: setting up the photobooth ===
 
=== Step 2: setting up the photobooth ===
 
[[File:Step3_CopyingPhotobooth.png|none]]
 
[[File:Step3_CopyingPhotobooth.png|none]]
 +
<sub>Copying a photobooth for our own root template</sub>
  
 
<br />
 
<br />

Revision as of 11:29, 20 September 2017

Description

The icons for characters in Divinity: Original Sin 2 are rendered by the portrait renderer, in the editor. Although fully automatic, the portrait renderer requires some setting up to know which portraits to render.

This article will not be going over creating a new character root template. If you do not yet know how to create a character root template, I recommend you read My first: Character first.


Rendering a character portrait

Step 1: the photobooth level

In order to render character portraits, we will need a photobooth level. The photobooth level is a level that contains photobooths for each character for which an icon is rendered. Each photobooth consists of a background plane, lights, a point trigger and a spectator trigger. The spectator trigger is the camera from which the icon will be rendered.

First, we will open the SYS_NPC_Portrait_A level, which is inherited from the Shared project. We could create a photobooth level from scratch, but using an existing one is easier, as it allows us to copy an existing photobooth.


Step1 OpenPhotoboothLevel.png

Opening the SYS_NPC_Portrait_A level


To open the photobooth level, check the "Show Inherited Levels" toggle (1). Then, navigate to the "SYS" folder (2) and select (or double click) the SYS_NPC_Portrait_A level (3). With the level selected, click "Select" to load (4).

Next, we need to set the level as our project's default photobooth level.


Step2 ConfigureProjectProperties.png

Setting the photobooth level for this project


To set the photobooth level of your project, go to the Project settings window (under Project > Project Settings...) and navigate to the "General" tab (1).

In the general tab, click the [...] button next to "Photo Booth Level" (2) and select your photobooth level (SYS_NPC_Portrait_A). If the level is set correctly, hit "Save" back in the project settings window (3).

We can now render portraits for our level. However, the portrait texture atlas will be empty, as we have not yet defined any templates to render.


Step 2: setting up the photobooth

Step3 CopyingPhotobooth.png

Copying a photobooth for our own root template


Step 3: rendering


Notes

Portraits that exist in inherited projects will not be re-rendered, making it impossible to render icons for existing templates. However, it is possible to create a new photobooth with a copy of the root template you wish to modify, render the icon for that template, and then assign the rendered icon to the original template.