ff8

Members
  • Content count

    591
  • Joined

  • Last visited

Community Reputation

134 Neutral

About ff8

  • Rank
    Advanced Member
  1. OpenGL Alpha Blending problem

    Well maybe the University PCs' GFXs cards are too old cause : Quote: glBlendEquation is part of the GL_ARB_imaging subset. glBlendEquation is present only if GL_ARB_imaging is returned when glGetString is called with GL_EXTENSIONS as its argument. source : http://pyopengl.sourceforge.net/documentation/manual/glBlendEquation.3G.html
  2. OpenGL OpenGL camera problem

    Well could at least put the actual numerical example for the problem?
  3. OpenGL OpenGL camera problem

    Well then if are rotating one vector i assume you are recalculating the others cause as you said when you rotate in Y-axis the Up vector shouldn't be affected but in case of other Axises such X or Z then you have to recalculate them.
  4. OpenGL OpenGL camera problem

    Hey, Is the rotating done on the vectors then passing them to gluLookAt(or sort of) or is it calling glRotate ? Well could you provide a piece of code that will help in understanding the issus?
  5. Hey, matrices multiplication is an expansive process so try to avoid using it that much especially when you are using fixed functions (glRotate,...) so try : 1) using Vertex Shader. 2) utilizing all matrices operations on CPU side before using it. well this is as far as i can think about.
  6. Hey , Well it seems that you didn't disable the background texture when you try to render the foreground objects use glDisable/glEnable for it.
  7. Quote:Original post by loufoque Quote:It's been said over and over that impossible to design a system without faults False premise. As a matter of fact, there are ways to prove programs are correct with formal methods, and designing programs without them by using instead test-driven development often leads to quite correct programs as well. i don't think so you can't secure program to have no bugs in it, BUT you try to make it secure enough if i am a manager in MMORPG team i would focus on game elements more than the security(not to be manic but to make it secure enough).
  8. try bounding(Box/Sphere/Object/...)[still intersection testing] and try to use some sort of ordering to pick them based on distenace or something like that. check BSP Tree or so. take care,
  9. The Dot Product Question

    Quote:Original post by BlackDuck CLICK! To my lecturer who may be reading this. I do not mind you giving me a zero for this question. I needing to know this as it is very important to understand. Thank you Black Knight. Pravo! /clap
  10. The Dot Product Question

    hey there , if you only asking about how far P3 from the plane (P1,n`) simple you need to find |P3-P1| take care,
  11. OpenGL Opengl Vertex Array

    Hey, simply u can send anytype of structures into the gl*Pointer() only if there is some unrealited data between the needed data u just need to define the offset , so if the have this struct ex. : class vertex{ public : float x,y,z; float r,g,b; } vertex someobject[x]; then ur glVertexPointer() calling will be like this: glVertexPointer(3, GL_FLOAT, 3*sizeof(float), someobject); about the vector class i really don't know how this will be like =\ cause i have never used it b4 usually i make my own stuffs . take care. Edit: i just forgot if u have mixed structure like the one above u should use glInterleavedArrays() and it is better for u to separate every component into its own array for performance issue.
  12. hey , 1) what kind of gfx do u have it? 2) do u have the latest driver? 3) which Window API are u using? 4) what is the setup code for the device ? 5) how can u setup the texutre in ogl?
  13. hey, like MARS_999 said in : gluPerspective(45.0f,(GLfloat)width/(GLfloat)height,0.1f,100.0f); make the znear >= 1 take care.
  14. Quote: ..im planning to make a "Mario" game..but for me its... uhmmmm,,,,i dont know..maybe BORING.. O_O;; Mario isn't BORING.. take care..!
  15. Hello everyone, i am trying these days to implement a camera system so i get rid of gluLookAt() >.>;; so i started building the modelview matrix and it worked after testing values on my owe matrix and using gluLookAt() after that i decide to implement simply operations on the camera (pitch,yew,slide,roll) then when i tested it i didn't face any problem until i do 2 operations in row like pitch -> roll or roll -> yew the camera goes crazy >.>;; i tried everything to figure the problem but no luck = i hope anyone can help me = code : void setupMVMatrix(){ float tmp[16]; ModelView.arrMat[0]=u.x; ModelView.arrMat[1]=u.y; ModelView.arrMat[2]=u.z; ModelView.arrMat[3]=-eye.Dot3(u); ModelView.arrMat[4]=v.x; ModelView.arrMat[5]=v.y; ModelView.arrMat[6]=v.z; ModelView.arrMat[7]=-eye.Dot3(v); ModelView.arrMat[8]=n.x; ModelView.arrMat[9]=n.y; ModelView.arrMat[10]=n.z;ModelView.arrMat[11]=-eye.Dot3(n); ModelView.SetOpenGLMatrix(tmp); glMultMatrixf(tmp); } void setupCamera(_3DVECTOR<float> Eye,_3DVECTOR<float> Look,_3DVECTOR<float> Up){ eye=Eye; look=Look; up=Up; n=look; n.normalize(); n=n.operator *(-1); u.CrossProduct(up,n); u.normalize(); v.CrossProduct(n,u); v.normalize(); U=u;V=v;N=n;EYE=eye; setupMVMatrix(); } void slide(float du,float dv,float dn){ eye =EYE+u*du+v*dv+n*dn; } void roll(float angle){ u= U*cosf(angle)+V*sinf(angle); v= U*sinf(-angle)+V*cosf(angle); } void pitch(float angle){ v=V*cosf(angle)+N*sinf(-angle); n=V*sinf(angle)+N*cosf(angle); } void yaw(float angle){ u= U*cosf(angle)+N*sinf(angle); n= U*sinf(-angle)+N*cosf(angle); } thank you, ^^