15bd8deadSopenharmony_ciName
25bd8deadSopenharmony_ci
35bd8deadSopenharmony_ci    QCOM_writeonly_rendering
45bd8deadSopenharmony_ci
55bd8deadSopenharmony_ciName Strings
65bd8deadSopenharmony_ci
75bd8deadSopenharmony_ci    GL_QCOM_writeonly_rendering
85bd8deadSopenharmony_ci
95bd8deadSopenharmony_ciContributors
105bd8deadSopenharmony_ci
115bd8deadSopenharmony_ci    Benj Lipchak (Original Author)
125bd8deadSopenharmony_ci    Maurice Ribble
135bd8deadSopenharmony_ci
145bd8deadSopenharmony_ciContact
155bd8deadSopenharmony_ci
165bd8deadSopenharmony_ci    Maurice Ribble (mribble 'at' qualcomm.com)
175bd8deadSopenharmony_ci
185bd8deadSopenharmony_ciNotice
195bd8deadSopenharmony_ci
205bd8deadSopenharmony_ci    Copyright Qualcomm 2009.
215bd8deadSopenharmony_ci
225bd8deadSopenharmony_ciIP Status
235bd8deadSopenharmony_ci
245bd8deadSopenharmony_ci    Qualcomm Proprietary.
255bd8deadSopenharmony_ci
265bd8deadSopenharmony_ciStatus
275bd8deadSopenharmony_ci
285bd8deadSopenharmony_ci    Complete.
295bd8deadSopenharmony_ci
305bd8deadSopenharmony_ciVersion
315bd8deadSopenharmony_ci
325bd8deadSopenharmony_ci    Last Modified Date: July 7, 2009
335bd8deadSopenharmony_ci    Revision: #2
345bd8deadSopenharmony_ci
355bd8deadSopenharmony_ciNumber
365bd8deadSopenharmony_ci
375bd8deadSopenharmony_ci    OpenGL ES Extension #61
385bd8deadSopenharmony_ci
395bd8deadSopenharmony_ciDependencies
405bd8deadSopenharmony_ci
415bd8deadSopenharmony_ci    OpenGL ES 1.0 is required.
425bd8deadSopenharmony_ci
435bd8deadSopenharmony_ci    This extension is written against the OpenGL ES 2.0 specification.
445bd8deadSopenharmony_ci
455bd8deadSopenharmony_ciOverview
465bd8deadSopenharmony_ci
475bd8deadSopenharmony_ciThis extension defines a specialized "write-only" rendering mode that
485bd8deadSopenharmony_cimay offer a performance boost for simple 2D rendering.
495bd8deadSopenharmony_ci
505bd8deadSopenharmony_ciSome applications render large frame buffers with simple geometry, very
515bd8deadSopenharmony_cilittle overdraw, and no need for the following per-fragment stages:
525bd8deadSopenharmony_cidepth/stencil testing, Multisampling, blending, and Logic Operations.
535bd8deadSopenharmony_ciApplications rendering a windowed desktop or other 2D GUI might fit
545bd8deadSopenharmony_ciinto this profile.
555bd8deadSopenharmony_ci
565bd8deadSopenharmony_ciApplications that match this profile can enable ``write-only'' rendering
575bd8deadSopenharmony_cimode.  Performance may be improved in this mode through single-pass
585bd8deadSopenharmony_cirendering directly to system memory as compared with multipass tile-based
595bd8deadSopenharmony_cirendering into on-chip memory.  However, since the write-path to system memory
605bd8deadSopenharmony_ciis generally lower bandwidth, any gains are most likely for 2D applications
615bd8deadSopenharmony_cirendering to large frame buffers with little overdraw.
625bd8deadSopenharmony_ci
635bd8deadSopenharmony_ciOn some HW, the GPU is not able to simultaneously read and write to system
645bd8deadSopenharmony_cimemory framebuffers, so enabling this mode also implicitly disables any per-
655bd8deadSopenharmony_cifragment operations that may read from the frame buffer.  In addition, this
665bd8deadSopenharmony_cimode implicitly disables any reads and writes from the depth buffer.
675bd8deadSopenharmony_ci
685bd8deadSopenharmony_ciTo enable write-only rendering, an OpenGL application will call
695bd8deadSopenharmony_ciglEnable(GL_WRITEONLY_RENDERING_QCOM).  When write-only rendering is enabled,
705bd8deadSopenharmony_cithe following per-fragment stages are disabled regardless of the associated
715bd8deadSopenharmony_ciGL enables:  multisample, depth_test, stencil_test, blending, and color_logic_Op.
725bd8deadSopenharmony_ciIn addition, write-only rendering will implicitly disable all depth writes
735bd8deadSopenharmony_ciregardless of the value set via glDepthMask().    The alpha_test and scissor_test
745bd8deadSopenharmony_cistages function as normal.
755bd8deadSopenharmony_ci
765bd8deadSopenharmony_ciTo disable fast-rendering, call glDisable(GL_ WRITEONLY_RENDERING_QCOM).  Any
775bd8deadSopenharmony_cistages previously disabled by write-only rendering will return to their current
785bd8deadSopenharmony_ciGL state.
795bd8deadSopenharmony_ci
805bd8deadSopenharmony_ciIP Status
815bd8deadSopenharmony_ci
825bd8deadSopenharmony_ci    There is no intellectual property associated with this extension.
835bd8deadSopenharmony_ci
845bd8deadSopenharmony_ciIssues
855bd8deadSopenharmony_ci
865bd8deadSopenharmony_ci(1)  How can alpha-blending be implemented with write-only rendering?
875bd8deadSopenharmony_ci
885bd8deadSopenharmony_ciRESOLVED:  For ES2.0 applications that want to use write-only rendering combined
895bd8deadSopenharmony_ciwith alpha-blending, this must be done in the GLSL fragment shader, by binding the
905bd8deadSopenharmony_ciRT as a texture.  Application will handle all coherency issues using glFinish().
915bd8deadSopenharmony_ci
925bd8deadSopenharmony_ci(2)  Can write-only logicOps be supported?
935bd8deadSopenharmony_ci
945bd8deadSopenharmony_ciRESOLVED:  It is possible we could allow some LogicOps (those that don't need to
955bd8deadSopenharmony_ciread from the destination).  For simplicity, the extension doesn't allow any LogicOps
965bd8deadSopenharmony_ciwith write-only rendering.
975bd8deadSopenharmony_ci
985bd8deadSopenharmony_ci(3)  Can Multisample be supported?
995bd8deadSopenharmony_ci
1005bd8deadSopenharmony_ciRESOLVED:  Write-only rendering with multisampling enabled may not work on
1015bd8deadSopenharmony_ciall HW.  For now, MSAA is not allowed with WRITEONLY_RENDERING.
1025bd8deadSopenharmony_ci
1035bd8deadSopenharmony_ci(4)  Can the depth or stencil buffer be cleared while write-only rendering is
1045bd8deadSopenharmony_cienabled?
1055bd8deadSopenharmony_ci
1065bd8deadSopenharmony_ciRESOLVED:  No, while write-only rendering is enabled, all reads and writes to the
1075bd8deadSopenharmony_cidepth/stencil buffer implicitly disabled.  Clears of the depth buffer are ignored.
1085bd8deadSopenharmony_ciFor example, calling glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT |
1095bd8deadSopenharmony_ciGL_STENCIL_BUFFER_BIT) would only clear the color buffer.
1105bd8deadSopenharmony_ci
1115bd8deadSopenharmony_ci
1125bd8deadSopenharmony_ciNew Procedures and Functions
1135bd8deadSopenharmony_ci
1145bd8deadSopenharmony_ci
1155bd8deadSopenharmony_ciNew Tokens
1165bd8deadSopenharmony_ci
1175bd8deadSopenharmony_ci    Accepted by the <cap> parameter of Enable, Disable, and by the
1185bd8deadSopenharmony_ci
1195bd8deadSopenharmony_ci        WRITEONLY_RENDERING_QCOM                      0x8823
1205bd8deadSopenharmony_ci
1215bd8deadSopenharmony_ci
1225bd8deadSopenharmony_ci    None.
1235bd8deadSopenharmony_ci
1245bd8deadSopenharmony_ci
1255bd8deadSopenharmony_ciAdditions to Chapter 4 of the OpenGL 1.4 Specification (Per-Fragment
1265bd8deadSopenharmony_ciOperations and the Frame Buffer)
1275bd8deadSopenharmony_ci
1285bd8deadSopenharmony_ci    TBD
1295bd8deadSopenharmony_ci
1305bd8deadSopenharmony_ciAdditions to Chapter 5 of the OpenGL 1.4 Specification (Special
1315bd8deadSopenharmony_ciErrors
1325bd8deadSopenharmony_ci
1335bd8deadSopenharmony_ci    None.
1345bd8deadSopenharmony_ci
1355bd8deadSopenharmony_ciNew State
1365bd8deadSopenharmony_ci
1375bd8deadSopenharmony_ci
1385bd8deadSopenharmony_ciGet Value                                 Type            Command      Value
1395bd8deadSopenharmony_ci---------                                 ----            -------     -------
1405bd8deadSopenharmony_ciWRITEONLY_RENDERING_QCOM                  bool          IsEnabled
1415bd8deadSopenharmony_ci
1425bd8deadSopenharmony_ci
1435bd8deadSopenharmony_ciRevision History
1445bd8deadSopenharmony_ci#03    09/30/2009    Maurice Ribble     Fixed some AMD stuff I missed.
1455bd8deadSopenharmony_ci#02    07/07/2009    Maurice Ribble     Update due to the AMD->Qualcomm move.
1465bd8deadSopenharmony_ci#01    ??            Benj Lipchak       Initial version.
147