Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC,WIP] Initial experimental SDL2 support #234

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Commits on Jun 29, 2017

  1. Clone SDL into SDL2

    Prepare for before commiting changes needed for SDL2
    sjnewbury committed Jun 29, 2017
    Configuration menu
    Copy the full SHA
    3e76dd4 View commit details
    Browse the repository at this point in the history

Commits on Jul 1, 2017

  1. This is an initial (mostly working) port to SDL2.

    By default SDL1.2 is still used, but by chaning the config.make
    option, SDL2 is used instead as a build-time option.
    
    What works, what doesn't?
    
    Working fine:
    
    Joystick input
    
    Mouse input
    
    Keyboard input
    
    Sound
    
    Fullscreen mode-switching - now mostly working
    
    Issues:
    
    Fullscreen *mostly* (there is often some
    flickering sometimes, switching back and forth fixes it.
    Okay, I think this is might be related to the problems
    with the splash screen.  There's a problem with the GL bounds
    I think.  I'm not an OpenGL expert by any means, so I'm not
    sure what the problem is exactly.  A bigger issue is changing
    fullscreen resolutions from the in game menu only properly
    resizes going down, going up leaves the "window" at the
    previous size but like the flickering, switching to windowed
    and back fixes it.
    
    Splash screen - code is there and no longer prevents startup.
    It works sometimes.  I tried writing a test outside the game
    and it worked fine.  Something is strange, under X the window
    doesn't get painted or contains random video memory, once the
    game starts rendering it's fine.  It always works under
    wayland (with the Wayland SDL video backend), see below.
    
    Windows support is untested.  I tried not to break it, or
    even change it where possible.
    
    Wayland - it works, even the splash screen!
    There were some issues resizing under Weston, possibly fixed
    now, lack of Server Side Decorations makes it tricky anyway!
    Worked fine under Enlightenment/Wayland.
    
    Android/iPhone, obscure devices ...  Probably needs OpenGL ES ...
    maybe it just works like Wayland.
    
    There is a lot of code that could be simplified, in particular
    it's possible the SDL2 Windows support works...?
    
    Testers/reviewers more than welcome!  Especially help with the
    GL issues mentioned above.
    sjnewbury committed Jul 1, 2017
    Configuration menu
    Copy the full SHA
    9d2392e View commit details
    Browse the repository at this point in the history