Release DBGL + DosBox with 3Dfx

Discussion in 'Software Releases' started by ptitSeb, Dec 31, 2015.

Tags:
  1. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    @sepulep: I'm preparing the next release of c::b PND, maybe wait for this one? I built the one in dbgl with it and had no issue (next will be based on gcc 5.3, maybe that help).

    @Pickle: there is a command line environnement in the codeblocks PND, with everything needed to compile. I assumed sepulep is compiling dosbox with that.
     
  2. sepulep

    sepulep Member

    Joined:
    Nov 18, 2008
    Messages:
    354
    ok, thanks, will wait..I am indeed using the codeblocks command line env (an old one)...
     
  3. Wally

    Wally I am a banana! Staff Member

    Joined:
    Jan 31, 2006
    Messages:
    2,925
    Location:
    Melbourne, Australia
    You have to launch it within code::blocks or copy the newer libraries out into the pandora OS (which isn't really a good idea considering the ones we use are ancient)

    My compiler flags are optimised for the Pyra, but MHT (I think) has documented a lot of dosbox stuff around here.

    The config.h stuff is this.

    #define C_DYNREC 1
    #define C_TARGETCPU ARMV7LE
    #define C_UNALIGNED_MEMORY 1

    Edit: NVM Ptitseb had already mentioned a fix.
     
  4. sepulep

    sepulep Member

    Joined:
    Nov 18, 2008
    Messages:
    354
    found a fix/workaround: did an strace and noticed the last thing before the segfault was a read of /etc/timidity.cfg - deleting this file (not sure if i will miss it for other stuff, the timidity pnd now installs cfg in /et/timidity/timidity.cfg) allows dosbox to run!
     
  5. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    @sepulep. Good (I don't have this issue myself). Be sure to apply @Wally's comment to get decent performances (or folow M-HT tutorial that is somewhere else on hwo to compile dosbox with his dynarec).
     
  6. sepulep

    sepulep Member

    Joined:
    Nov 18, 2008
    Messages:
    354
    @ptitSeb have you considered something like the following (very hackish) patches for the touchscreen offset and a modifier for the touchscreen left click to make it right click? The first one works similar as setting env SDL_MOUSE_RELATIVE=0 (the latter needs a bit more alt-enter); also it wont work for all dos programs, eg settlers, but does for others eg civ. moo. c&c
    the modifier is hardcoded to left shoulder (right shift) - there must be a way to use the dosbox mapper to make this assignable (cant make heads or tails of the corresponding code though...)
     

    Attached Files:

  7. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    @sepulep: Thanks for the patches, I'm reviewing them.

    Why are you not using SDL_ShowCursor(SDL_DISABLE) to hide the cursor? Is it to avoid the stich to relative mode when SDL_WM_GrabInput(SDL_GRAB_ON)? In that case, the env. var. SDL_MOUSE_RELATIVE=0 should be enough. Or is it related to the crash you had?

    About the right-click modifier, I'll try to have a parameter in the dosbox config or something, I don't want to hard code that (I'm not a big user of touchscreen myself, so I prefer to keep the shoulders buttons available for something else).
     
  8. sepulep

    sepulep Member

    Joined:
    Nov 18, 2008
    Messages:
    354
    its not related to the crash..I think SDL_MOUSE_RELATIVE=0 should indeed be enough, except that the patch (that boneheadedly replaces SDL_ShowCursor(SDL_DISABLE)
    with a hidden cursor and resets it where a SDL_ShowCursor(SDL_ENABLE) was called) in practice behaves slightly different (SDL_MOUSE_RELATIVE=0 needs to be 'reset' sometimes..now you mention it - this may have something to do with the SDL_WM_GrabInput(SDL_GRAB_ON))
    yea, I agree with you here..no good to have it hardcoded..
     
  9. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    Well, I had issue with GLES games on SDL with that SDL_WM_GrabInput(SDL_GRAB_ON) was active. So that impacted all FPS games, more or less. I have put a patch (there is the patch somewhere in the forum, don't remember where), and now I have no issue. Did you still see a need for the "reset" with the SDL lib that is inside codeblocks?
     
  10. sepulep

    sepulep Member

    Joined:
    Nov 18, 2008
    Messages:
    354
    if i compile and run within the codeblocks cli that is the one that should be used automatically?
     
  11. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    Yes @sepulep . And you add issue with just SDL_MOUSE_RELATIVE=0 ?
     
  12. sepulep

    sepulep Member

    Joined:
    Nov 18, 2008
    Messages:
    354
    yes, for example: for civ it can show up as an offset after restarting the program (within dosbox), which goes away after pointing outside the draw area (fullscreen btw), but it clearly behaves better than not setting the env (in that case its difficult to maintain any relation between ts and pointer at all)
     
  13. edlee

    edlee Member

    Joined:
    Dec 3, 2013
    Messages:
    77
    If I use the hardware SDL renderer setup of Pickle, the mouse cursor in Master of Orion becomes stuck in this small box in the bottom half of the screen. If I press Alt Enter to get a windowed screen, the game remains full screen, but then I can move the mouse cursor all over the game screen. The upper left corner of the screen also acts as a touchpad with which I can control the mouse cursor on the game screen.
     
  14. ekianjo

    ekianjo Hardcore Member

    Joined:
    May 7, 2012
    Messages:
    8,261
    Location:
    神戸市、日本 (Japan)
    So if you do alt+enter it solves the mouse issue completely ?
     
  15. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    The omapdss should be used with windowed mode anyway, and no scaller (scale=none) to have the most speed effect.
     
  16. sepulep

    sepulep Member

    Joined:
    Nov 18, 2008
    Messages:
    354
    maybe there is a better way, but here a version of the right click with ts patch with a corresponding keyword in the conf, in the sdl section you can specify the key name as e.g.
    click_mod=right shift
    omitting or leaving blank gives default behaviour (no modifier)

    There is no support for this keywordin dbgl, but you can add it to the conf template used..
     

    Attached Files:

  17. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    Good sepulep. I was planning to do something like that :)

    I'll integrate it for next release!
     
  18. Pickle

    Pickle Mega GP Mania

    Joined:
    May 30, 2006
    Messages:
    5,449
    Location:
    Detroit, Michigan
    a little follow up on my hw scale script:

    the scaled option will provide a 1 for 1 pixel ratio 8:5 (16:10), but in a real dos system this view is actually scaled to be 4:3.
    This can also be possible by changing this line to:
    export SDL_OMAP_LAYER_SIZE=640x480

    Also i thought sync might affect game speed but in my tests so far I dont feel that it does. So to get a smoother frame rate change these lines:
    export SDL_OMAP_FORCE_DOUBLEBUF=1
    export SDL_OMAP_VSYNC=1
     
  19. ptitSeb

    ptitSeb Serial Porter

    Joined:
    Aug 15, 2012
    Messages:
    8,359
    Location:
    France, near Lyon
    Ok @Pickle I'll integrate those changes in the next release.
     
  20. ekianjo

    ekianjo Hardcore Member

    Joined:
    May 7, 2012
    Messages:
    8,261
    Location:
    神戸市、日本 (Japan)
    does that change anything about the mouse stuck issue?
     

Share This Page

Loading...