-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Some more redesign, basic audio support, raylib 3.7.
- Loading branch information
Showing
31 changed files
with
885 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import "raylib" for Raylib, Color, ConfigFlags, Music, Sound | ||
|
||
// some basic setup | ||
Raylib.configFlags = ConfigFlags.vsync | ||
Raylib.targetFPS = 60 | ||
|
||
Raylib.initWindow(800, 450, "raylib-wren [audio] example - music stream") | ||
Raylib.initAudioDevice() | ||
|
||
var music = Music.new("ressources/mini1111.xm") | ||
music.play() | ||
|
||
while (!Raylib.windowShouldClose) { | ||
music.update() | ||
|
||
Raylib.beginDrawing() | ||
Raylib.clearBackground(Color.rayWhite) | ||
|
||
Raylib.drawFPS(10, 10) | ||
|
||
Raylib.drawText("Playing some music !", 300, 200, 20, Color.lightGray) | ||
|
||
Raylib.endDrawing() | ||
} | ||
|
||
Raylib.closeAudioDevice() | ||
Raylib.closeWindow() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import "raylib" for Raylib, Color, ConfigFlags, Music, Sound | ||
|
||
// some basic setup | ||
Raylib.configFlags = ConfigFlags.vsync | ||
Raylib.targetFPS = 60 | ||
|
||
Raylib.initWindow(800, 450, "raylib-wren [audio] example - music stream") | ||
Raylib.initAudioDevice() | ||
|
||
var sound = Sound.new("ressources/mini1111.ogg") | ||
sound.play() | ||
|
||
while (!Raylib.windowShouldClose) { | ||
Raylib.beginDrawing() | ||
Raylib.clearBackground(Color.rayWhite) | ||
|
||
Raylib.drawFPS(10, 10) | ||
|
||
Raylib.drawText("Playing some music !", 300, 200, 20, Color.lightGray) | ||
|
||
Raylib.endDrawing() | ||
} | ||
|
||
Raylib.closeAudioDevice() | ||
Raylib.closeWindow() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import "raylib" for Raylib, Color, ConfigFlags, Texture | ||
|
||
// Set config flags. | ||
Raylib.configFlags = ConfigFlags.vsync | ||
Raylib.targetFPS = 60 | ||
|
||
Raylib.initWindow(800, 450, "raylib [wren] example - basic window (embedded)") | ||
var logo = Texture.new("logo.png") | ||
|
||
while (!Raylib.windowShouldClose) { | ||
Raylib.beginDrawing() | ||
|
||
Raylib.clearBackground(Color.rayWhite) | ||
Raylib.drawText("Congrats! You made a embedded wray executable!", 190, 200, 20, Color.lightGray) | ||
Raylib.endDrawing() | ||
} | ||
|
||
Raylib.closeWindow() |
Binary file not shown.
Binary file not shown.
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
|
||
import "raylib" for Raylib, Color, ConfigFlags | ||
|
||
var screenWidth = 800 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.