ambiera home ambiera home

Ambiera Forum

Discussions, Help and Support.

Create a new account, Search, or Login:
Name:  Password:    
Ambiera Forum > irrKlang
I have a doubt about ISound::drop
Author Text

gabriel
Registered User
Quote
2017-07-11 14:48:11

When I call method drop still music keep playing.

ISoundEngine *engine = createIrrKlangDevice();

ISound *sound = engine->play2D("PIL.mp3",false,false,true);
sound->setPlayPosition(15000);

sound->drop() ;

int c;
cin >> c;

engine->drop();


erik
Registered User
Quote
2017-07-12 13:40:41

Drop won't stop playing the music. Stop() will.


gabriel
Guest
Quote
2017-07-14 03:06:26

So what method drop does?


niko
Moderator
Quote
2017-07-14 08:59:08

It is just a standard reference counting mechanism. Drop() says you don't need the object anymore. But that doesn't mean that it gets deleted. Likely the engine needs it still. Only if the last owner calls drop(), then the object gets deleted.

Also see the documentation for this.


Create reply:


Posted by: (you are not logged in)


Enter the missing letter in: "Interna?ional" (you are not logged in)


Text:

 

  

Forum 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


   





Software: Ambiera Light Forum. © 2008-2015 Nikolaus Gebhardt, Ambiera e.U.