Lines Matching refs:Framebuffer

119 static tcu::CubeFace texTargetToFace (Framebuffer::TexTarget target)
123 case Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_X: return tcu::CUBEFACE_NEGATIVE_X;
124 case Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_X: return tcu::CUBEFACE_POSITIVE_X;
125 case Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_Y: return tcu::CUBEFACE_NEGATIVE_Y;
126 case Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_Y: return tcu::CUBEFACE_POSITIVE_Y;
127 case Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_Z: return tcu::CUBEFACE_NEGATIVE_Z;
128 case Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_Z: return tcu::CUBEFACE_POSITIVE_Z;
133 static Framebuffer::TexTarget texLayeredTypeToTarget (Texture::Type type)
137 case Texture::TYPE_2D_ARRAY: return Framebuffer::TEXTARGET_2D_ARRAY;
138 case Texture::TYPE_3D: return Framebuffer::TEXTARGET_3D;
139 case Texture::TYPE_CUBE_MAP_ARRAY: return Framebuffer::TEXTARGET_CUBE_MAP_ARRAY;
140 default: return Framebuffer::TEXTARGET_LAST;
466 vector<Framebuffer*> framebuffers;
468 for (vector<Framebuffer*>::iterator i = framebuffers.begin(); i != framebuffers.end(); i++)
708 rc::Framebuffer* framebufferBinding = ndx ? m_drawFramebufferBinding : m_readFramebufferBinding;
714 for (int point = 0; point < Framebuffer::ATTACHMENTPOINT_LAST; point++)
716 Framebuffer::Attachment& attachment = framebufferBinding->getAttachment((Framebuffer::AttachmentPoint)point);
721 attachment = Framebuffer::Attachment();
733 Framebuffer* fbo = DE_NULL;
745 fbo = new Framebuffer(name);
753 rc::Framebuffer*& binding = ndx ? m_drawFramebufferBinding : m_readFramebufferBinding;
762 for (int point = 0; point < Framebuffer::ATTACHMENTPOINT_LAST; point++)
763 releaseFboAttachmentReference(binding->getAttachment((Framebuffer::AttachmentPoint)point));
773 for (int point = 0; point < Framebuffer::ATTACHMENTPOINT_LAST; point++)
774 acquireFboAttachmentReference(fbo->getAttachment((Framebuffer::AttachmentPoint)point));
787 void ReferenceContext::deleteFramebuffer (Framebuffer* framebuffer)
802 Framebuffer* framebuffer = name ? m_framebuffers.find(name) : DE_NULL;
850 rc::Framebuffer* framebufferBinding = ndx ? m_drawFramebufferBinding : m_readFramebufferBinding;
856 for (int point = 0; point < Framebuffer::ATTACHMENTPOINT_LAST; point++)
858 Framebuffer::Attachment& attachment = framebufferBinding->getAttachment((Framebuffer::AttachmentPoint)point);
863 attachment = Framebuffer::Attachment();
1889 static inline Framebuffer::AttachmentPoint mapGLAttachmentPoint (deUint32 attachment)
1893 case GL_COLOR_ATTACHMENT0: return Framebuffer::ATTACHMENTPOINT_COLOR0;
1894 case GL_DEPTH_ATTACHMENT: return Framebuffer::ATTACHMENTPOINT_DEPTH;
1895 case GL_STENCIL_ATTACHMENT: return Framebuffer::ATTACHMENTPOINT_STENCIL;
1896 default: return Framebuffer::ATTACHMENTPOINT_LAST;
1900 static inline Framebuffer::TexTarget mapGLFboTexTarget (deUint32 target)
1904 case GL_TEXTURE_2D: return Framebuffer::TEXTARGET_2D;
1905 case GL_TEXTURE_CUBE_MAP_POSITIVE_X: return Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_X;
1906 case GL_TEXTURE_CUBE_MAP_POSITIVE_Y: return Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_Y;
1907 case GL_TEXTURE_CUBE_MAP_POSITIVE_Z: return Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_Z;
1908 case GL_TEXTURE_CUBE_MAP_NEGATIVE_X: return Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_X;
1909 case GL_TEXTURE_CUBE_MAP_NEGATIVE_Y: return Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_Y;
1910 case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z: return Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_Z;
1911 default: return Framebuffer::TEXTARGET_LAST;
1915 void ReferenceContext::acquireFboAttachmentReference (const Framebuffer::Attachment& attachment)
1919 case Framebuffer::ATTACHMENTTYPE_TEXTURE:
1928 case Framebuffer::ATTACHMENTTYPE_RENDERBUFFER:
1942 void ReferenceContext::releaseFboAttachmentReference (const Framebuffer::Attachment& attachment)
1946 case Framebuffer::ATTACHMENTTYPE_TEXTURE:
1955 case Framebuffer::ATTACHMENTTYPE_RENDERBUFFER:
1979 Framebuffer::AttachmentPoint point = mapGLAttachmentPoint(attachment);
1981 Framebuffer::TexTarget fboTexTarget = mapGLFboTexTarget(textarget);
1986 RC_IF_ERROR(point == Framebuffer::ATTACHMENTPOINT_LAST, GL_INVALID_ENUM, RC_RET_VOID);
1989 rc::Framebuffer* framebufferBinding = (target == GL_FRAMEBUFFER || target == GL_DRAW_FRAMEBUFFER) ? m_drawFramebufferBinding : m_readFramebufferBinding;
2004 RC_IF_ERROR(fboTexTarget != Framebuffer::TEXTARGET_2D, GL_INVALID_OPERATION, RC_RET_VOID);
2008 if (!deInRange32(fboTexTarget, Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_X, Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_Z))
2013 Framebuffer::Attachment& fboAttachment = framebufferBinding->getAttachment(point);
2016 fboAttachment = Framebuffer::Attachment();
2020 fboAttachment.type = Framebuffer::ATTACHMENTTYPE_TEXTURE;
2041 Framebuffer::AttachmentPoint point = mapGLAttachmentPoint(attachment);
2047 RC_IF_ERROR(point == Framebuffer::ATTACHMENTPOINT_LAST, GL_INVALID_ENUM, RC_RET_VOID);
2050 rc::Framebuffer* framebufferBinding = (target == GL_FRAMEBUFFER || target == GL_DRAW_FRAMEBUFFER) ? m_drawFramebufferBinding : m_readFramebufferBinding;
2080 Framebuffer::Attachment& fboAttachment = framebufferBinding->getAttachment(point);
2083 fboAttachment = Framebuffer::Attachment();
2087 fboAttachment.type = Framebuffer::ATTACHMENTTYPE_TEXTURE;
2093 DE_ASSERT(fboAttachment.texTarget != Framebuffer::TEXTARGET_LAST);
2111 Framebuffer::AttachmentPoint point = mapGLAttachmentPoint(attachment);
2117 RC_IF_ERROR(point == Framebuffer::ATTACHMENTPOINT_LAST, GL_INVALID_ENUM, RC_RET_VOID);
2120 rc::Framebuffer* framebufferBinding = (target == GL_FRAMEBUFFER || target == GL_DRAW_FRAMEBUFFER) ? m_drawFramebufferBinding : m_readFramebufferBinding;
2135 Framebuffer::Attachment& fboAttachment = framebufferBinding->getAttachment(point);
2138 fboAttachment = Framebuffer::Attachment();
2142 fboAttachment.type = Framebuffer::ATTACHMENTTYPE_RENDERBUFFER;
2158 rc::Framebuffer* framebufferBinding = (target == GL_FRAMEBUFFER || target == GL_DRAW_FRAMEBUFFER) ? m_drawFramebufferBinding : m_readFramebufferBinding;
2170 for (int point = 0; point < Framebuffer::ATTACHMENTPOINT_LAST; point++)
2172 const Framebuffer::Attachment& attachment = framebufferBinding->getAttachment((Framebuffer::AttachmentPoint)point);
2177 if (attachment.type == Framebuffer::ATTACHMENTTYPE_TEXTURE)
2183 if (attachment.texTarget == Framebuffer::TEXTARGET_2D)
2191 else if (deInRange32(attachment.texTarget, Framebuffer::TEXTARGET_CUBE_MAP_POSITIVE_X,
2192 Framebuffer::TEXTARGET_CUBE_MAP_NEGATIVE_Z))
2203 else if (attachment.texTarget == Framebuffer::TEXTARGET_2D_ARRAY)
2211 else if (attachment.texTarget == Framebuffer::TEXTARGET_3D)
2219 else if (attachment.texTarget == Framebuffer::TEXTARGET_CUBE_MAP_ARRAY)
2228 TCU_FAIL("Framebuffer attached to a texture but no valid target specified");
2234 else if (attachment.type == Framebuffer::ATTACHMENTTYPE_RENDERBUFFER)
2245 TCU_CHECK(attachment.type == Framebuffer::ATTACHMENTTYPE_LAST);
2267 if (point != Framebuffer::ATTACHMENTPOINT_COLOR0)
2272 if (point != Framebuffer::ATTACHMENTPOINT_DEPTH)
2277 if (point != Framebuffer::ATTACHMENTPOINT_STENCIL)
2282 if (point != Framebuffer::ATTACHMENTPOINT_DEPTH &&
2283 point != Framebuffer::ATTACHMENTPOINT_STENCIL)
2330 tcu::PixelBufferAccess ReferenceContext::getFboAttachment (const rc::Framebuffer& framebuffer, rc::Framebuffer::AttachmentPoint point)
2332 const Framebuffer::Attachment& attachment = framebuffer.getAttachment(point);
2336 case Framebuffer::ATTACHMENTTYPE_TEXTURE:
2366 case Framebuffer::ATTACHMENTTYPE_RENDERBUFFER:
3145 // Framebuffer formats must match
5407 Framebuffer::Framebuffer (deUint32 name)
5412 Framebuffer::~Framebuffer (void)