Version: 2017.1

RenderTexture

class in UnityEngine

/

Hereda de:Texture

Cambiar al Manual

Descripción

Las Render Texturas son texturas que se pueden renderizar.

They can be used to implement image based rendering effects, dynamic shadows, projectors, reflections or surveillance cameras.

One typical usage of render textures is setting them as the "target texture" property of a Camera (Camera.targetTexture), this will make a camera render into a texture instead of rendering to the screen.

Keep in mind that render texture contents can become "lost" on certain events, like loading a new level, system going to a screensaver mode, in and out of fullscreen and so on. When that happens, your existing render textures will become "not yet created" again, you can check for that with IsCreated function.

As with other "native engine object" types, it is important to pay attention to the lifetime of any render textures and release them when you are finished using them with the Release function, as they will not be garbage collected like normal managed types.

See Also: Camera.targetTexture.

Variables Estáticas

activeRender texture actualmente activa.

Variables

antiAliasingEl nivel antialiasing para la RenderTexture.
autoGenerateMipsMipmap levels are generated automatically when this flag is set.
colorBufferBuffer de color de la render texture (Lectura solamente).
depthThe precision of the render texture's depth buffer in bits (0, 16, 24/32 are supported).
depthBufferDepth/stencil buffer de la render texture (lectura solamente).
descriptorThis struct contains all the information required to create a RenderTexture. It can be copied, cached, and reused to easily create RenderTextures that all share the same properties.
dimensionDimensionalidad (tipo) de la render texture.
enableRandomWriteHabilita la escritura de acceso aleatoria a esta render texture en Shader Model 5.0 level shaders.
formatEl formato de color de la render texture.
heightLa altura de la render texture en pixeles.
memorylessModeThe render texture memoryless mode property.
sRGBEsta render texture utiliza una conversión sRGB lectura/escritura (Lectura solamente).
useMipMapRender texture has mipmaps when this flag is set.
volumeDepthVolume extent of a 3D render texture or number of slices of array texture.
vrUsageIf this RenderTexture is a VR eye texture used in stereoscopic rendering, this property decides what special rendering occurs, if any.
widthEl ancho de la render texture en pixeles.

Constructores

RenderTextureCrea un nuevo objeto RenderTexture.

Funciones Públicas

CreateEn realidad crea la RenderTexture.
DiscardContentsHint the GPU driver that the contents of the RenderTexture will not be used.
GenerateMipsGenerate mipmap levels of a render texture.
GetNativeDepthBufferPtrRecupera un apuntador (API gráfica subyacente) nativo al recurso del depth buffer.
IsCreatedEs la render texture en realidad creada?
MarkRestoreExpectedIndica que hay una operación de restauración RenderTexture esperada.
ReleaseSuelta la RenderTexture.
SetGlobalShaderPropertyAsigna esta RenderTexture como una propiedad global shader llamada propertyName.

Funciones Estáticas

GetTemporaryAsigna una render texture temporal.
ReleaseTemporarySoltar una textura temporal asignada con GetTemporary.
SupportsStencilEsta RenderTexture tiene un stencil buffer?

Miembros heredados

Variables

hideFlags¿Debería el objeto estar oculto, guardado con la escena o modificable por el usuario?
nameEl nombre del objeto.
anisoLevelNivel de filtrado anisotrópico de la textura.
dimensionDimensionalidad (tipo) de la textura (lectura solamente).
filterModeModo de filtrado de la textura.
heightAltura de la textura en pixels. (Read Only)
mipMapBiasMip map bias de la textura.
widthAnchura de la textura en píxeles. (Read Only)
wrapModeTexture coordinate wrapping mode.
wrapModeUTexture U coordinate wrapping mode.
wrapModeVTexture V coordinate wrapping mode.
wrapModeWTexture W coordinate wrapping mode for Texture3D.

Funciones Públicas

GetInstanceIDDevuelve el id de la instancia del objeto.
ToStringDevuelve el nombre del objeto.
GetNativeTexturePtrRecupere un puntero nativo (API de gráficos subyacente) al recurso de textura.

Funciones Estáticas

DestroyElimina un gameobject, componente o asset.
DestroyImmediateDestroys the object obj immediately. You are strongly recommended to use Destroy instead.
DontDestroyOnLoadHace que el objeto target no sea destruido automáticamente cuando se cargue una nueva escena.
FindObjectOfTypeDevuelve el primer objeto activo cargado de tipo type.
FindObjectsOfTypeDevuelve una lista de todos los objetos activos cargados de tipo type.
InstantiateClona el objeto original y devuelve el clon.
SetGlobalAnisotropicFilteringLimitsEstablece límites anisotrópicos.

Operadores

bool¿Existe el objeto?
operator !=Compare si dos objetos se refieren a un objeto diferente.
operator ==Compara dos referencias de objeto para ver si se refieren al mismo objeto.