Results 1 to 3 of 3

Thread: Gallium3D programming example

  1. #1
    Join Date
    May 2012
    Posts
    2

    Question Gallium3D programming example

    Hi,
    I've been seeing a lot of posts on the web about Gallium3D, but I'm not really sure how it is working (especially Direct3D part). The only thing I understand is that if I run a Direct3D game through Wine I can get native rendering if I got supporting graphic card drivers on Linux.

    What I'd like to know is how to write a simple Direct3D program in C on Linux that will use Gallium3D. I tried to google it, but found nothing.

    Thank you

  2. #2
    Join Date
    Oct 2007
    Location
    Toronto-ish
    Posts
    7,287

    Default

    You want to search for info on the Direct3D State Tracker, eg :

    http://www.phoronix.com/scan.php?pag...tem&px=MTAzMDA

    Gallium3D provides a "hardware layer" (standard interface for HW drivers) which supports a number of different state trackers, each implementing one or more higher level APIs. The most commonly used state tracker is for OpenGL, but there are others as well.

    Wine normally operates by translating Direct3D calls into OpenGL calls then calling the OpenGL driver (which may in turn use Gallium3D as a hardware layer), but in principle Wine could include the Direct3D state tracker and pass the Direct3D calls to it instead. Not sure of the status of that - you may still have to build the Direct3D state tracker yourself from source (see source link in article above).

    For programming examples I guess the best place to start would be the test programs in the state tracker tree :

    http://cgit.freedesktop.org/mesa/mes...rs/d3d1x/progs

  3. #3
    Join Date
    May 2012
    Posts
    2

    Default

    Thank you very much.

    Simple answer and very helpful

Posting Permissions

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