|
virtual void | beginFrame () override |
| Indicate the begining of a frame.
|
|
virtual void | beginRenderPass (const RenderPassDescriptor &descriptor) override |
| Begin a render pass, initial color, depth and stencil attachment.
|
|
virtual void | setRenderPipeline (RenderPipeline *renderPipeline) override |
| Sets the current render pipeline state object.
|
|
virtual void | setViewport (int x, int y, unsigned int w, unsigned int h) override |
| Fixed-function state.
|
|
virtual void | setCullMode (CullMode mode) override |
| Fixed-function state.
|
|
virtual void | setWinding (Winding winding) override |
| Fixed-function state.
|
|
virtual void | setVertexBuffer (Buffer *buffer) override |
| Set a global buffer for all vertex shaders at the given bind point index 0.
|
|
virtual void | setProgramState (ProgramState *programState) override |
| Set unifroms and textures.
|
|
virtual void | setIndexBuffer (Buffer *buffer) override |
| Set indexes when drawing primitives with index list @ buffer A buffer object that the device will read indexes from.
|
|
virtual void | drawArrays (PrimitiveType primitiveType, std::size_t start, std::size_t count) override |
| Draw primitives without an index list.
|
|
virtual void | drawElements (PrimitiveType primitiveType, IndexFormat indexType, std::size_t count, std::size_t offset) override |
| Draw primitives with an index list.
|
|
virtual void | endRenderPass () override |
| Do some resources release.
|
|
virtual void | endFrame () override |
| Present a drawable and commit a command buffer so it can be executed as soon as possible.
|
|
virtual void | setLineWidth (float lineWidth) override |
| Fixed-function state.
|
|
virtual void | setScissorRect (bool isEnabled, float x, float y, float width, float height) override |
| Fixed-function state.
|
|
virtual void | setDepthStencilState (DepthStencilState *depthStencilState) override |
| Set depthStencil status.
|
|
virtual void | captureScreen (std::function< void(const unsigned char *, int, int)> callback) override |
| Get a screen snapshot.
|
|
|
Public Member Functions inherited from CommandBuffer |
void | setStencilReferenceValue (unsigned int value) |
| Update both front and back stencil reference value.
|
|
void | setStencilReferenceValue (unsigned int frontRef, unsigned int backRef) |
| Update stencil reference value.
|
|
void | retain () |
| Retains the ownership.
|
|
void | release () |
| Releases the ownership immediately.
|
|
Ref * | autorelease () |
| Releases the ownership sometime soon automatically.
|
|
unsigned int | getReferenceCount () const |
| Returns the Ref's current reference count.
|
|
virtual | ~Ref () |
| Destructor.
|
|
unsigned int | _ID |
| object id, ScriptSupport need public _ID
|
|
int | _luaID |
| Lua reference id.
|
|
void * | _scriptObject |
| scriptObject, support for swift
|
|
bool | _rooted |
| When true, it means that the object was already rooted.
|
|
Store encoded commands for the GPU to execute.
A command buffer stores encoded commands until the buffer is committed for execution by the GPU
virtual void setIndexBuffer |
( |
Buffer * |
buffer | ) |
|
|
overridevirtual |
Set indexes when drawing primitives with index list @ buffer A buffer object that the device will read indexes from.
@ see drawElements(PrimitiveType primitiveType, IndexFormat indexType, unsigned int count, unsigned int offset)
Implements CommandBuffer.