Newbie question on _mfxSession structure

Newbie question on _mfxSession structure


I have a question about the _mfxSession structure definition.  In the mfxvideo.h file, there is typedef that defines mfxSession as a pointer to a _mfxSession structure.  It's defined as follows:

typedef struct _mfxSession *mfxSession;

Can someone tell me where and/or how _mfxSession is defined?

To use the SDK you really don't care per se, however, I'm trying to expose the API to a scripting language and am struggling to figure out how to expose the structure definition since I cannot find it in any of the SDK header files.

Thanks in advance,



3 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

"typedef struct _mfxSession *mfxSession" construction is a way of typing void*. It can be treated as an identifier of some "black box". DWORD_PTR or void* could be used for such purpose, but DWORD_PTR/void* is a less secure approach (I mean the c/c++ language). With "typedef struct _X* X" you can not assign identifier of X essence to identifier of Y essence.

Thanks for good/accurate answer.

Jeff, I suspect your scripting language has some examples of how to treat generic "handles" that are type casted in this fashion.

Leave a Comment

Please sign in to add a comment. Not a member? Join today