Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Page 17 of 173 FirstFirst ... 715161718192767117 ... LastLast
Results 161 to 170 of 1724

Thread: OpenGL 3 Updates

  1. #161
    Senior Member OpenGL Guru
    Join Date
    Dec 2000
    Location
    Reutlingen, Germany
    Posts
    2,052

    Re: OpenGL 3 Updates

    OpenGL 2 has always been object oriented. For example textures are objects. Display lists are objects etc. Only the more recent things like framebuffers and shaders were implemented in a way that seemed to please the ARB more than the previous approach.

    Only the PIPELINE has been configured with a state-machine. OpenGL 3 will do this a bit differently, but i think that there will still be some kind of small state-machine left. Otherwise it would be too much state to pass to each draw-call.

    Jan.
    GLIM - Immediate Mode Emulation for GL3

  2. #162
    Member Regular Contributor
    Join Date
    Apr 2007
    Location
    Fairfax, VA
    Posts
    252

    Re: OpenGL 3 Updates

    I was asking in terms of what the syntax would look like. I'd imagine ARB wouldn't want it to vary too much between languages.

  3. #163
    Senior Member OpenGL Pro Zengar's Avatar
    Join Date
    Sep 2001
    Location
    Germany
    Posts
    1,979

    Re: OpenGL 3 Updates

    You can find examples of syntax in the pipeline newsletters (like here: http://www.opengl.org/pipeline/article/vol003_4/ ). It won't be much different from current one.

  4. #164
    Senior Member OpenGL Guru
    Join Date
    Mar 2001
    Posts
    3,768

    Re: OpenGL 3 Updates

    OpenGL 2 has always been object oriented.
    Aside:

    Object orientation does not mean, "It uses objects." Object orientation is about the coupling of data and the code that directly affects that data, the binding of information and interface. It also refers to the notion of encapsulation, data hiding, and most importantly, polymorphism. If you're not doing all of these, it isn't object oriented.

    OpenGL, either 2.x or 3.0, doesn't use enough of these to qualify.

    It won't be much different from current one.
    Actually, it's quite a bit different.

    GL 2.x and all prior versions shoehorned the concept of objects onto its state-based design through the concept of binding. This provided a notion of a global "current object" that all state-based commands pertaining to that object's state could modify. Thus, the basic API would be no different when using objects than when not using objects.

    GL 3.0 is an object-based (note: this is separate from object-oriented) system. Binding exists for the sole purpose of rendering; to bind an object is to express the intent to use it for rendering in the immediate future. Functions that change the state of an object take that object as a parameter. That way, an implementation does not have to guess as to why you bound that object to the context.

    This seems like a subtle difference, but ultimately, it's pretty substantial. It's the single most important change, the one that necessitated many other changes to the API to the point where GL 3.0 because an entirely new API.

  5. #165
    Senior Member OpenGL Guru Humus's Avatar
    Join Date
    Mar 2000
    Location
    Stockholm, Sweden
    Posts
    2,444

    Re: OpenGL 3 Updates

    Quote Originally Posted by Timothy Farrar
    ARB_fragment_program, ARB_vertex_program, and now NV_gpu_program4 for the G8x?
    These extensions are very generic and at least on ATI cards they pass through the same optimizer as the GLSL ones, and DX shaders too for that matter. I'd say they aren't very close to hardware at all. The danger with high level languages is that it hides too much, so even an experienced developer could write bad code, because it's a black box. I don't think an assembly language is very useful, but insight into what happens under the hood is indeed very useful. For anyone with an ATI card I really recommend the GPU Shader Analyzer, it's the performance tool I've used the most by far. There you get to view the GPU assembly code (as in the real hardware instructions and not ARB_fp or something like that), and it supports GLSL and ARB_fp/ARB_vp shaders. Definitely recommended!

  6. #166
    Senior Member OpenGL Guru Humus's Avatar
    Join Date
    Mar 2000
    Location
    Stockholm, Sweden
    Posts
    2,444

    Re: OpenGL 3 Updates

    To further elaborate, one important difference between ARB_fp and what the hardware really does is that ARB_fp doesn't take the mini-alu into account that all R300-R580 hardware is equiped with, nor does it take the general pipeline configuration into account, like the 3+1 setup of all R300-R580 that allows it to schedule scalar instructions in parallel with vectors, or the fact that some common constants can be applied to arguments. To take a random example, this shader may seem like it should generate three instructions or so:
    Code :
    varying vec3 var;
     
    void main(){
    	gl_FragColor = vec4(vec3(dot(var - 0.5, var)), var.y * 0.25);
    }

    In fact, as you can see with GPU ShaderAnalyzer, it evaluates to a single ALU instruction slot:
    Code :
    0 alu 00 pre:  srcp.rgb = 1.0-2.0*r00.rgb
    0 alu 00 rgb:  out0.rgb =           dp3(r00.rgb, neg(srcp.rgb))/2 sem_wait
           alpha:  out0.a   =           mad(r00.g, 1.0, 0.0)/4 last

    The first line uses the mini-alu to compute 1.0 - 2.0 * var (which is -2 * (var - 0.5)). This is negated and divided by two together with the dot-product to get the right result. In parallel on the scalar unit var.y * 0.25 is computed.

  7. #167
    Intern Contributor
    Join Date
    May 2007
    Posts
    53

    Re: OpenGL 3 Updates

    How long the GL3.0 will released?After a week,two week or a month?Can disclose more details on the GL3.0 API and GLSL1.3 that has already determined function.example for the realizing of program parameter buffer or GS of functions in GL API and GLSL.
    Code :
    GLbuffer image = glCreateImage(template);
    glImageData2D(image,0,0,0,256,256,GL_RGBA,GL_UNSIGNED_BYTE,data);
    That means the glGenTextures, glBindTexture,glTexImage2D and and all texture functions will be changed of current version of GL? Why not called glCreateTexBuffer but glCreateImage?

  8. #168
    Junior Member Regular Contributor Roderic (Ingenu)'s Avatar
    Join Date
    Mar 2000
    Location
    Horsham, West Sussex, UK.
    Posts
    161

    Re: OpenGL 3 Updates

    I've asked for a draft to have a clue of how things will work and write preliminary implementation/design in existing code...
    But nothing went.
    -* So many things to do, so little time to spend. *-

  9. #169
    Intern Contributor
    Join Date
    Nov 2007
    Posts
    72

    Re: OpenGL 3 Updates

    Any idea where can I get even alpha/beta builds? I really want to use OpenGL3 from now...

  10. #170
    Senior Member OpenGL Pro Zengar's Avatar
    Join Date
    Sep 2001
    Location
    Germany
    Posts
    1,979

    Re: OpenGL 3 Updates

    You haven't read the thread, did you? There is not even a spec yet, what "alpha builds" are you talking about?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •