Results 1 to 3 of 3

Thread: prog Work but # is Complicated Cg

  1. #1
    Senior Member Regular Contributor
    Join Date
    Apr 2009
    Posts
    171

    prog Work but # is Complicated Cg

    please reply to this
    hiiiiii
    i just come at point of compile Cg .cg(progs byfew change of gl_Fra/gl_Po in file)

    when i compiled 01Vertex_Program's cg program
    by these of changes i get
    file
    both below code for work in fragment progs
    Code :
    !!ARBfp1.0\
    # cgc version 2.2.0006, build date Mar 31 2009\
    # command line args: -oglsl -profile arbvp1 -profile arbfp1\
    # source file: C2E1v_green.cg\
    #vendor NVIDIA Corporation\
    #version 2.2.0.6\
    #profile arbfp1\
    #program C2E1v_green\
    #var float4 gl_FragColor : $vout.COLOR : COL : -1 : 1\
    #const c[0] = 0 1\
    PARAM c[1] = { { 0, 1 } };\
    MOV result.color, c[0].xyxx;\
    END\
    # 1 instructions, 0 R-regs
    which not work on assginment(char object)

    but when i make it to
    Code :
    !!ARBfp1.0\
    PARAM c[1] = { { 0, 1 } };\
    MOV result.color, c[0].xyxx;\
    END
    then it workssss

    but
    #..
    line must be used in comments

    but for green color i need to use fragment profile(with gl_Frag change)

    but cg use it directly in the vertex program && profile

    thanks for reading/thinking/helping

    thanks in advance


    apologies for grammer
    N being language barrier
    haven't made a game [img]<<GRAEMLIN_URL>>/frown.gif[/img]

  2. #2
    Senior Member OpenGL Guru
    Join Date
    Oct 2004
    Posts
    4,655

    Re: prog Work but # is Complicated Cg

    You're interpretation is being totally lost (on me) in the language barrier. I'd suggest you post 1) your shader program source, and 2) what the error message is that you're getting, and we'll try to help you out.

    However, the one thing that seems like an obvious error from your assembly source is all the line continuation (\) characters:

    Code :
    # a comment\
    Some code \
    More code \
    stuff
    Because you've used \ at the end of the line, a standard preprocessor is going to join all the lines together, and you're going to get that entire file just being one big long comment. That is:

    Code :
    # a comment Some code More code stuff

  3. #3
    Senior Member Regular Contributor
    Join Date
    Apr 2009
    Posts
    171

    Re: prog Work but # is Complicated Cg

    thank you very very very much
    (my English is non-understandable but u still help me you are really really really great!!)
    haven't made a game [img]<<GRAEMLIN_URL>>/frown.gif[/img]

Similar Threads

  1. OpenGL doesn't work in multithreaded prog, why?
    By arffie in forum OpenGL: Linux
    Replies: 1
    Last Post: 02-07-2008, 01:50 PM
  2. Replies: 17
    Last Post: 06-06-2005, 01:53 PM
  3. Complicated question....
    By reubenhwk in forum OpenGL: Advanced Coding
    Replies: 6
    Last Post: 11-15-2003, 04:10 PM
  4. i'm thinking too complicated....
    By imported_sebastian in forum OpenGL: Advanced Coding
    Replies: 4
    Last Post: 06-07-2000, 11:22 AM
  5. prog doesn't work on other machine
    By markl in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 05-30-2000, 07:02 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean