src/libGLESv2/Texture.h


Log

Author Commit Date CI Message
gman@chromium.org 50c526d2 2011-08-10T05:19:44 Add support for DXT3 and DXT5 TEST=none BUG=none Review URL: http://codereview.appspot.com/4809068 git-svn-id: https://angleproject.googlecode.com/svn/trunk@721 736b8ea6-26fd-11df-bfd4-992fa37f6226
jbauman@chromium.org f1f28c80 2011-05-12T20:53:34 Use SSE2 to swizzle RGBA to BGRA Using SSE2 can drastically reduce the amount of time it takes to do glTexImage2D. I've also added a plain-C path that's much faster than the one that was there before. BUG=151 TEST= Review URL: http://codereview.appspot.com/4465052 git-svn-id: https://angleproject.googlecode.com/svn/trunk@649 736b8ea6-26fd-11df-bfd4-992fa37f6226
jbauman@chromium.org ae345807 2011-03-30T22:04:25 Add support for eglBindTexImage and eglReleaseTexImage With this patch we can bind pbuffers as textures. Once we add support for using a sharing handle to create a pbuffer we can use this to allow us to use it as a texture as well. BUG=129 TEST=modified Simple_Texture2D works Review URL: http://codereview.appspot.com/4291066/ git-svn-id: https://angleproject.googlecode.com/svn/trunk@604 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com b627699f 2011-03-29T00:58:18 Use D3DX to copy between renderable texture surfaces. TRAC #16118 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@598 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 549bdefe 2011-03-29T00:57:01 Retrieve the D3D texture format per image. TRAC #16118 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@597 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com d976b584 2011-03-29T00:56:20 Consistently use the virtual keyword on virtual overloaded methods. TRAC #16118 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@596 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com a06aa870 2011-03-21T17:22:21 Track dirty texture parameters and images separately. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@590 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com a9eb5dac 2011-03-21T16:39:16 Track texture serials instead of id's. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@589 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 38e76e53 2011-03-21T16:39:10 Keep track of applied textures and dirty state to minimize D3D calls. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@588 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 51887316 2011-03-21T16:39:03 Fix checking for floating-point render target texture support. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@587 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 6120820e 2011-03-21T16:38:50 Retrieve texture width, height and type from the top-level image. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@584 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com b5a3a6b6 2011-03-21T16:38:46 Texture image refactoring. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@583 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com c50edcb2 2011-03-21T16:38:40 Remove redundant dirtyImageData() check. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@582 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 0bd22bc9 2011-03-21T16:38:26 Check image type in texture completeness test. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@581 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 8a0a2db7 2011-03-21T16:38:20 InternalFormat and format are the same. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@580 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com aed1832d 2011-03-21T16:38:13 Fix dirty texture state management. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@579 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 68076a07 2011-03-21T16:38:09 Eliminate the weak base texture pointer. TRAC #15703 Issue=86 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@578 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com d2fd4f2a 2011-02-01T18:49:11 Fix FBO/Texture/renderbuffer class hierarchy issues TRAC #14744 Issue=51/52 Delegated format queries to RenderbufferStorage. Eliminated TextureColorbufferProxy by merging it into Colorbuffer. Abstracted texture colorbuffer queries. Moved some conversion functions to the right namespace. Fixed line-endings in Texture.cpp Signed-off-by: Daniel Koch Author: Nicolas Capens <nicolas@transgaming.com> git-svn-id: https://angleproject.googlecode.com/svn/trunk@553 736b8ea6-26fd-11df-bfd4-992fa37f6226
apatrick@chromium.org b31f532d 2011-01-19T19:02:52 All surfaces follow D3D Y convention, i.e. (0, 0) is "top-left" rather than GL's "bottom-left". This eliminates the need to flip the default FBO to the D3D convention using additional blits when presenting and reduces VRAM usage for redundant window sized surfaces. I took out the gl_Position.y flip from the vertex shader so FBOs are rendered according to D3D conventions. Texture lookups are flipped on Y to compensate. Cube map +Y and -Y faces are swapped. Y is now flipped in various other places, including uploading and reading back texture data from / to system memory, functions that take pixel space coordinates, winding order for culling, the implementation of ddy, the calculation of gl_Position and gl_FragCoord in fragment shaders and the flipping of compressed texture tiles. Review URL: http://codereview.appspot.com/3265041 git-svn-id: https://angleproject.googlecode.com/svn/trunk@536 736b8ea6-26fd-11df-bfd4-992fa37f6226
apatrick@chromium.org 9d1c9b4b 2010-11-23T22:05:41 glGenerateMipmap now does not force textures to become render targets. For textures that are not already render targets, use the CPU to filter them and mark them as dirty. I tested it by modifying the "mip_map_2d" demo to call glGenerateMipmap instead of generating the mipmaps itself. I also used the debugger to force it to take the render target path and verified that it still worked. We've been having problems with the display being reset when video memory pressure is heavy with one of our demos. This patch made a noticable improvement on Vista but I don't think it will necessarily help on XP. Review URL: http://codereview.appspot.com/3262041 git-svn-id: https://angleproject.googlecode.com/svn/trunk@490 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 4c5142c6 2010-10-15T17:58:27 Implemented glCopyTex[Sub]Image for non-renderable formats. TRAC #13792 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@461 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 3f85fbbc 2010-10-15T17:58:05 Validate glCopyTex[Sub]Image source and destination format combinations. TRAC #13792 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@459 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 11cb68cb 2010-10-15T17:57:40 Create and load L/LA textures. TRAC #13792 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@456 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 5d752f29 2010-10-07T13:37:20 Add proper detection for maximum texture and renderbuffer size Trac #13849 Increased the maximum possible texture & renderbuffer size to 16384 (the minimum required for DX11 cards). Limit the actual maximum texture & renderbuffer size to the maximum that it reported by the underlying D3D9 device. Note that creating textures and renderbuffers at the maximum size will quickly exhaust video memory! Signed-off-by: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@447 736b8ea6-26fd-11df-bfd4-992fa37f6226
enne@chromium.org 0fa74639 2010-09-21T16:18:52 Allow blitting to a render texture in BlitFramebuffer. Change the type check to allow blitting between render buffers and render textures. Store the format for render textures so that resolving to a render texture Colorbuffer will pass the format check. BUG=37 Review URL: http://codereview.appspot.com/2205043 git-svn-id: https://angleproject.googlecode.com/svn/trunk@430 736b8ea6-26fd-11df-bfd4-992fa37f6226
apatrick@chromium.org 4e3bad4e 2010-09-15T17:31:48 Changed raw pointers to RefCountObject to BindingPointers. I suspect there is a bug whereby an owning reference to a RefCountObject is temporarily assigned to a BindingPointer, causing it to be destroyed and making the owning raw pointer go dangling. Making this change for mColorbufferProxy seemed to fix a crash in Chrome with canvas 2D. This was previously landed in r417 and r418. Review URL: http://codereview.appspot.com/2108047 git-svn-id: https://angleproject.googlecode.com/svn/trunk@423 736b8ea6-26fd-11df-bfd4-992fa37f6226
apatrick@chromium.org ff8bdfb0 2010-09-15T17:27:49 Backing out r417 and r418. I will recommit these as two separate patches: one for ID invalidation and one for reference counting issue. I will not recommit the FBO changes and since the GLES2 spec will soon make it undefined whether FBOs are in a shared namespace. Review URL: http://codereview.appspot.com/2154045 git-svn-id: https://angleproject.googlecode.com/svn/trunk@422 736b8ea6-26fd-11df-bfd4-992fa37f6226
apatrick@chromium.org 5525502d 2010-09-11T02:12:47 Replaced raw pointers to RefCountObject to BindingPointer. This fixes the ANGLE crashes in Chrome when using canvas 2D. The issue was this: Renderbuffer *mColorbufferProxy = new RenderBuffer(...); // Reference count is zero. BindingPointer<RenderBuffer> tempRef; tempRef.set(mColorbufferProxy); // Reference count is one. tempRef.set(NULL); // Reference count is zero and object is destroyed, leaving mColorbufferProxy dangling. I also initially suspected the problem was that FBOs are not treated as shared and the implementation of shared FBOs is still in the patch. I believe GLES2 supports shared FBOs. My reading of the GLES2 spec is that when a shared object is deleted, it loses its id but retains its state if left bound elsewhere. I added that to RefCountObject. Review URL: http://codereview.appspot.com/2120045 git-svn-id: https://angleproject.googlecode.com/svn/trunk@417 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 1297d92b 2010-09-01T15:47:47 Implements support for renderable floating point textures. TRAC #12909 Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@409 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 0a337e93 2010-08-28T17:38:27 Implement support for floating point textures. Trac #12909 Implements GL_OES_texture_float, GL_OES_texture_half_float, GL_OES_texture_float_linear, and GL_OES_texture_half_float_linear when supported by the hardware. Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Shannon Woods <shannon.woods@transgaming.com> git-svn-id: https://angleproject.googlecode.com/svn/trunk@404 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 1ac37d80 2010-08-24T19:21:31 Optimizes Texture::loadImageData TRAC #13046 Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@399 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 01868135 2010-08-24T19:21:17 Implements compressed textures. TRAC #12714 Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@397 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 31273558 2010-08-04T13:42:44 Fixes erroneous copy in subImage calls after failure is already detected. TRAC #13074 Also adds initializations for missed Texture members. Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@368 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 9ecb9f9d 2010-07-28T19:21:12 Sharing for buffer, texture and renderbuffer objects. TRAC #12496 Derive Renderbuffer, Texture and Buffer from RefCountObject. This class keeps a reference count for all objects that need cross-context reference counting, and also the object id. Restructure Renderbuffers to create a wrapper object and a storage object. Use BindingPointer for all binding points instead of binding by object id. Signed-off-by: Shannon Woods Signed-off-by: Daniel Koch git-svn-id: https://angleproject.googlecode.com/svn/trunk@364 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com da13f3e9 2010-07-28T19:20:56 Adds resource manager class. TRAC #12493 The resource manager class is now in charge of allocation & management of objects which may be shared by multiple contexts. Signed-off-by: Andrew Lewycky Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@360 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 866f318d 2010-05-20T19:28:22 TextureColorbufferProxy must query the texture to get the latest width & height. TRAC #12372 Signed-off-by: Daniel Koch Author: Andrew Lewycky git-svn-id: https://angleproject.googlecode.com/svn/trunk@315 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com c808c5a9 2010-05-14T17:31:01 When NONPOW2CONDITIONAL is set, limit NPOTs to a single level. TRAC #12250 Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Andrew Lewycky git-svn-id: https://angleproject.googlecode.com/svn/trunk@283 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 5a0b0a8b 2010-05-12T03:45:07 Minimizes texture state changes TRAC #12203 Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@267 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 092bd481 2010-05-12T03:39:36 Minimizes render target changes TRAC #12154 This patch reduces calls to SetRenderTarget. Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@259 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 713914b5 2010-05-04T03:35:17 Implements PACK_ALIGNMENT for ReadPixels TRAC #11484 Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/trunk@224 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 93a8147f 2010-04-20T18:52:58 Support FBO attachment to cubemaps TRAC #11364 Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Andrew Lewycky git-svn-id: https://angleproject.googlecode.com/svn/trunk@172 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com e6842296 2010-04-20T18:52:50 Fix more relative #include paths (mostly header files) Trac #11408 Signed-off-by: Andrew Lewycky Signed-off-by: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@171 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 8fd99e26 2010-04-20T18:52:00 Implement support for mipmap generation TRAC #11338 Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch Author: Andrew Lewycky git-svn-id: https://angleproject.googlecode.com/svn/trunk@161 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com b8c28edd 2010-04-13T03:26:32 Implement CopyTex(Sub)Image2D TRAC #11474 Signed-off-by: Shannon Woods Signed-off-by: Daniel Koch Author: Andrew Lewycky git-svn-id: https://angleproject.googlecode.com/svn/trunk@132 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 3489e3ae 2010-03-21T04:31:11 Implement glPixelStorei for Tex(Sub)Image2D. TRAC #11475 Author: Andrew Lewycky Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch git-svn-id: https://angleproject.googlecode.com/svn/trunk@55 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 7051b97e 2010-03-21T04:31:07 Default textures to non-renderable. TRAC #11309 * Lift getRenderTarget() into base class Texture. * Add pure virtual convertToRenderTarget() and getSurface(). Author: Andrew Lewycky Signed-off-by: Shannon Woods Signed-off-by: Daniel Koch git-svn-id: https://angleproject.googlecode.com/svn/trunk@54 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 842f7a4e 2010-03-21T04:31:03 Partial TexSubImage after FBO rendering overwrites entire image. TRAC #11439 * Store texel data in IDirect3DSurface9 rather than client memory. * TexSubImage uploads new data immediately. * Fix 5551 texture format conversion. Author: Andrew Lewycky Signed-off-by: Nicolas Capens Signed-off-by: Daniel Koch git-svn-id: https://angleproject.googlecode.com/svn/trunk@53 736b8ea6-26fd-11df-bfd4-992fa37f6226
daniel@transgaming.com 7c46b9e6 2010-03-17T13:12:58 mv libGLESv2 -> src/libGLESv2 Trac #11406 Signed-off-by: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@40 736b8ea6-26fd-11df-bfd4-992fa37f6226