Jump to content
  • Advertisement
Sign in to follow this  
ConfigSys

GL_POINT_SPRITE_ARB Texture Coords in GLSL

This topic is 4882 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi! I have some trouble generating the correct texture coordinates when drawing sprites in GLSL shaders. Afaik GLSL discards TexEnv setttings, so glTexEnvf( GL_POINT_SPRITE_ARB, GL_COORD_REPLACE_ARB, GL_TRUE ); does not have an influence. Currently my gl_TexCoord[0] is 0.0,0.0 for all fragments calculated, although the value is set to gl_MultiTexCoord0. The texture returns the correct value for any other texture coordinates i set manually. Anyone suggestions? Thanks for your help.

Share this post


Link to post
Share on other sites
Advertisement
point_sprites are useless (how the hell they made it inot gl2.0 i never know)
seems like youve discovered one of the many problems

Share this post


Link to post
Share on other sites
Using quads increases my vertexes significantly. My vertex shader calculates the position of the particles with a texture fetch from the position texture. Since the nv 6800 is limited to apox 40.000.000 texture fetches thats quite bad for my millions of particles.

Additionally, i know sprites work with shaders, i've seen demos. I just don't know what i did wrong.

Share this post


Link to post
Share on other sites
According to "OpenGL(R) Shading Language" by Randi J. Rost, the glTexEnv calls influence the states of the fixed function pipeline, but not the shader. It does not return an error and does not change the result if commented out.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!