Author Topic: Antipodes 9 - SDL Everywhere  (Read 12389 times)

0 Members and 2 Guests are viewing this topic.

Offline niffiwan

  • 211
  • Eluder Class
Re: Antipodes 9 - SDL Everywhere
Sounds good.  It'll conflict with at least this recent commit, so maybe roll that commit into antipodes as well?
Creating a fs2_open.log | Red Alert Bug = Hex Edit | MediaVPs 2014: Bigger HUD gauges | 32bit libs for 64bit Ubuntu
----
Linux OBS Packages: FSO 3.7.0 | FSO BP Build | wxLauncher (?) | PCS2 (?) | wxVPView (?)
Debian Packages (testing/unstable): Freespace2 | wxLauncher
----
m|m: I think I'm suffering from Stockholm syndrome. Bmpman is starting to make sense and it's actually written reasonably well...

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️À➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Re: Antipodes 9 - SDL Everywhere
Yeah can do a trunk sync first and then make it line up probably.  Unless this would actually just work in trunk without any real problems, I don't know how much controlsconfigcommon was hacked apart in that area of the file in Antipodes.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline niffiwan

  • 211
  • Eluder Class
Re: Antipodes 9 - SDL Everywhere
Hmm... I don't know that much about the controls config section myself, I think z64555 would be most qualified to comment here.
Creating a fs2_open.log | Red Alert Bug = Hex Edit | MediaVPs 2014: Bigger HUD gauges | 32bit libs for 64bit Ubuntu
----
Linux OBS Packages: FSO 3.7.0 | FSO BP Build | wxLauncher (?) | PCS2 (?) | wxVPView (?)
Debian Packages (testing/unstable): Freespace2 | wxLauncher
----
m|m: I think I'm suffering from Stockholm syndrome. Bmpman is starting to make sense and it's actually written reasonably well...

 

Offline z64555

  • 210
  • Self-proclaimed controls expert
    • Minecraft
    • Steam
Re: Antipodes 9 - SDL Everywhere
It doesn't appear that I committed most of my hacks for the controls code. I have it on my github clone only.
I'm on Facebook! sort of. Zeesixtyfour Fivefiftyfive

-=wxFRED2=-
R.I.P. Oliver
------------
EveningTea: Time to go Freeman on this cultist..
* EveningTea pulls crowbar off his shoulderstrap and charges screaming incoherently across the marsh *
------------
z64555: bro. do you even salad
------------
z64555: suprise double quaternion!

 

Offline m!m

  • 210
Re: Antipodes 9 - SDL Everywhere
While we are at this topic , I noticed that the current version of wxLauncher is not compatible with the current SDL builds. wxLauncher gets the joystick list like the current FSO builds but those indices are different from the indices SDL supplies. To fix this wxLauncher would need to be modified to also retrieve the list using SDL and use those indices. For that to also work with older builds a new build capabilities flag has to be added to the flags file.
However there is better solution. SDL is capable of supplying GUIDs for the joysticks (SDL_JoystickGetGUID and SDL_JoystickGetGUIDString) which can be used to uniquely identify the joysticks without having to rely on the indices (that also means that removing a device would not suddenly change the used joystick).
What do you think?

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
Re: Antipodes 9 - SDL Everywhere
id just yoink the stick select out of the launchers and allow bindings to every stick on the system. selecting one stick makes things easy because bindings can simply be axis1 or button2, indexing into whatever stick is the chosen one. if you add multiple sticks you then need to bind something like stick3:axis4, or stick2:button1, bringing fourth the problem of non-numeric indexing (especially if you use guids instead of stick indices). then to deal with users plugging and unplugging different joysticks into the system, drastically changing the configuration and causing total chaos.

thing is you dont need to say goodby to numeric indices. if you can say axis1, button2, you can say axis42 or button350 just as well. you just need to scan every stick on the system, figure out its axis/button count, then allocate space on a master list of axes and buttons. these indices are then used for bindings, and wraps functions to get the state any button or axis on the master list by the appropriate sdl calls. for example, masterFakeJoystick:getAxis(12) or masterFakeJoystick:getbutton(69).

to keep track of everything, build another list where each entry is a joystick, using the guid as the unique identifier (thats what guids are for after all). this maps physical controls into the master list in a very permanent way without confusing the code. this keeps track of every joystick the user ever had connected to the machine when the game ran, and stores mapping information to resolve big number indices to their device-local equivalents. new joysticks are, scanned, and mapped into the master list, old joysticks are retained for later use. this list has to be saved to avoid a particular stick's master list indices from changing.

this is a good opportunity to shoot down, once and for all, the one stick limit.
« Last Edit: July 10, 2014, 05:46:06 am by Nuke »
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline m!m

  • 210
Re: Antipodes 9 - SDL Everywhere
That would obviously be the ideal solution (I think z64555 works on this) but would require a lot of work, ideally it would be implemented by a completely rewritten joystick management system.
My point is to use this as a preliminary solution until the new joystick handling can be implemented which will probably need another antipodes cycle.

 

Offline z64555

  • 210
  • Self-proclaimed controls expert
    • Minecraft
    • Steam
Re: Antipodes 9 - SDL Everywhere
m!m is correct, the joystick overhaul is so extensive that it'll need an antipodes cycle all by itself. There's just a whole lot of assumptions in the existing codebase that make a change from a single joystick to multiple controllers non-trivial.
I'm on Facebook! sort of. Zeesixtyfour Fivefiftyfive

-=wxFRED2=-
R.I.P. Oliver
------------
EveningTea: Time to go Freeman on this cultist..
* EveningTea pulls crowbar off his shoulderstrap and charges screaming incoherently across the marsh *
------------
z64555: bro. do you even salad
------------
z64555: suprise double quaternion!

 

Offline m!m

  • 210
Re: Antipodes 9 - SDL Everywhere
I went ahead and implemented the necessary changes, here is a comparision which sould show what needs to be done: https://github.com/asarium/fs2open.github.com/compare/asarium:cmake...feature/joystickGUID
This also adds handling of added/removed devices.

This also requires changes to wxLauncher but I already implemented it.

 

Offline z64555

  • 210
  • Self-proclaimed controls expert
    • Minecraft
    • Steam
Re: Antipodes 9 - SDL Everywhere
oh damnit, you're gonna make me get back to work on the io/controls overhaul, aren't you? :P
I'm on Facebook! sort of. Zeesixtyfour Fivefiftyfive

-=wxFRED2=-
R.I.P. Oliver
------------
EveningTea: Time to go Freeman on this cultist..
* EveningTea pulls crowbar off his shoulderstrap and charges screaming incoherently across the marsh *
------------
z64555: bro. do you even salad
------------
z64555: suprise double quaternion!

 

Offline Bryan See

  • Has anyone really been far as decided to use even go want to do look more like?
  • 29
  • Visionary modder and coder
    • Skype
    • Steam
    • Twitter
Re: Antipodes 9 - SDL Everywhere
I've tested this build, but for some reason my joystick/gamepad did not work or get recognized.
Bryan See - My FreeSpace Wiki User Page (Talk, Contributions)

Campaigns:
FreeSpace: Reunited - Shattered Stars

Ships:
GTS Hygeia, GTT Argo, SC Raguel

 

Offline m!m

  • 210
Re: Antipodes 9 - SDL Everywhere
There is an issue with the current version of wxLauncher, try selecting other joysticks in the launcher until one is recognized.

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️À➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Re: Antipodes 9 - SDL Everywhere
First post finally updated with OS X builds.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️À➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Re: Antipodes 9 - SDL Everywhere
And now FreeBSD builds.  OS X builds updated again to match current latest.  Will try to get Windows builds soon as these are pretty outdated.  Then we really need to have a go at bug squashing in this branch.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️À➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Re: Antipodes 9 - SDL Everywhere
And Linux builds because why not.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️À➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Re: Antipodes 9 - SDL Everywhere
And now finally updated Windows Antipodes 9 builds in the first post.  Been a while.  Not sure if we still need the custom SDL2 so I have uploaded it alongside the new builds as a potentially optional download.  If it is indeed still definitely required it can be re-clarified as such but I was thinking we were compatible with the official release now.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline m!m

  • 210
Re: Antipodes 9 - SDL Everywhere
The binaries in the git repository are the release binaries so no custom built binaries are needed.

 

Offline Echelon9

  • Moderator
  • 210
Re: Antipodes 9 - SDL Everywhere
On OS X 10.10 (which with trunk no longer works due to SDL 1.x problems), the Antipodes 9 build work fine from the command line.

There is however a new error when double clicking the .app from Finder or the Dock, which is that FS2_Open reports "Unrecognized command line parameter -psn_<xxx>". This parameter is apparently one which Finder/Dock silently adds on Mac. The <xxx> number is the PSN - process serial number (a unique PID-ish thing).

VLC and Firefox ran into this based on found bug reports, so I'll spend some time trying to resolve it.

GitHub Issue reported here. Would someone with access mind tagging it as Antipodes?
« Last Edit: July 26, 2015, 02:24:47 am by Echelon9 »

 

Offline m!m

  • 210
Re: Antipodes 9 - SDL Everywhere
I tagged the issue as Antipodes and created a pull request with a proposed patch which should match what SDLMain.c did: https://github.com/scp-fs2open/fs2open.github.com/pull/250

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️À➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Re: Antipodes 9 - SDL Everywhere
Trunk and zookeeper's FotG builds still seem to be working for me for the most part on 10.10.  I'm not sure they are broken for everyone.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays