Jump to content

  • Log In with Google      Sign In   
  • Create Account


geometry shader to pixel shader


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
3 replies to this topic

#1 the dodger uk   Members   -  Reputation: 148

Like
1Likes
Like

Posted 28 February 2013 - 01:06 PM

is there a way  to send a  int number or bool to the pixel shader from the geometry shader

 

i been writing a  geometry shader for grass , which expands  a point to a grass which has 4 quads which are all created on the geometry shader.

 

now  these all texture colour correctly . now  is there a way to send a  bool from the geometry shader to the pixel shader so that it will then texture sample from a  picture of a flower, 

 

so that the grass can either be  grass or  grass with a flower head at the end of it 

 

 

 

 



Sponsor:

#2 MJP   Moderators   -  Reputation: 10832

Like
0Likes
Like

Posted 28 February 2013 - 01:43 PM

You can send whatever you want, but it has to be as vertex data. So you'd have to add that bool to each vertex that you emit from the geometry shader.



#3 the dodger uk   Members   -  Reputation: 148

Like
0Likes
Like

Posted 28 February 2013 - 01:47 PM

You can send whatever you want, but it has to be as vertex data. So you'd have to add that bool to each vertex that you emit from the geometry shader.

how can i access the vertex data from the geometry shader ,  they  take in compleatly differnt data



#4 the dodger uk   Members   -  Reputation: 148

Like
0Likes
Like

Posted 28 February 2013 - 02:18 PM

cheers , just figured out what you mean and how to do it  :)

thank you 






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS