Forums Archived

The forums are being archived. See this topic for more information.

Rubygame 2.6 feedback

Discussion about anything related to Rubygame

Rubygame 2.6 feedback

Postby jacius » Wed Oct 21, 2009 12:59 am

Please post about your experiences with Rubygame 2.6 (and the 2.6 test release) here!

Please be sure to mention what operating system, Ruby version, and what versions of SDL (and SDL_image, SDL_gfx, etc.) you have.
User avatar
jacius
Site Admin
 
Posts: 131
Joined: Fri Feb 06, 2009 11:13 pm

Re: Rubygame 2.6 test release feedback

Postby shawn42 » Wed Oct 21, 2009 3:58 am

Installed nice-ffi 0.2
Installed ruby-sdl-ffi 0.1
Installed rubygame-2.6 (downloaded from blog post)

It's not recognizing SDL_gfx. I may have a strange setup though. Is there anything I need to do to tell ruby-sdl-ffi or ffi where to look for my libs? Where does it look by default?

Error from Gamebox:
http://gist.github.com/214857
User avatar
shawn42
 
Posts: 109
Joined: Tue Feb 10, 2009 8:22 pm

Re: Rubygame 2.6 test release feedback

Postby jacius » Wed Oct 21, 2009 4:06 am

shawn42 wrote:It's not recognizing SDL_gfx. I may have a strange setup though. Is there anything I need to do to tell ruby-sdl-ffi or ffi where to look for my libs? Where does it look by default?

By default, it looks in:
  • Linux:
    • /usr/lib/
    • /usr/local/lib/
  • Mac:
    • /usr/local/lib/
    • /sw/lib/
    • /opt/local/lib/
    • ~/Library/Frameworks/
    • /Library/Frameworks/
  • Windows:
    • C:\windows\system32\
    • C:\windows\system\

It looks for *.so files on Linux, *.dylib and Frameworks on Mac, and *.dll on Windows.

I haven't made a way for users to indicate where the libraries are installed, but I'm considering it. It's possible for an application to tell it extra places to look, check out the Custom SDL Load Paths instructions.
User avatar
jacius
Site Admin
 
Posts: 131
Joined: Fri Feb 06, 2009 11:13 pm

Re: Rubygame 2.6 test release feedback

Postby tyler » Wed Oct 21, 2009 5:41 am

SDL_gfx isn't loading on my machine either (32bit Ubuntu Jaunty), it's installed via the package manager and I haven't messed with it at all...

The actual error I get:
Code: Select all
"Function 'SDL_gfxBlitRGBA' not found in [/usr/lib/libSDL_gfx.so]"


Everything else appears to load without error.
tyler
 
Posts: 25
Joined: Sat Feb 28, 2009 6:10 am

Re: Rubygame 2.6 test release feedback

Postby jacius » Wed Oct 21, 2009 3:43 pm

tyler wrote:
Code: Select all
"Function 'SDL_gfxBlitRGBA' not found in [/usr/lib/libSDL_gfx.so]"

Woops. I'm guessing from that message that your SDL_gfx is older than 2.0.16. Which is fine, because Rubygame is supposed to work with that still. Looks like I'll need to program it to rescue when certain functions aren't available.

Thanks for the report!
User avatar
jacius
Site Admin
 
Posts: 131
Joined: Fri Feb 06, 2009 11:13 pm

Re: Rubygame 2.6 test release feedback

Postby jacius » Wed Oct 21, 2009 6:59 pm

Update for Intel Mac users: I've made a package of dylibs for SDL and related libraries. You can unpack this into /usr/local/lib/, and Rubygame will find and use the libraries.

http://jacius.info/files/2009/10/21/SDL-mac-dylibs.tar.bz2

Included libraries:
* SDL-1.2.14
* SDL_gfx-2.0.19
* SDL_image-1.2.8
* SDL_mixer-1.2.9
* SDL_ttf-2.0.9
* smpeg r389
* freetype-2.3.9
User avatar
jacius
Site Admin
 
Posts: 131
Joined: Fri Feb 06, 2009 11:13 pm

Re: Rubygame 2.6 test release feedback

Postby shawn42 » Wed Oct 21, 2009 7:35 pm

With your SDL_gfx.dylib, seems to work for me!
User avatar
shawn42
 
Posts: 109
Joined: Tue Feb 10, 2009 8:22 pm

Function 'SDL_GetKeyState' not found in [/opt/local/lib/libS

Postby jm3 » Thu Oct 22, 2009 4:41 am

running ruby 1.8.7 on OS X 10.6.1 with SDL-1.2.14 (pre-release), SDL_mixer-1.2.8 (also pre-release).

after installing the 3 new rubygame 2.6 gems, in order, and then re-running my code, i get the following stack trace when ruby hits the line,

require 'rubygame'

Code: Select all
/opt/local/lib/ruby/gems/1.8/gems/ffi-0.5.1/lib/ffi/library.rb:77:in `attach_function': Function 'SDL_GetKeyState' not found in [/opt/local/lib/libSDL.dylib] (FFI::NotFoundError)
        from /opt/local/lib/ruby/gems/1.8/gems/nice-ffi-0.2/lib/nice-ffi/library.rb:122:in `func'
        from /opt/local/lib/ruby/gems/1.8/gems/ruby-sdl-ffi-0.1/lib/ruby-sdl-ffi/sdl/keyboard.rb:56
        from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
        ....


gems:
Code: Select all
ffi (0.5.1)
gem_plugin (0.2.3)
gemcutter (0.1.6, 0.1.5)
nice-ffi (0.2)
ruby-sdl-ffi (0.1)
rubygame (2.6.0)
rubygems-update (1.3.5)


i also tried it with the dylibs linked below, with the same result.
jm3
 
Posts: 2
Joined: Thu Oct 22, 2009 4:28 am

Re: Function 'SDL_GetKeyState' not found in [/opt/local/lib/libS

Postby jacius » Thu Oct 22, 2009 7:35 pm

jm3 wrote:
Code: Select all
/opt/local/lib/ruby/gems/1.8/gems/ffi-0.5.1/lib/ffi/library.rb:77:in `attach_function': Function 'SDL_GetKeyState' not found in [/opt/local/lib/libSDL.dylib] (FFI::NotFoundError)

This is very strange. SDL_GetKeyState is not a new function, it has been in SDL for a long time, and is definitely in SDL 1.2.14. I've even checked manually and confirmed it's compiled into the libSDL.dylib in the pack I uploaded. So I have no idea what's wrong there, sorry. :|
User avatar
jacius
Site Admin
 
Posts: 131
Joined: Fri Feb 06, 2009 11:13 pm

Re: Rubygame 2.6 test release feedback

Postby jm3 » Thu Oct 22, 2009 7:59 pm

I had rubygame previously installed, built from source because of the rakefile bug i contacted you about. maybe there is a conflict between that version and the new one, somehow.

Jacius, what's the best way to make sure that the old versions of rubygame are completely uninstalled?
jm3
 
Posts: 2
Joined: Thu Oct 22, 2009 4:28 am

Next

Return to Rubygame (General)

Who is online

Users browsing this forum: fwrbtclr00, ircufyzb80, mgbjzcrw40, wbqjexzc38 and 1 guest

cron