How to increase size of particle?
in
Contributed Library Questions
•
2 years ago
Hiii,
I am implementing an application in processing in which I am using glDrawArrays function of openGL with mode as GL.GL_TRIANGLES.
for(int i=0; i<maxParticles; i++)
{
if(particles[i].alpha > 0)
{
particles[i].update();
particles[i].updateVertexArrays(i, posArray, colArray);
}
}
gl.glEnableClientState(GL.GL_VERTEX_ARRAY);
gl.glVertexPointer(2, GL.GL_FLOAT, 0, posArray);
gl.glEnableClientState(GL.GL_COLOR_ARRAY);
gl.glColorPointer(3, GL.GL_FLOAT, 0, colArray);
// gl.glScalef(1.7,1.7,0.5);
gl.glDrawArrays(GL.GL_TRIANGLES, 0, maxParticles * 2);
I want to increase the size of particles of the triangle.For this I tried to use glScalef function too but after using this particles are not rendered at mouseX and mouseY position,rather the position has been translated.
Can anyone please help me out.
1