Not logged inGosu Forums
Forum back to libgosu.org Help Search Register Login
Up Topic Gosu / Gosu News / Gosu 0.10.0 released
- - By jlnr (dev) Date 2015-08-20 08:51 Edited 2015-08-20 09:05
Gosu 0.10.0 is out. It contains two things that I thought I had already released:

• Add new ifRetro/:retro parameter to image constructors
• Ruby: Fix mouse position getter/setter interaction

Sorry for the delay, I meant to release 0.9.3 months ago. The tl;dr is that you should start using Image.new("filename.png", :retro => true) instead of using Gosu::enable_undocumented_retrofication.

I've also replaced a few third-party libraries with easier-to-maintain public domain code.
(The version was bumped to 0.10.0 because some exotic image files might not work anymore — but at least they will consistently be broken across platforms now! No more surprises during porting.)

• Use stb_image(_write) for image I/O instead of GDI+, FreeImage, UIImage/NSImage etc.
• Use stb_vorbis for OGG decoding instead of libogg/libvorbis/libvorbisfile

This is also great news because libogg/libvorbis require written attribution in every game that uses the libraries (BSD license) - and readers of our games' README files honestly don't care about audio codecs. Less clutter for everyone.

The biggest changes in 0.10.0 are in the non-Ruby build scripts, though:

• Windows: Upgrade to Visual C++ 2015 (the free Express Desktop edition works). Microsoft has pulled all downloads for good old Visual C++ 2010, time to move on.
• Unix: Fix the CMake build files.
• Xcode: The Gosu.podspec for OS X and iOS is now versioned, instead of being stuck at v0.0.1.

Precompiled libraries for Windows, and a source code tarball for UNIX systems can be found here: https://libgosu.org/downloads/

To keep the Gosu codebase somewhat manageable, I have also ripped out the Socket classes for C++ and moved them to https://github.com/jlnr/Sockets.
Reply
Parent - By jlnr (dev) Date 2015-08-20 08:59 Edited 2015-08-20 09:05
Two more things:

First, I'm sorry for not looking into the Chingu bug yet! It's on my list.

Second, 33th Ludum Dare gamedev competition starts tomorrow! If you have no plans for the weekend, stock up on healthy snacks and write a game :)

http://ludumdare.com/compo/
Parent - - By bestguigui Date 2015-08-21 18:39
Hi jlnr,

I'm sorry but your fix for the mouse doesn't work.

Quick and dirty test code :

require 'gosu'

class Window < Gosu::Window
  def initialize
    super(640, 480, false)
  end
 
  def button_down(id)
    exit if id == Gosu::KbEscape
    if id == Gosu::KbSpace
      self.mouse_x = 10
      self.mouse_y = 10
    end
  end
 
  def needs_cursor?;true;end
end

Window.new.show

Only the y value is set to 10.
Reply
Parent - By jlnr (dev) Date 2015-08-22 01:23
Works as expected on OS X. I wonder if it doesn't work on Windows because I'm still using SDL 2.0.3 there. (Man, SDL 2.0.4 can't come fast enough :( Maybe I should compile an intermediate DLL myself?) Thanks for reporting this, and sorry for the lack of progress.

I've opened a GitHub issue here: https://github.com/gosu/gosu/issues/293
- - By Gammel Date 2015-08-20 15:56
Hi

Is it me or :retro doesn't work with load_tiles?
Reply
Parent - - By lol_o2 Date 2015-08-20 21:18
I think it doesn't. I even tried loading tiles from :retro Image.
Parent - By jlnr (dev) Date 2015-08-20 22:05 Edited 2015-08-22 01:24
Loading tiles will copy the image data to a new texture, so you'd have to pass :retro when creating the individual tiles - that should work!

If you use retro_image.subimage(x,y,w,h), it should preserve the parent texture's retro-ness. The image data is shared in that case, which also makes subimage extremely cheap.

Then again, I'm not sure if subimage was really a good idea, or if Image.load_tiles should just take an array of rectangles to support texture atlas loading.
Parent - By jlnr (dev) Date 2015-08-20 21:58 Edited 2015-08-20 22:04
Confirmed, looking into it now.

Edit: Fixed, will be released as 0.10.1 ASAP. I've also fixed the :retro parameter in Image.from_text, for the sake of consistency.
Up Topic Gosu / Gosu News / Gosu 0.10.0 released

Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill