public class RenderTarget2D extends Texture2D
Modifier and Type | Field and Description |
---|---|
Event<EventArgs> |
ContentLost
Occurs when resources are lost due to a lost device event.
|
_parent, Disposing, Name, Tag
Constructor and Description |
---|
RenderTarget2D(GraphicsDevice graphicsDevice,
int width,
int height)
Creates an instance of this object.
|
RenderTarget2D(GraphicsDevice graphicsDevice,
int width,
int height,
boolean mipMap,
SurfaceFormat preferredFormat,
DepthFormat preferredDepthFormat) |
RenderTarget2D(GraphicsDevice graphicsDevice,
int width,
int height,
boolean mipMap,
SurfaceFormat preferredFormat,
DepthFormat preferredDepthFormat,
int preferredMultiSampleCount,
RenderTargetUsage usage) |
Modifier and Type | Method and Description |
---|---|
protected void |
Dispose(boolean disposing)
Immediately releases the unmanaged resources used by this Object.
|
DepthFormat |
getDepthStencilFormat()
Gets the data format for the depth stencil data.
|
int |
getMultiSampleCount()
Gets the number of sample locations during multisampling.
|
RenderTargetUsage |
getRenderTargetUsage()
Gets or sets the render target usage.
|
boolean |
IsContentLost()
Determines if the index buffer data has been lost due to a lost device event.
|
Bounds, FromStream, FromStream, GetData, GetData, GetData, Height, SaveAsJpeg, SaveAsPng, SetData, SetData, SetData, Width
getFormat, getLevelCount
Dispose, finalize, getGraphicsDevice, IsDisposed, raise_disposing, toString
public RenderTarget2D(GraphicsDevice graphicsDevice, int width, int height)
graphicsDevice
- The graphics device to associate with this render target resource.width
- Width, in pixels, of the render target. You can use graphicsDevice.PresentationParameters.BackBufferWidth to get the current screen width.height
- Height, in pixels, of the render target. You can use graphicsDevice.PresentationParameters.BackBufferHeight to get the current screen height.public RenderTarget2D(GraphicsDevice graphicsDevice, int width, int height, boolean mipMap, SurfaceFormat preferredFormat, DepthFormat preferredDepthFormat)
graphicsDevice
- width
- height
- mipMap
- preferredFormat
- preferredDepthFormat
- public RenderTarget2D(GraphicsDevice graphicsDevice, int width, int height, boolean mipMap, SurfaceFormat preferredFormat, DepthFormat preferredDepthFormat, int preferredMultiSampleCount, RenderTargetUsage usage)
graphicsDevice
- width
- height
- mipMap
- preferredFormat
- preferredDepthFormat
- preferredMultiSampleCount
- usage
- public DepthFormat getDepthStencilFormat()
public boolean IsContentLost()
public int getMultiSampleCount()
public RenderTargetUsage getRenderTargetUsage()
protected void Dispose(boolean disposing)
GraphicsResource