This page has been translated automatically.
UnigineEditor
Interface Overview
Assets Workflow
Settings and Preferences
Working With Projects
Adjusting Node Parameters
Setting Up Materials
Setting Up Properties
Landscape Tool
Using Editor Tools for Specific Tasks
Extending Editor Functionality
Programming
Fundamentals
Setting Up Development Environment
Usage Examples
UnigineScript
C++
C#
UUSL (Unified UNIGINE Shader Language)
File Formats
Rebuilding the Engine Tools
GUI
Double Precision Coordinates
API
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Math Functionality
Node-Related Classes
Objects-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
IG Plugin
CIGIConnector Plugin
Warning! This version of documentation is OUTDATED, as it describes an older SDK version! Please switch to the documentation for the latest SDK version.
Warning! This version of documentation describes an old SDK version which is no longer supported! Please upgrade to the latest SDK version.

RenderTarget Class

Warning
The scope of applications for UnigineScript is limited to implementing materials-related logic (material expressions, scriptable materials, brush materials). Do not use UnigineScript as a language for application logic, please consider C#/C++ instead, as these APIs are the preferred ones. Availability of new Engine features in UnigineScipt (beyond its scope of applications) is not guaranteed, as the current level of support assumes only fixing critical issues.

A container to which an image is rendered (a framebuffer abstraction).

RenderTarget Class

Members


RenderTarget create ( ) #

Creates a new render target.

Return value

Render target.

void destroy ( ) #

Destroys the render target.

void enable ( ) #

Enables the render target.

void enableCompute ( ) #

Enables the render target with the use of compute shader output.

void disable ( ) #

Disables the render target.

void flush ( ) #

Flushes the render target.

Texture getColorTexture ( int slot ) #

Returns a color texture by the specified slot.

Arguments

  • int slot - Texture slot.

Return value

Color texture if it exists, otherwise NULL.

void bindColorTexture ( int slot, Texture texture, int array_slice = -1, int texture_slice = -1, int mip_level = 0 ) #

Binds a render target texture to a device by the specified slot.

Arguments

  • int slot - Texture slot.
  • Texture texture - Color texture to be bound.
  • int array_slice - Array slice.
  • int texture_slice - Texture slice.
  • int mip_level - Texture mip level.

void unbindColorTexture ( int slot ) #

Unbinds a render target texture from a device by the specified slot.

Arguments

  • int slot - Texture slot.

void unbindColorTextures ( ) #

Unbinds all render target textures from a device.

Texture getDepthTexture ( ) #

Returns the depth texture.

Return value

Depth texture if it exists, otherwise NULL.

void bindDepthTexture ( Texture texture, int array_slice = -1, int texture_slice = -1, int mip_level = 0 ) #

Binds a depth texture to a device by the specified slot.

Arguments

  • Texture texture - Depth texture to be bound.
  • int array_slice - Array slice.
  • int texture_slice - Texture slice.
  • int mip_level - Texture mip level.

void unbindDepthTexture ( ) #

Unbinds a depth texture from a device.

Texture getUnorderedAccessTexture ( int slot ) #

Returns an unordered access texture by the specified slot.

Arguments

  • int slot - Texture slot.

Return value

Unordered access texture if it exists, otherwise NULL.

void bindUnorderedAccessTexture ( int slot, Texture texture, int writeonly = 0 ) #

Binds an unordered access texture to a device by the specified slot.

Arguments

  • int slot - Texture slot.
  • Texture texture - Unordered access texture to be bound.
  • int writeonly - Access flag. 1 to use the texture for writing only, otherwise 0.

void unbindUnorderedAccessTexture ( int slot ) #

Unbinds an unordered access texture from a device by the specified slot.

Arguments

  • int slot - Texture slot.

void unbindUnorderedAccessTextures ( ) #

Unbinds all unordered access textures from a device.

StructuredBuffer getStructuredBuffer ( int slot ) #

Returns a structured buffer by the specified slot.

Arguments

  • int slot - Texture slot.

Return value

Structured buffer if it exists, otherwise NULL.

void bindStructuredBuffer ( int slot, StructuredBuffer buffer ) #

Binds a structured buffer to a device by the specified slot.

Arguments

void unbindStructuredBuffer ( int slot ) #

Unbinds a structured buffer from a device by the specified slot.

Arguments

  • int slot - Texture slot.

void unbindStructuredBuffers ( ) #

Unbinds all structured buffers from a device.

int isEnabled ( ) #

Returns a value indicating if the render target is enabled.

Return value

1 if the render target is enabled, otherwise 0.

int isCompleted ( ) #

Returns a value indicating if the render target is completed.

Return value

1 if the render target is completed, otherwise 0.

void unbindAll ( ) #

Unbinds all color, depth, and unordered access textures as well as structured buffers from a device.
Last update: 2020-07-31
Build: ()