3 Replies Latest reply on Feb 2, 2009 2:16 PM by avk

    Shader language problem

    rajeshdmonte

      Hi,


      I'm been making my game using C++/OpenGL/ and NVIDIA Cg language.

      The nvidia specific profile seems fine for nvidia cards, but all my sm3/sm4 shaders dont' work on ATI hardware, since they are nvidia specific profiles, right now I'm running on ARBVP1 and ARBFP1 profiles but that doesn't have much shader instruction length, so the shaders are limited, I would love to know a solution to support ATI hardware as well. Right now all my shaders are in NVIDIA Cg, porting to directX is not possible right now, so is there a way to run HLSL like code (Cg) on ATI hardware through OpenGL?

       

      Thanks!

        • Shader language problem
          avk
          Did you visit that page?
            • Shader language problem
              rajeshdmonte

              yes I have already. my closest bet is the HLSL2GLSL converter. And seeing as Cg is the same as HLSL, I guess that should help, but still I would preferably like to use the HLSL/Cg effect framework, does ATI have the equivalent?

               

              Most ATI examples that are next gen use Dx10/10.1 with HLSL but I'm not targetting Vista only, I hope to have my game running on Mac, Linux if possible, WinXP and Vista through OpenGL. Right now I develope on XP SP2/ubuntu 8.xx and I am able to use all Dx10 level features like geometry shaders on both operating systems in Cg, OpenGL on Nvidia Hardware.

              Is there an Effect framework for ATI hardware? Whats the best workaround you recommend?

               

              Edit: Also HLSL2GLSL failed to convert, I guess this was due using #includes in the Effect file

            • Shader language problem
              avk
              Alas, I'm not a graphics programmer, so I can't help you. Maybe you could find some useful information by downloading the Previous SDK (March 2006), although I don't think so . Let me wish you good luck and I hope that someone graphics programmer will help you .