Lines Matching refs:buffer
87 GrBufferObj *buffer = NULL;
90 buffer = GrDebugGL::getInstance()->getArrayBuffer();
93 buffer = GrDebugGL::getInstance()->getElementArrayBuffer();
100 GrAlwaysAssert(buffer);
101 GrAlwaysAssert(buffer->getBound());
103 buffer->allocate(size, reinterpret_cast<const GrGLchar *>(data));
104 buffer->setUsage(usage);
210 // frame buffer
222 // a renderBufferID of 0 is acceptable - it unbinds the bound render buffer
251 // Open GL will remove a deleted render buffer from the active
252 // frame buffer but not from any other frame buffer
276 GrTextureObj *buffer = GR_FIND(textures[i],
279 GrAlwaysAssert(buffer);
282 // something other than the currently bound frame buffer
283 GrAlwaysAssert(!buffer->getBound());
285 GrAlwaysAssert(!buffer->getDeleted());
286 buffer->deleteAction();
300 // this ID is the current frame buffer - rebind to the default
308 GrFrameBufferObj *buffer = GR_FIND(frameBuffers[i],
311 GrAlwaysAssert(buffer);
313 GrAlwaysAssert(!buffer->getDeleted());
314 buffer->deleteAction();
327 // this ID is the current render buffer - make no
328 // render buffer be bound
335 // Open GL will remove a deleted render buffer from the active frame
336 // buffer but not from any other frame buffer
361 GrRenderBufferObj *buffer = GR_FIND(renderBuffers[i],
364 GrAlwaysAssert(buffer);
366 // OpenGL gives no guarantees if a render buffer is deleted
368 // bound frame buffer
369 GrAlwaysAssert(!buffer->getColorBound());
370 GrAlwaysAssert(!buffer->getDepthBound());
373 //GrAlwaysAssert(!buffer->getStencilBound());
375 GrAlwaysAssert(!buffer->getDeleted());
376 buffer->deleteAction();
392 // A render buffer cannot be attached to the default framebuffer
396 // render buffer
576 GrBufferObj *buffer = GR_FIND(bufferID,
579 // 0 is a permissible bufferID - it unbinds the current buffer
583 GrDebugGL::getInstance()->setArrayBuffer(buffer);
586 GrDebugGL::getInstance()->setElementArrayBuffer(buffer);
594 // deleting a bound buffer has the side effect of binding 0
601 // this ID is the current array buffer
607 // this ID is the current element array buffer
614 GrBufferObj *buffer = GR_FIND(ids[i],
617 GrAlwaysAssert(buffer);
619 GrAlwaysAssert(!buffer->getDeleted());
620 buffer->deleteAction();
624 // map a buffer to the caller's address space
632 GrBufferObj *buffer = NULL;
635 buffer = GrDebugGL::getInstance()->getArrayBuffer();
638 buffer = GrDebugGL::getInstance()->getElementArrayBuffer();
645 if (buffer) {
646 GrAlwaysAssert(!buffer->getMapped());
647 buffer->setMapped();
648 return buffer->getDataPtr();
652 return NULL; // no buffer bound to the target
655 // remove a buffer from the caller's address space
662 GrBufferObj *buffer = NULL;
665 buffer = GrDebugGL::getInstance()->getArrayBuffer();
668 buffer = GrDebugGL::getInstance()->getElementArrayBuffer();
675 if (buffer) {
676 GrAlwaysAssert(buffer->getMapped());
677 buffer->resetMapped();
694 GrBufferObj *buffer = NULL;
697 buffer = GrDebugGL::getInstance()->getArrayBuffer();
700 buffer = GrDebugGL::getInstance()->getElementArrayBuffer();
704 GrAlwaysAssert(buffer);
709 if (buffer)
710 *params = buffer->getMapped() ? GR_GL_TRUE : GR_GL_FALSE;
714 if (buffer)
715 *params = buffer->getSize();
719 if (buffer)
720 *params = buffer->getUsage();