Pipeline Spring 2007 the Official ARB Newsletter Full PDF Print Edition

Pipeline Spring 2007 the Official ARB Newsletter Full PDF Print Edition

Issue 004 Pipeline Spring 2007 The official ARB Newsletter Full PDF print edition In This Issue: Climbing OpenGL Longs Peak, Camp 3 - An OpenGL ARB Update 1 Another Object Lessson . 5 Shaders Go Mobile:Announcing OpenGL ES 2.0 . 2 Transforming OpenGL Debugging to a “White Box” Model . 8 Longs Peak Update: Buffer Object Improvements . 3 Climbing OpenGL Longs Peak, Camp 3 More context creation options are available. In the previ- ous edition of OpenGL Pipeline I described how we are planning An OpenGL ARB Progress Update on handling interoperability of OpenGL 2. and Longs Peak code. As a result, the application needs to explicitly create an OpenGL Longs Peak or OpenGL 2.x context. To aid debugging, it is also possible to request the GL to create a debug context. A debug context is only intended for use during application development. It provides additional validation, logging and error checking, but possibly at the cost of performance. The object handle model is fleshed out. We finalized all the nitty-gritty details of the object model that have to do with ob- ject and handle creation and deletion, attachment of an object to a container object, and the behavior of these operations across contexts. Here is a brief summary: . The GL creates handles, not the application, as can be the case in OpenGL 2.. This is done in the name of ef- ficiency. 2. Object creation can be asynchronous. This means that th Longs Peak – 14,255 feet, 15 highest mountain in Colo- it is possible that the creation of an object happens later rado. Mount Evans is the 14th highest mountain in Colorado. in time than the creation of the handle to the object. A (Therefore, we have at least 13 OpenGL revisions to go!) call to an object creation routine will return the handle to the caller immediately. The GL server might not get Since the last edition of OpenGL Pipeline we’ve increased our to the creation of the actual object until later. This is efforts even more. We held a face-to-face meeting in March and again done for performance reasons. The rule that all another face-to-face meeting at the end of May. Currently we’re commands are executed in the order issued still applies on track to meet face-to-face six times this year, instead of the (within a given context). Thus, asynchronous object usual four! The ARB recognizes it is extremely important to get creation might mean that a later request to operate on OpenGL Longs Peak and Mount Evans done. We also still meet an object will have to block until the object is created. by phone five times per week. This is a big commitment from Fences and queries can help determine if this will be the our members, and I’m very happy and proud to see the graph- case. ics industry working together to make OpenGL the best graphics 3. Object use by the GL is reference counted. Once the platform! “refcount” of an object goes to zero, the GL implemen- tation is free to delete the storage of the object. Object A lot has happened since the last edition of Pipeline. Below creation sets the refcount to . follows a brief summary of the most important advances. Other 4. The application does not delete an object, but instead articles in this edition will go into more detail on some of the top- invalidates the object handle. The invalidation decre- ics. Happy reading! ments the object’s refcount. An object’s refcount is incremented whenever it is “in Maximize vertex throughput using buffer objects. Just like use.” Examples of “in use” include attaching an object in OpenGL 2., an application can map a buffer object in OpenGL to a container object, or binding an object into the con- Longs Peak. Mapping a buffer object returns a pointer to the ap- text. plication which can be used to write (or read) data to (or from) the 6. Once a handle is invalidated, it cannot be used to refer buffer object. In OpenGL Longs Peak the mapping is made more to its underlying object anymore, even if the object still sophisticated, with the end result that maximum parallelism can exists. be achieved between the application writing data into the buffer object and the GL implementation reading data out of it. Read more about this cool feature in an article later in this newsletter. OpenGL Pipeline, The Official ARB Newsletter | Spring 2007, Issue 004 Page Pipeline Pipeline The official ARB Newsletter The official ARB Newsletter Most context state will be moved into an object. We are A Lean, Mean, Shadin’ Machine… currently pondering which state stays in the context, and which context state is moved into an object. One interesting set of state Like its predecessors, OpenGL ES 2.0 is based on a version I want to highlight is the state for the per-fragment operations, of desktop OpenGL – in this case, OpenGL 2.0. That means, of described in Chapter 4 of the OpenGL 2. specification. This state course, that it supports vertex and fragment shaders written in a actually applies per sample, not per fragment. Think of state such high-level programming language. But almost as interesting as as alpha test, stencil test, depth test, etc. We expect that some what ES 2.0 has, is what it doesn’t have. As I said in the OpenGL time in the future hardware will be available that makes all these ES article in OpenGL Pipeline #3, one of the fundamental design operations programmable. Once that happens, we’ll define an- principles of OpenGL ES is to avoid providing multiple ways of other program object type, and would like to be able to just “drop achieving the same goal. In OpenGL 2.0 on the desktop, you can it in” to the framework defined in OpenGL Longs Peak. Therefore, do your vertex and fragment processing in shaders or you can we are working on defining a sample operation state object that use traditional fixed-functionality transformation, lighting, and contains all this state. texturing controlled by state-setting commands. You can even mix and match, using the fixed-functionality vertex pipeline with We’re also working on fleshing out the draw commands as a fragment shader, or vice versa. It’s powerful, flexible, and back- well as display lists. Good progress was made defining what ward compatible; but isn’t it, perhaps, a little bit… redundant? the draw calls will look like. We decided to keep it simple, and largely mirror what is done in OpenGL 2.. There will be DrawAr- One of the first (and toughest) decisions we made for OpenGL rays, DrawElements, etc. commands that take vertex indices. In ES 2.0 was to break backward compatibility with ES .0 and .. order to actually render, at least a program object, a vertex array We decided to interpret the “avoid redundancy” rule to mean object, and an FBO need to be bound to the context. Possibly a that anything that can be done in a shader should be removed from sample operation state object, as describe above, will also need the fixed-functionality pipeline. That means that transformation, to be bound. lighting, texturing, and fog calculation have been removed from the API. We even removed alpha test, since you can perform it You can meet the designers behind OpenGL Longs Peak and in a fragment shader using discard. Depth test, stencil test, Mount Evans at Siggraph 2007 in August. The traditional OpenGL and blending are still there, because you can’t perform them in a BOF (Birds of a Feather) will likely be on Wednesday evening, Au- shader; even if you could read the frame buffer, these operations gust 8th, from 6:00pm – 8:00pm. I hope to see you there! must be executed per sample, whereas fragment shaders work on fragments. In the remainder of this issue you’ll find an update from the OpenGL ES Working Group, a discussion of Longs Peak buffer ob- Living without the fixed-functionality pipeline may seem a ject improvements, a look at the Longs Peak object model with little scary, but the advantages are enormous. The API becomes source code samples, and an article showing how to use gDEBug- very simple and easy to learn – a handful of state-setting calls, ger as a window exposing what’s happening within the GL. plus a few functions to load and compile shaders. At the same time, the driver gets a lot smaller. An OpenGL 2.0 driver has to do a lot of work to let you switch back and forth smoothly between Barthold Lichtenbelt, NVIDIA fixed-functionality and programmable mode, access fixed-func- Khronos OpenGL ARB Steering Group chair tionality state inside your shaders, and so on. Since OpenGL ES 2.0 has no fixed-functionality mode, all of that complexity goes away. Shaders Go Mobile: …with Leather Seats, AC, and Cruise Control Announcing OpenGL ES 2.0 OpenGL ES 2.0 lacks the fixed-functionality capability of OpenGL It’s here at last! At the Game Developers Conference in March, ES .x, but don’t get the impression that it is a stripped-down, the OpenGL ES Working Group announced the release of OpenGL bare-bones API. Along with the shader capability, we’ve added ES 2.0, the newest version of OpenGL for mobile devices. OpenGL many other new features that weren’t available in ES .0 or .. ES 2.0 brings shader-based rendering to cell phones, set-top box- Among them are: es, and other embedded platforms.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    11 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us