May 6th, 2013, 12:30 AM
Pass a handle to a function
Visual C++ 2010
This is all very new to me.
I'm using SFML with Visual C++ and need to pass a handle to
a function. I've tried to find this on the web with no luck.
The handle happens to be a sprite defined as:
Now I want to pass "Numbers" to a function.
How do I do this?
Thanks for any reply.
May 6th, 2013, 04:04 AM
Re: Pass a handle to a function
Whatever framework you use you have to use types provided by the framework.
Originally Posted by jerry_d
In case the framework's on-line documentation is not enough, you always may inspect samples the framework site provides.
I've tried to find this on the web with no luck.
Considering this snippet, it seems to me you need to get back to your C++ lessons covering functions and data types.
One of the very basic programming skills is ability to read code/documentation and deduce data types to be used as function parameters and return values, as well as design safe data type casts/transformations for passing data to and from the function if required. Without the skill you're not able to move forward.
RETURN_TYPE getFrame(PARAMETER_TYPE parameterVariable)
Last edited by Igor Vartanov; May 6th, 2013 at 04:06 AM.
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!