Lines Matching refs:buffer

281    ANativeWindowBuffer*   buffer;
387 nativeWindow(window), buffer(0), previousBuffer(0), module(0),
404 if (buffer) {
405 buffer->common.decRef(&buffer->common);
419 // dequeue a buffer
420 if (nativeWindow->dequeueBuffer(nativeWindow, &buffer) != NO_ERROR) {
424 // allocate a corresponding depth-buffer
425 width = buffer->width;
426 height = buffer->height;
437 // keep a reference on the buffer
438 buffer->common.incRef(&buffer->common);
440 // Lock the buffer
441 nativeWindow->lockBuffer(nativeWindow, buffer);
442 // pin the buffer down
443 if (lock(buffer, GRALLOC_USAGE_SW_READ_OFTEN |
445 LOGE("connect() failed to lock buffer %p (%ux%u)",
446 buffer, buffer->width, buffer->height);
448 // FIXME: we should make sure we're not accessing the buffer anymore
455 if (buffer && bits) {
457 unlock(buffer);
460 nativeWindow->queueBuffer(nativeWindow, buffer);
461 if (buffer) {
462 buffer->common.decRef(&buffer->common);
463 buffer = 0;
532 if (!buffer) {
538 * We copyback from the front buffer
541 dirtyRegion.andSelf(Rect(buffer->width, buffer->height));
551 // copy from previousBuffer to buffer
552 copyBlt(buffer, bits, previousBuffer, prevBits, copyBack);
565 unlock(buffer);
566 previousBuffer = buffer;
567 nativeWindow->queueBuffer(nativeWindow, buffer);
568 buffer = 0;
570 // dequeue a new buffer
571 if (nativeWindow->dequeueBuffer(nativeWindow, &buffer) == NO_ERROR) {
575 nativeWindow->lockBuffer(nativeWindow, buffer);
577 // reallocate the depth-buffer if needed
578 if ((width != buffer->width) || (height != buffer->height)) {
581 width = buffer->width;
582 height = buffer->height;
587 depth.stride = buffer->stride;
596 // keep a reference on the buffer
597 buffer->common.incRef(&buffer->common);
599 // finally pin the buffer down
600 if (lock(buffer, GRALLOC_USAGE_SW_READ_OFTEN |
602 LOGE("eglSwapBuffers() failed to lock buffer %p (%ux%u)",
603 buffer, buffer->width, buffer->height);
605 // FIXME: we should make sure we're not accessing the buffer anymore
623 GGLSurface buffer;
624 buffer.version = sizeof(GGLSurface);
625 buffer.width = this->buffer->width;
626 buffer.height = this->buffer->height;
627 buffer.stride = this->buffer->stride;
628 buffer.data = (GGLubyte*)bits;
629 buffer.format = this->buffer->format;
632 //printf("\t width=%d height=%d stride=%d format=%d \n", buffer.width, buffer.height, buffer.stride, buffer.format);
634 gl->width = this->buffer->width;
635 gl->height = this->buffer->height;
636 gl->stride = this->buffer->stride;
637 gl->format = this->buffer->format;
640 //gl->rasterizer.procs.colorBuffer(gl, &buffer);
661 * the content of the swapped buffer.
663 * EGL_BUFFER_DESTROYED means that the content of the buffer is lost.
720 GGLSurface buffer;
721 buffer.version = sizeof(GGLSurface);
722 buffer.width = nativePixmap.width;
723 buffer.height = nativePixmap.height;
724 buffer.stride = nativePixmap.stride;
725 buffer.data = nativePixmap.data;
726 buffer.format = nativePixmap.format;
728 //gl->rasterizer.procs.colorBuffer(gl, &buffer);
1759 // Returns the ID of the EGL frame buffer configuration with
1785 // if it's bound to a context, update the buffer
1789 // it is bound to, make sure to update the read buffer as well.