gosu 0.7.38-universal-darwin → 0.7.39-universal-darwin

Sign up to get free protection for your applications and to get access to all the features.
@@ -67,8 +67,6 @@ namespace Gosu
67
67
  //! Schedules a custom GL functor to be executed at a certain Z level.
68
68
  //! The functor is called in a clean GL context (as given by beginGL/endGL).
69
69
  //! Gosu's rendering up to the Z level may not yet have been glFlush()ed.
70
- //! Note: Unlike normal drawing operations on the same Z level, the order
71
- //! of custom GL functors is NOT DEFINED.
72
70
  //! Note: You may not call any Gosu rendering functions from within the
73
71
  //! functor, and you must schedule it from within Window::draw's call tree.
74
72
  void scheduleGL(const std::tr1::function<void()>& functor, ZPos z);
@@ -81,8 +79,11 @@ namespace Gosu
81
79
  //! Starts recording a macro. Cannot be nested.
82
80
  void beginRecording();
83
81
  //! Finishes building the macro and returns it as a drawable object.
82
+ //! The width and height affect nothing about the recording process,
83
+ //! the resulting macro will simply return these values when you ask
84
+ //! it.
84
85
  //! Most usually, the return value is passed to Image::Image().
85
- std::auto_ptr<Gosu::ImageData> endRecording();
86
+ std::auto_ptr<Gosu::ImageData> endRecording(int width, int height);
86
87
 
87
88
  //! Pushes one transformation onto the transformation stack.
88
89
  void pushTransform(const Transform& transform);
@@ -87,7 +87,7 @@ namespace Gosu
87
87
  //! \param tileHeight See tileWidth.
88
88
  //! \param appendTo STL container to which the images will be appended.
89
89
  //! Must provide a push_back member function; vector<tr1::shared_ptr<Image>>
90
- //! or std::tr1::ptr_vector<Image> are good choices.
90
+ //! or boost::ptr_vector<Image> are good choices.
91
91
  template<typename Container>
92
92
  void imagesFromTiledBitmap(Graphics& graphics, const std::wstring& filename,
93
93
  int tileWidth, int tileHeight, bool tileable, Container& appendTo)
@@ -104,7 +104,7 @@ namespace Gosu
104
104
  //! \param tileHeight See tileWidth.
105
105
  //! \param appendTo STL container to which the images will be appended.
106
106
  //! Must provide a push_back member function; std::vector<std::tr1::shared_ptr<Image>>
107
- //! or std::tr1::ptr_vector<Image> are good choices.
107
+ //! or boost::ptr_vector<Image> are good choices.
108
108
  template<typename Container>
109
109
  void imagesFromTiledBitmap(Graphics& graphics, const Bitmap& bmp,
110
110
  int tileWidth, int tileHeight, bool tileable, Container& appendTo)
@@ -38,8 +38,8 @@ namespace Gosu
38
38
  {
39
39
  }
40
40
 
41
- virtual unsigned width() const = 0;
42
- virtual unsigned height() const = 0;
41
+ virtual int width() const = 0;
42
+ virtual int height() const = 0;
43
43
 
44
44
  virtual void draw(double x1, double y1, Color c1,
45
45
  double x2, double y2, Color c2,
@@ -3,8 +3,8 @@
3
3
 
4
4
  #define GOSU_MAJOR_VERSION 0
5
5
  #define GOSU_MINOR_VERSION 7
6
- #define GOSU_POINT_VERSION 38
7
- #define GOSU_VERSION "0.7.38"
6
+ #define GOSU_POINT_VERSION 39
7
+ #define GOSU_VERSION "0.7.39"
8
8
 
9
9
  #define GOSU_COPYRIGHT_NOTICE \
10
10
  " " \
@@ -65,9 +65,9 @@ class Star
65
65
  def initialize(animation)
66
66
  @animation = animation
67
67
  @color = Gosu::Color.new(0xff000000)
68
- @color.red = rand(255 - 40) + 40
69
- @color.green = rand(255 - 40) + 40
70
- @color.blue = rand(255 - 40) + 40
68
+ @color.red = rand(256 - 40) + 40
69
+ @color.green = rand(256 - 40) + 40
70
+ @color.blue = rand(256 - 40) + 40
71
71
  @x = rand * 640
72
72
  @y = rand * 480
73
73
  end
Binary file
Binary file
@@ -5,12 +5,12 @@ if defined? RUBY_PLATFORM and
5
5
  ENV['PATH'] = "#{File.dirname(__FILE__)};#{ENV['PATH']}"
6
6
  end
7
7
 
8
- if File.exist? "#{File.dirname(__FILE__)}/gosu.#{Config::CONFIG['DLEXT']}"
9
- require "gosu.#{Config::CONFIG['DLEXT']}"
8
+ if File.exist? "#{File.dirname(__FILE__)}/gosu.#{RbConfig::CONFIG['DLEXT']}"
9
+ require "gosu.#{RbConfig::CONFIG['DLEXT']}"
10
10
  elsif defined? RUBY_VERSION and RUBY_VERSION >= '1.9' then
11
- require "gosu.for_1_9.#{Config::CONFIG['DLEXT']}"
11
+ require "gosu.for_1_9.#{RbConfig::CONFIG['DLEXT']}"
12
12
  else
13
- require "gosu.for_1_8.#{Config::CONFIG['DLEXT']}"
13
+ require "gosu.for_1_8.#{RbConfig::CONFIG['DLEXT']}"
14
14
  end
15
15
 
16
16
  require "gosu/swig_patches"
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gosu
3
3
  version: !ruby/object:Gem::Version
4
- hash: 79
4
+ hash: 77
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 7
9
- - 38
10
- version: 0.7.38
9
+ - 39
10
+ version: 0.7.39
11
11
  platform: universal-darwin
12
12
  authors:
13
13
  - Julian Raschke
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-10-28 00:00:00 Z
18
+ date: 2011-11-19 00:00:00 Z
19
19
  dependencies: []
20
20
 
21
21
  description: " 2D game development library.\n\n Gosu features easy to use and game-friendly interfaces to 2D graphics\n and text (accelerated by 3D hardware), sound samples and music as well as\n keyboard, mouse and gamepad/joystick input.\n\n Also includes demos for integration with RMagick, Chipmunk and OpenGL.\n"
@@ -89,12 +89,19 @@ files:
89
89
  - examples/media/Starfighter.bmp
90
90
  - lib/gosu.for_1_8.bundle
91
91
  - lib/gosu.for_1_9.bundle
92
- homepage: http://libgosu.org/
92
+ homepage: http://www.libgosu.org/
93
93
  licenses: []
94
94
 
95
95
  post_install_message:
96
- rdoc_options: []
97
-
96
+ rdoc_options:
97
+ - README.txt
98
+ - COPYING
99
+ - reference/gosu.rb
100
+ - reference/*.rdoc
101
+ - --title
102
+ - Gosu
103
+ - --main
104
+ - README.txt
98
105
  require_paths:
99
106
  - lib
100
107
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -120,7 +127,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
120
127
  requirements: []
121
128
 
122
129
  rubyforge_project:
123
- rubygems_version: 1.8.9
130
+ rubygems_version: 1.8.11
124
131
  signing_key:
125
132
  specification_version: 3
126
133
  summary: 2D game development library.