Jump to content
  • Advertisement

asghar

Member
  • Content Count

    34
  • Joined

  • Last visited

Community Reputation

100 Neutral

About asghar

  • Rank
    Member
  1. asghar

    normalize

    hi (cot(θ/2)/aspect 0 0 0 ) ( 0 cot(a/2) 0 0 ) ( 0 0 (Near + Far)/(Near − Far) 2 Far Near/(Near − Far) ) * ( 0 0 −1 0 ) ( 1 0 0 px ) (cos(r) 0 sin(r) 0 ) (x1) (xt) ( 0 1 0 py ) ( 0 1 0 0 ) (y1) (yt) ( 0 0 1 pz ) * (-sin(r) 0 cos(r) 0 ) * (z1) = (zt) ( 0 0 0 1 ) ( 0 0 0 1 ) (1) (wt) how normalize (xt,yt,zt,wt)?
  2. Whether can use gluProject() for Obtained new Coordinate ((x1,y1,z1),(x2,y2,z2),(x3,y3,z3)) after code (A)? code(A)::( void display2(){ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); gluPerspective(a,aspect,n,f); glTranslatef(pz, py, pz); glRotatef(r,0.0,1.0,0.0); glPushMatrix(); glBegin(GL_TRIANGLES); glVertex3f(x1,y1,z1); glVertex3f(x2,y2,z2); glVertex3f(x3,y3,z3); glEnd(); glPopMatrix(); glutSwapBuffers(); })
  3. asghar

    gluProject()

    Whether can use gluProject() for Obtained newCoordinate after code (A)? void display2(){ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); gluPerspective(a,aspect,n,f); glTranslatef(pz, py, pz); glRotatef(r,0.0,1.0,0.0); glPushMatrix(); glBegin(GL_TRIANGLES); glVertex3f(x1,y1,z1); glVertex3f(x2,y2,z2); glVertex3f(x3,y3,z3); glEnd(); glPopMatrix(); glutSwapBuffers(); }
  4. asghar

    coordinate

    I need new Coordinate after code (A). void display2(){ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); gluPerspective(a,aspect,n,f); glTranslatef(pz, py, pz); glRotatef(r,0.0,1.0,0.0); glPushMatrix(); glBegin(GL_TRIANGLES); glVertex3f(x1,y1,z1); glVertex3f(x2,y2,z2); glVertex3f(x3,y3,z3); glEnd(); glPopMatrix(); glutSwapBuffers(); } how obtain?
  5. asghar

    Homogeneous

    Hi I'm trying use code (b) in stead of code (a) , Code(a){{ void display2(){ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); gluPerspective(a,aspect,n,f); glTranslatef(pz, py, pz); glRotatef(r,0.0,1.0,0.0); glPushMatrix(); glBegin(GL_TRIANGLES); glVertex3f(x1,y1,z1); glVertex3f(x2,y2,z2); glVertex3f(x3,y3,z3); glEnd(); glPopMatrix(); glutSwapBuffers(); } }} Code(b) {{ (cot(θ/2)/aspect 0 0 0 ) ( 0 cot(a/2) 0 0 ) ( 0 0 (Near + Far)/(Near − Far) 2 Far Near/(Near − Far) ) * ( 0 0 −1 0 ) ( 1 0 0 px ) (cos(r) 0 sin(r) 0 ) (x1) (xt) ( 0 1 0 py ) ( 0 1 0 0 ) (y1) (yt) ( 0 0 1 pz ) * (-sin(r) 0 cos(r) 0 ) * (z1) = (zt) ( 0 0 0 1 ) ( 0 0 0 1 ) (1) (1) x1=xt; y1=yt;z1=zt; x1=xt/w,y1yt/w,z1=zt/w; Repeat this method for (x2,y2,z2) and (x3,y3,z3). void display2(){ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); glPushMatrix(); glBegin(GL_TRIANGLES); glVertex3f(x1,y1,z1); glVertex3f(x2,y2,z2); glVertex3f(x3,y3,z3); glEnd(); glPopMatrix();glutSwapBuffers();} }} But when triangle collide to plan Near, code(b) return incorrect result.
  6. asghar

    glGetFloat

    hi how use void glGetDoublev( GLenum pname, GLdouble *params ) to obtain the clipping coordinate W value?
  7. asghar

    Homogeneous

    Hi I'm trying use code (b) in stead of code (a) , Code(a){{ void display2(){ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); gluPerspective(a,aspect,n,f); glTranslatef(pz, py, pz); glRotatef(r,0.0,1.0,0.0); glPushMatrix(); glBegin(GL_TRIANGLES); glVertex3f(x1,y1,z1); glVertex3f(x2,y2,z2); glVertex3f(x3,y3,z3); glEnd(); glPopMatrix(); glutSwapBuffers(); } }} Code(b) {{ (cot(θ/2)/aspect 0 0 0 ) ( 0 cot(a/2) 0 0 ) ( 0 0 (Near + Far)/(Near − Far) 2 Far Near/(Near − Far) ) * ( 0 0 −1 0 ) ( 1 0 0 px ) (cos(r) 0 sin(r) 0 ) (x1) (xt) ( 0 1 0 py ) ( 0 1 0 0 ) (y1) (yt) ( 0 0 1 pz ) * (-sin(r) 0 cos(r) 0 ) * (z1) = (zt) ( 0 0 0 1 ) ( 0 0 0 1 ) (1) (1) x1=xt; y1=yt;z1=zt; x1=xt/w,y1=yt/w,z1=zt/w; Repeat this method for (x2,y2,z2) and (x3,y3,z3). void display2(){ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); glPushMatrix(); glBegin(GL_TRIANGLES); glVertex3f(x1,y1,z1); glVertex3f(x2,y2,z2); glVertex3f(x3,y3,z3); glEnd(); glPopMatrix();glutSwapBuffers();} }} But when triangle collide to plan Near, code(b) return incorrect result.
  8. asghar

    clipping coordinate

    hi all how obtain the clipping coordinate W value?.
  9. asghar

    homogeneous

    hi. how convert a homogeneous representation to a non-homogeneous ?
  10. asghar

    homogeneous

    hi how convert a homogeneous representation to a non-homogeneous?
  11. hi how obtain the clipping coordinate W value?.
  12. using namespace System::Media; this code give erro in console(c++). how use sounplayer?
  13. asghar

    soundplayer class

    hi how use soundplayer class in console?(c ++)
  14. asghar

    openal

    hi how unse openal in Visual Studio 2005?
  15. asghar

    openal

    hi how unse openal in Visual Studio 2005?
  • 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!