Skip to content

Instantly share code, notes, and snippets.

@RobertShippey
Created April 12, 2012 19:56
Show Gist options
  • Save RobertShippey/2370571 to your computer and use it in GitHub Desktop.
Save RobertShippey/2370571 to your computer and use it in GitHub Desktop.
Gwin Sound
GSound myTrack;
GSample myPlayableTrack = myTrack.load("path/to/file.mp3", true);
myPlayableTrack.play();
//It looks like that's passing back a GError so you could try this:
GError myError = myTrack.load("path/to/file.mp3", true);
Gwin.writeString(myError.getErrorMsg());
//This will store the error that the myTrack.load is causing then write out the error message to your Gwindow so you can see what it thinks the problem is.
@wilferraciolli
Copy link

no actualy
1>h:\project\space invaders\space invaders\space invaders.cpp(74) : error C2440: 'initializing' : cannot convert from 'GError' to 'GSample'
1> No constructor could take the source type, or constructor overload resolution was ambiguous

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment