Ambiera Forum

Discussions, Help and Support.

Ambiera Forum > irrKlang
Could not open sound file

lagger
Registered User
Quote
2013-05-24 22:21:11

Hi guys!

I've got a problem that i just can't seem to solve.
I'm programming a game on the OGRE3D engine, and i'm using irrklang for everything sound related.

I've added the .lib file to my project directory and the .dll in the right folder.

Now, i'm trying to create a sound on the main screen of the game as such:
file.h
include "irrklang.h"
include "conio.h"
pragma comment(lib, "irrKlang.lib")

class something
{
protected:
irrklang::ISoundEngine* engine;
}

file.cpp
engine = irrklang::createIrrKlangDevice();
engine->play2D("getout.ogg", true);

everything compiles fine but i can't hear any sound and the debug table says:

irrKlang sound library version 1.4.0
Loaded plugin: ikpflac.dll
Loaded plugin: ikpmp3.dll
Using DirectSound8 driver
Could not open sound file: getout.ogg

Any idea why the file isn't opened? :s

plz help me

EDIT: i tried using
play2D("getout.ogg", false, false, true);
but didn't change anything :P


niko
Moderator
Quote
2013-05-26 07:54:32

If you enter the full path to the file, does it work then? Probably the file cannot be loaded from your current working directory.


lagger
Registered User
Quote
2013-05-26 22:41:53

yup tried that :S still no work.

can the path in the linker be causing this? (i just placed the .lib file in the project directory)
im at a lost and have totally no clue why this is happening. i'm all out of ideas :S


lagger
Registered User
Quote
2013-05-28 20:12:36

no idea anyone ? :S


niko
Moderator
Quote
2013-05-28 21:51:33

The linker doesn't have to do anything with that. Are you sure you entered the full path correctly? Note that if it includes special charaters like \, then you need to escape them, like this: \\


lagger
Registered User
Quote
2013-05-28 22:17:43

AAAAAAAAAAA
omg that fixed it!!! THX NIKO you are the BEST!

the double "\" fixed it!

So happy right now :D THX!


Create reply:


Posted by: (you are not logged in)


Enter the missing letter in: "Intern?tional" (you are not logged in)


Text:

 

  

Possible Codes


Feature Code
Link [url] www.example.com [/url]
Bold [b]bold text[/b]
Image [img]http://www.example.com/image.jpg[/img]
Quote [quote]quoted text[/quote]
Code [code]source code[/code]

Emoticons


   






Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact