Delgine 3D Tools & Content DeleD Community Edition
Forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

My engine is geting no where.
Goto page Previous  1, 2
 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    DeleD Community Edition Forum Index -> DeleD User Game Projects
View previous topic :: View next topic  
Author Message
Mr.Fletcher
DeleD PRO user


Joined: 07 Aug 2004
Posts: 1772
Location: Germany

PostPosted: Tue Feb 22, 2005 3:21 pm    Post subject: Reply with quote

Use the automatic OnMouseMove - Event of the window/form, it's not opengl-specific. I don't know how this is handled in c++, but i think it might be quite the same as in delphi.
_________________
Behold! The DeleD Wiki! Please help us expanding it Smile
DeleD on IRC
Back to top
View user's profile Send private message
banshee777
Member


Joined: 10 Feb 2005
Posts: 37

PostPosted: Fri Feb 25, 2005 4:54 am    Post subject: .... Reply with quote

I've did it using glutmouse

glRotatef(ry,1,0,0); //WORKING
glRotatef(rx,0,1,0); //WORKING
glTranslatef(-XPOS,-YPOS,-ZPOS);
glGetFloatv(GL_MODELVIEW_MATRIX, matrix); // puts the


void mouse(int x, int y)
{
if (x < 1024 / 2)
rx = rx - 3;
if (x > 1024 / 2)
rx = rx + 3;
if (y < 768 / 2)
ry = ry - 2;
if (y > 768 / 2)
ry = ry + 2;
frame3++;
time3=glutGet(GLUT_ELAPSED_TIME);
if (time3 - timebase3 > 31)
{
timebase3 = time3;
frame3 = 0;
glutWarpPointer(1024/2,768/2);

}
)
Back to top
View user's profile Send private message
Yokom
DeleD PRO user


Joined: 11 Apr 2005
Posts: 22
Location: Dallas TX

PostPosted: Sun Apr 24, 2005 7:13 am    Post subject: Reply with quote

You mentioned collision there is a good open source resource called opcode that does perface collision detection. I have heard really good things about it but havnt messed with it "yet". Im still using a convex hull collision system from our physices engine.

btw on your mouse code I will assume you are on a linux platform or you would be using directX.
Back to top
View user's profile Send private message Visit poster's website
Jeroen
Site Admin


Joined: 07 Aug 2004
Posts: 5332
Location: The Netherlands

PostPosted: Sun Apr 24, 2005 7:32 am    Post subject: Reply with quote

Yokom wrote:

btw on your mouse code I will assume you are on a linux platform or you would be using directX.


Why would you assume he's using linux? Because of the openGL commands?
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Guest






PostPosted: Fri Nov 04, 2005 6:25 pm    Post subject: Re: .... Reply with quote

banshee777 wrote:
I've did it using glutmouse

glRotatef(ry,1,0,0); //WORKING
glRotatef(rx,0,1,0); //WORKING
glTranslatef(-XPOS,-YPOS,-ZPOS);
glGetFloatv(GL_MODELVIEW_MATRIX, matrix); // puts the


void mouse(int x, int y)
{
if (x < 1024 / 2)
rx = rx - 3;
if (x > 1024 / 2)
rx = rx + 3;
if (y < 768 / 2)
ry = ry - 2;
if (y > 768 / 2)
ry = ry + 2;
frame3++;
time3=glutGet(GLUT_ELAPSED_TIME);
if (time3 - timebase3 > 31)
{
timebase3 = time3;
frame3 = 0;
glutWarpPointer(1024/2,768/2);

}
)
Back to top
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    DeleD Community Edition Forum Index -> DeleD User Game Projects All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum