Skip to content

Commit 6b8861e

Browse files
committed
Fix examples
1 parent 2ff4bcb commit 6b8861e

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

examples/diagnostics.cr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ $font = SF::Font.from_file("resources/font/Ubuntu-R.ttf")
77

88
$window = SF::RenderWindow.new(
99
SF.video_mode(800, 600), "Diagnostic information",
10-
settings: SF.context_settings(depth: 32, antialiasing: 8)
10+
settings: SF.context_settings(depth: 24, antialiasing: 8)
1111
)
1212
$window.framerate_limit = 30
1313

@@ -207,7 +207,7 @@ class Button < SF::RectangleShape
207207
@text.position = SF.vector2((width - @text.global_bounds.width) / 2, -height / 20)
208208
end
209209

210-
def draw(target, states: RenderStates)
210+
def draw(target, states: SF::RenderStates)
211211
states.transform.combine(transform)
212212

213213
super(target, states)

examples/shapes.cr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ require "crsfml"
22

33
window = SF::RenderWindow.new(
44
SF.video_mode(200, 200), "Shapes",
5-
settings: SF.context_settings(depth: 32, antialiasing: 8)
5+
settings: SF.context_settings(depth: 24, antialiasing: 8)
66
)
77
window.vertical_sync_enabled = true
88

examples/snakes.cr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ scale = 20
182182

183183
window = SF::RenderWindow.new(
184184
SF.video_mode(field.size.x*scale, field.size.y*scale), "Snakes",
185-
settings: SF.context_settings(depth: 32, antialiasing: 8)
185+
settings: SF.context_settings(depth: 24, antialiasing: 8)
186186
)
187187
window.vertical_sync_enabled = true
188188
window.framerate_limit = 10

examples/transformable.cr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ class Logo
1515
@text.origin = SF.vector2(bounds.width / 2, bounds.height * 0.8)
1616
end
1717

18-
def draw(target, states: RenderStates)
18+
def draw(target, states: SF::RenderStates)
1919
states.transform.combine(transform)
2020
target.draw(@shape, states)
2121
target.draw(@text, states)

0 commit comments

Comments
 (0)