Sign in to follow this  

Recommended Posts

Anyone knows how to make this: When i Click on Quad with texture it will be do some instructions (in OpenGL with glut) Maybe some tutorials ... Please reply.

Share this post


Link to post
Share on other sites
I will try it later because i m going to make some songs in my studio
But thanks
It should help me like I see

Share this post


Link to post
Share on other sites
I dont know where is a problem i made a class where i declareted function for
glutMouseFunc
When i call it i have error

error C2664: 'glutMouseFunc' : cannot convert parameter 1 from 'void (int,int,int,int)' to 'void (__cdecl *)(int,int,int,int)'

but when i make it not in class but structural everything is OK


Share this post


Link to post
Share on other sites
Let us see your code.

You may have to write your function like so:


extern "C" myMouseFunc( /* params */ )
{
// stuff
}

glutMouseFunc( &myMouseFunc );

Edit:

Quote:

but when i make it not in class but structural everything is OK


Yes, functions in classes are very different to normal functions, the "this" pointer needs to be passed, and how it is passed can vary with compiler.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this