renderTarget

 

Tag: renderTarget
Parent tag: renderTargets
Attributes:

  • name – The name of the render target

Child tags:

  • SIZE (uivec2) – width and height of the render target
  • LAYERS (uint) -number of layers (default 1)
  • SAMPLES (uint) – number of samples per pixel (default 1)
  • CLEAR_VALUES (vec4) – clear color (default (0,0,0,0)
  • colors – sequence of color attachments
  • depth – depth attachment
  • depthStencil – depth and stencil attachment (24+8)

The depth and depthStencil tags are optional. If not specified the depth from the default frame buffer will be used. If specified these tags are exclusive, i.e. we can use one or the other but not both.

Example:

		<renderTarget name="gbuffer">
			<SIZE width=1024 height=1024/>
			<LAYERS value=2/>
			<SAMPLES value=8/>
			<CLEAR_VALUES r=0.0 g=0.0 b=0.0 a=0.0/>
			<colors>
				...
			</colors>
			<depth ... />	
		</renderTarget>