Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 2 of 2

Thread: DX9, DX10, GL2.1 and GL3 wrapper (w.r.t. shaders)

  1. #1
    Junior Member Regular Contributor
    Join Date
    Sep 2002
    Location
    Germany
    Posts
    205

    DX9, DX10, GL2.1 and GL3 wrapper (w.r.t. shaders)

    Based on the interface of DX10 (and I guess and hope the upcoming GL3 API will be very similar) it would be easy to write a thin wrapper for DX9, DX10, GL2.1 and GL3 backends on a rendering device level.

    The heardest problem will be to overcome the differences in the shading languages. How do you deal with this problem? Using CG? Using another intermediate language? Writing shaders twice.

  2. #2
    Senior Member OpenGL Pro
    Join Date
    Sep 2004
    Location
    Prombaatu
    Posts
    1,401

    Re: DX9, DX10, GL2.1 and GL3 wrapper (w.r.t. shaders)

    Yep, or writing your own "shading language" is a possibility, then translate it to any flavor you like. Of course then you've inherited the hassle of having to maintain it. Leveraging or preferring one language in particular and translating it to another is a way to go (there are some tools for this already).

    It's a problem but there are lots and lots of possibilities. I personally have a very high level script of sorts I convert to a shader on the fly; falls somewhere short of a complete language though....

Posting Permissions

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