Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
YGOPRO-520DIY
ygopro
Commits
39628506
Commit
39628506
authored
Feb 24, 2025
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add stb_vorbis for ogg support
parent
870b6b9d
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
5777 additions
and
2 deletions
+5777
-2
gframe/miniaudio/premake5.lua
gframe/miniaudio/premake5.lua
+2
-0
gframe/miniaudio/stb_vorbis.c
gframe/miniaudio/stb_vorbis.c
+5443
-0
gframe/miniaudio/stb_vorbis.h
gframe/miniaudio/stb_vorbis.h
+331
-0
gframe/sound_manager.cpp
gframe/sound_manager.cpp
+1
-1
gframe/sound_manager.h
gframe/sound_manager.h
+0
-1
No files found.
gframe/miniaudio/premake5.lua
View file @
39628506
...
@@ -2,5 +2,7 @@ project "cminiaudio"
...
@@ -2,5 +2,7 @@ project "cminiaudio"
kind
"StaticLib"
kind
"StaticLib"
files
{
"*.c"
,
"*.h"
}
files
{
"*.c"
,
"*.h"
}
forceincludes
{
"./stb_vorbis.h"
}
filter
"system:linux"
filter
"system:linux"
links
{
"dl"
,
"pthread"
,
"m"
}
links
{
"dl"
,
"pthread"
,
"m"
}
gframe/miniaudio/stb_vorbis.c
0 → 100644
View file @
39628506
This diff is collapsed.
Click to expand it.
gframe/miniaudio/stb_vorbis.h
0 → 100644
View file @
39628506
This diff is collapsed.
Click to expand it.
gframe/sound_manager.cpp
View file @
39628506
...
@@ -216,7 +216,7 @@ void SoundManager::PlayMusic(char* song, bool loop) {
...
@@ -216,7 +216,7 @@ void SoundManager::PlayMusic(char* song, bool loop) {
BufferIO
::
DecodeUTF8
(
song
,
song_w
);
BufferIO
::
DecodeUTF8
(
song
,
song_w
);
ma_sound_init_from_file_w
(
&
engineMusic
,
song_w
,
MA_SOUND_FLAG_ASYNC
|
MA_SOUND_FLAG_STREAM
,
nullptr
,
nullptr
,
&
soundBGM
);
ma_sound_init_from_file_w
(
&
engineMusic
,
song_w
,
MA_SOUND_FLAG_ASYNC
|
MA_SOUND_FLAG_STREAM
,
nullptr
,
nullptr
,
&
soundBGM
);
#else
#else
ma_sound_init_from_file
(
&
engineMusic
,
song
,
MA_SOUND_FLAG_ASYNC
|
MA_SOUND_FLAG_STREAM
,
nullptr
,
nullptr
,
&
soundBGM
);
auto
res
=
ma_sound_init_from_file
(
&
engineMusic
,
song
,
MA_SOUND_FLAG_ASYNC
|
MA_SOUND_FLAG_STREAM
,
nullptr
,
nullptr
,
&
soundBGM
);
#endif
#endif
ma_sound_set_looping
(
&
soundBGM
,
loop
);
ma_sound_set_looping
(
&
soundBGM
,
loop
);
ma_sound_start
(
&
soundBGM
);
ma_sound_start
(
&
soundBGM
);
...
...
gframe/sound_manager.h
View file @
39628506
...
@@ -4,7 +4,6 @@
...
@@ -4,7 +4,6 @@
#include "game.h"
#include "game.h"
#include "../ocgcore/mtrandom.h"
#include "../ocgcore/mtrandom.h"
#ifdef YGOPRO_USE_AUDIO
#ifdef YGOPRO_USE_AUDIO
#define MINIAUDIO_IMPLEMENTATION
#include "miniaudio/miniaudio.h"
#include "miniaudio/miniaudio.h"
#endif
#endif
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment