Home > Software engineering > Opengl only Sprite rendering displays only the background color patterns can be displayed
Opengl only Sprite rendering displays only the background color patterns can be displayed
Time:10-29
A particle simulation code, which is based on improved on the basis of the former, the former use fixed line VBO paint particles, glbegin and glend can also display at the same time, the latter with shader draws a two-dimensional manual control of the particle number display function, and then continue to use fixed line drawing, have been determined using glUseProgram (0), however VBO doesn't show, only a 2 d shader content and background color, and only when you start the Sprite mode can see particles, is this excuse me what is the principle? Related to drawing speed? I saw the little particle velocity can reach 90 fp/s, not to say that Windows typically refresh 60 times per second, the data is there a problem? In addition both code using cuda acceleration, but map data is transferred to the CPU to draw, this matter? This problem I really struggled for a long time, hope to have a great god proposed own view, at least let me have a try, thanks!
CodePudding user response:
The point as a quality, then execute the program of particle shader.
CodePudding user response:
Thank you, excuse me, can,,, you understand it? To perform VBO draw shader?