Well, maybe I could show more in detail what I'm doing. As I wrote earlier, it's just the VBO implementation that doesn't work: glMultiDrawElements in CPU mode work just fine.
// fill array...
Type: Posts; User: Alessandro_dup1
Well, maybe I could show more in detail what I'm doing. As I wrote earlier, it's just the VBO implementation that doesn't work: glMultiDrawElements in CPU mode work just fine.
// fill array...
Hi V-man, thanks for the answer and sorry for the typo.
I wrote
glVertexPointer(3, GL_FLOAT, 0, verts); because it was like that for the non-VBO version; obviously that is
glVertexPointer(3,...
I'm currently using glMultiDrawElements rendering arrays directly:
glPushMatrix();
glEnableClientState( GL_VERTEX_ARRAY );
glVertexPointer(3, GL_FLOAT, 0, verts);...
That's why I posted in the Math and Algorithms forum.
Hi, I'd like to ask some help and suggestions about simulating hair physics (so basically pulling hair vertices around, and smoothly disposing the adjacent ones).
Please take a look at the...
Thanks, I'm going to check those!
I have developed a small opengl application that allows to pick an object in the viewport. I'd like to move such object in 3D space, dragging it around with the mouse.
In the first image...
I'm totally confused.
What drives me crazy is that I'm so dumb to figure out what it seems to be such an easy problem.
I mean, let's forget opengl for a moment.
I have an object rotated in...
Arts, when you write M, you mean I should do the following?
float *M;
M= new float[16];
glGetFloatv( GL_MODELVIEW_MATRIX, M ); // Get the current MODELVIEW matrix from OpenGL
Thanks
Starting from 3 angles, I'm trying to create a global rotation matrix and get the angles back again.
First of all, I calculate a global rotation matrix multiplying the 3 angles rotation matrices
...
Maybe I should have given more info about what I'm trying to accomplish, I've the feeling I've created a chaotic thread and instead of posting/asking code I should have explained more in detail what...
Here is the code I came up with. It still doesn't work, because the world rotation angles do not produce the same rotation as the local ones.
float xRot=45.0*DEG_TO_RAD;
float...
Thank you very much, will try this...
I'm developing a plugin for an application called Daz Studio (more info here, if you are curious: INFINITO plugin), using QT and OpenGL.
In the plugin glWidget, my object rotates using the local...
Also this is a nice solution, thanks!
Max, I think the solution you suggested is the one I will follow. Thanks to everybody for your kind help!
Sorry for not being more precise. Here is a screenshot: we have a point P, whose coordinates are known (retrieved with glReadPixels).
I'd like to calculate the normal of the triangle where P is...
I have an irregular 3D mesh (meaning that is not a regular grid) and I have a glReadPixel routine that return the x,y,z coordinates of a point P clicked on the 3D mesh.
I'd like to calculate the...
Thanks BionicBytes, I'm going to do some experiments!
Sorry but I don't understand: in the above example, it seems to me that the gMouseInteractor function rotates the camera and so the view matrix has to be recalculated.
That's what I don't...
I'm trying to implement the glsl_pseudo_instancing nvidia example in my terrain engine project.
I've already setup the proper initialization routines (loading the shaders etc.) but I'd like to ask...
Thanks for the answer and sorry for my ignorance on this matter. So you say that even if I rotate or translate the terrain, the values should always be the same ?
My aim would be to gather the...
Hi, I have a simple function that returns the World coordinate when I click on a terrain mesh (a regular grid made of 4x4 quads), in the gl viewport:
GLfloat wx, wy, wz; ...
Well, this is probably a stupid question but: suppose you have scene with a terrain engine and some objects, and that i want to use shadows, lighting, bump mapping and more effects.
How should be...
Hi, i'm trying to make projective textures with shaders. I have the issue that the projected texture applied to the object is actually moving inside it as i move the camera. I suppose there is an...