OLD | NEW |
(Empty) | |
| 1 Name |
| 2 |
| 3 CHROMIUM_texture_mailbox |
| 4 |
| 5 Name Strings |
| 6 |
| 7 GL_CHROMIUM_texture_mailbox |
| 8 |
| 9 Version |
| 10 |
| 11 Last Modifed Date: April 25, 2012 |
| 12 |
| 13 Dependencies |
| 14 |
| 15 OpenGL ES 2.0 is required. |
| 16 |
| 17 Overview |
| 18 |
| 19 This extension defines a way of sharing texture image data between texture |
| 20 objects in different contexts where the contexts would not normally share |
| 21 texture resources. Three new functions are exported. glGenMailboxCHROMIUM |
| 22 generates a name that can be used to identify texture image data outside |
| 23 the scope of a context group. glProduceMailboxCHROMIUM moves texture image |
| 24 data out of a texture object and into a mailbox. glConsumeMailboxCHROMIUM |
| 25 moves texture image data out of a mailbox and into a texture object. |
| 26 |
| 27 New Procedures and Functions |
| 28 |
| 29 void glGenMailboxCHROMIUM (GLbyte *mailbox) |
| 30 |
| 31 Generates a unique name identifying a mailbox. The name is generated using |
| 32 a cryptographic random number generator and is intended to be difficult to |
| 33 guess. The scope of the name is implementation specific, for example it |
| 34 might not span multiple displays. |
| 35 |
| 36 <mailbox> returns a GL_MAILBOX_SIZE_CHROMIUM byte sized name |
| 37 |
| 38 |
| 39 void glProduceTextureCHROMIUM (GLenum target, const GLbyte *mailbox) |
| 40 |
| 41 Moves the image data of the currently bound texture object into the mailbox. |
| 42 The texture object is redefined as though all its levels had been resized to |
| 43 zero by zero and the texture object is therefore incomplete. If the mailbox |
| 44 previously contained image data, the old image data is deleted. The state |
| 45 of the bound texture object is not saved in the mailbox, only the image |
| 46 data. |
| 47 |
| 48 If glProduceTextureCHROMIUM generates an error, the associated image data |
| 49 is preserved in the texture object. |
| 50 |
| 51 The mailbox is emptied and the texture image data deleted if the context |
| 52 is destroyed before being consumed. See glConsumeTextureCHROMIUM. |
| 53 |
| 54 <target> uses the same parameters as TexImage2D. |
| 55 |
| 56 <mailbox> identifies a GL_MAILBOX_SIZE_CHROMIUM byte sized name returned by |
| 57 glGenMailboxCHROMIUM. |
| 58 |
| 59 INVALID_OPERATION is generated if <target> is not a valid target. |
| 60 |
| 61 INVALID_OPERATION is generated if the texture is attached to a framebuffer. |
| 62 |
| 63 INVALID_OPERATION is generated if the texture is immutable. |
| 64 |
| 65 INVALID_OPERATION is generated if <mailbox> is invalid. |
| 66 |
| 67 |
| 68 void glConsumeTextureCHROMIUM (GLenum target, const GLbyte *mailbox) |
| 69 |
| 70 <target> uses the same parameters as TexImage2D. |
| 71 |
| 72 <mailbox> identifies a GL_MAILBOX_SIZE_CHROMIUM byte sized name returned by |
| 73 glGenMailboxCHROMIUM. |
| 74 |
| 75 Redefines the image data of the currently bound texture object with the |
| 76 image data in the mailbox and empties the mailbox. The state of the |
| 77 currently bound texture object is not modified, only the image data. All |
| 78 levels are redefined. |
| 79 |
| 80 If glConsumeTextureCHROMIUM generates an error, the associated image data |
| 81 is preserved in the texture object. |
| 82 |
| 83 INVALID_OPERATION is generated if <target> is not a valid target. |
| 84 |
| 85 INVALID_OPERATION is generated if <mailbox> is empty. |
| 86 |
| 87 INVALID_OPERATION is generated if <mailbox> is not in the scope of the |
| 88 context. |
| 89 |
| 90 INVALID_OPERATION is generated if <mailbox> is invalid. |
| 91 |
| 92 INVALID_OPERATION is generated if the texture is attached to a framebuffer. |
| 93 |
| 94 INVALID_OPERATION is generated if the texture is immutable. |
| 95 |
| 96 INVALID_OPERATION is generated if the image data is invalid in the current |
| 97 context. |
| 98 |
| 99 New Tokens |
| 100 |
| 101 The size of a mailbox name in bytes. |
| 102 |
| 103 GL_MAILBOX_SIZE_CHROMIUM 64 |
| 104 |
| 105 Errors |
| 106 |
| 107 None. |
| 108 |
| 109 New Tokens |
| 110 |
| 111 None. |
| 112 |
| 113 New State |
| 114 |
| 115 None. |
| 116 |
| 117 Revision History |
| 118 |
| 119 4/25/2011 Documented the extension |
OLD | NEW |