AprilAndFriends / theoraplayer

A multi-threaded C++ library that plays video files supporting multiple codecs across platforms. Easy to use, fast, responsive, abstract interface and minimal dependencies, you'll soon be wondering how you lived without it! ;) Audio and Video interfaces are completely abstracted so the library can be used anywhere, regardless of what you use to display video frames and play audio samples (eg. OpenGL / OpenAL, Direct3D / DirectSound?, SDL / SDL_mixer, X11 / alsa ...) The library can pre-cache video frames and decoded audio samples for maximum efficiency and smooth playback, even on single-cpu systems. Currently, the library supports Theora on Windows, Mac, iOS, Linux, Android, WinRT and Windows Phone. H.264 is supported on Mac and iOS.
BSD 3-Clause "New" or "Revised" License
84 stars 43 forks source link

compile error #6

Open mumin16 opened 8 years ago

mumin16 commented 8 years ago

in vs2015,

TheoraDataSource.cpp(73): error C2228: left of '.__pos' must have class/struct/union

TheoraDataSource.cpp(92): error C2228: left of '.__pos' must have class/struct/union

kspes commented 8 years ago

which platform are you building for? this is linux code:

ifdef _LINUX //fpos_t is not a scalar in Linux, for more info refer here: https://code.google.com/p/libtheoraplayer/issues/detail?id=6

fpos_t fpos = { 0 };
fpos.__pos = byte_index;

else

fpos_t fpos = byte_index;

endif

Are you maybe compiling android target? switch to win32 in this case.

borisblizzard commented 8 years ago

It might be partly due to the VS2015 compiler. Or maybe some preprocessors aren't set up properly.