SDL2 based sample browser

Discussion area about developing or extending OGRE, adding plugins for it or building applications on it. No newbie questions please, use the Help forum for that.
Post Reply
paroj
OGRE Team Member
OGRE Team Member
Posts: 1994
Joined: Sun Mar 30, 2014 2:51 pm
x 1074
Contact:

SDL2 based sample browser

Post by paroj »

I picked up the work by holocroweaver and finished it for desktop platforms. You can find the results here. However I cannot test this on all supported platforms. Therefore someone who is reading this should test it on
  • Windows
  • OSX
and finish the proting for
  • NaCL
  • iOS
  • Emscripten
  • WinRT
  • Android (probably can to this myself)
User avatar
dark_sylinc
OGRE Team Member
OGRE Team Member
Posts: 5296
Joined: Sat Jul 21, 2007 4:55 pm
Location: Buenos Aires, Argentina
x 1278
Contact:

Re: SDL2 based sample browser

Post by dark_sylinc »

One question before I dive into everything else: How is the CMake dependencies on SDL being handled? AFAIK ogredeps repo doesn't handle SDL dependencies on Windows (MSVC). I would love to be wrong though.
User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 99
Contact:

Re: SDL2 based sample browser

Post by Wolfmanfx »

iOS / Android just use OIS interfaces but the input is injected nativly.

OSX / Linux / Win32 is important for the samplebrowser in the first instace - regarding CMake it should integrated into the build system I guess you did for linux
and installed SDL (make install).
What we would prefer is to integrate it into the OgreDeps repo and make it part of the build.
paroj
OGRE Team Member
OGRE Team Member
Posts: 1994
Joined: Sun Mar 30, 2014 2:51 pm
x 1074
Contact:

Re: SDL2 based sample browser

Post by paroj »

I thought holocronweaver already took care of that.
For porting I just used SDL2 from the repositories, but if I would have to compile it myself, I would just add an ExternalProject_Add somewhere - as done in the PR above.
Transporter
Minaton
Posts: 933
Joined: Mon Mar 05, 2012 11:37 am
Location: Germany
x 110

Re: SDL2 based sample browser

Post by Transporter »

I would like to add one little improvement: If SDL2 is not found but samples are selected to build, write out an error message. Or set SDL2 to required for samples.
User avatar
dark_sylinc
OGRE Team Member
OGRE Team Member
Posts: 5296
Joined: Sat Jul 21, 2007 4:55 pm
Location: Buenos Aires, Argentina
x 1278
Contact:

Re: SDL2 based sample browser

Post by dark_sylinc »

paroj wrote:I thought holocronweaver already took care of that.
For porting I just used SDL2 from the repositories, but if I would have to compile it myself, I would just add an ExternalProject_Add somewhere - as done in the PR above.
As far as I know that PR didn't cover MSVC builds, only *nix and MinGW.
paroj
OGRE Team Member
OGRE Team Member
Posts: 1994
Joined: Sun Mar 30, 2014 2:51 pm
x 1074
Contact:

Re: SDL2 based sample browser

Post by paroj »

unfortunately I dont have any experience with MSVC builds so I can help there. How to you handle SDL2 for v2-1? I guess the same solution could also be applied here..
theydidntnameme
Gnoblar
Posts: 3
Joined: Sat Nov 30, 2013 8:03 pm

Re: SDL2 based sample browser

Post by theydidntnameme »

dark_sylinc wrote:
paroj wrote:I thought holocronweaver already took care of that.
For porting I just used SDL2 from the repositories, but if I would have to compile it myself, I would just add an ExternalProject_Add somewhere - as done in the PR above.
As far as I know that PR didn't cover MSVC builds, only *nix and MinGW.
It says in the overview that he tested it with Visual Studio 2013.
Jesse Johnson wrote:I have tested these changes using Visual Studio 2013
Transporter
Minaton
Posts: 933
Joined: Mon Mar 05, 2012 11:37 am
Location: Germany
x 110

Re: SDL2 based sample browser

Post by Transporter »

SDL and SDL2 are working well with Visual Studio. SDL2 uses CMake for building, so it's not a problem to create the library. The only problem is the DirectX staff. SDL is using DirectInput8 which is part of the "old" DirectX SDK from 2010. The CMake script are not detecting DirectX from the Windows SDK.
paroj
OGRE Team Member
OGRE Team Member
Posts: 1994
Joined: Sun Mar 30, 2014 2:51 pm
x 1074
Contact:

Re: SDL2 based sample browser

Post by paroj »

I finally found some time to put together a new ogredeps repository which only consists of CMake scripts downloading and building stuff. Therefore it scales well for cross-platform. Among others this builds SDL2 for Linux and Android:
https://bitbucket.org/paroj/ogredeps
Post Reply