Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Help
»
Audio
»
sf::Sound by value
Print
Pages: [
1
]
Author
Topic: sf::Sound by value (Read 2936 times)
0 Members and 1 Guest are viewing this topic.
Serapth
Full Member
Posts: 105
sf::Sound by value
«
on:
November 10, 2011, 07:52:43 pm »
Hello all,
I just want to verify, SoundBuffer is heavy and should be cached, but sf::Sound itself is light weight and passing it by value should not be a big deal, right?
Logged
Laurent
Administrator
Hero Member
Posts: 32498
sf::Sound by value
«
Reply #1 on:
November 11, 2011, 11:33:30 am »
Yes. However it is not as lightweight as a sf::Sprite or sf::Text. sf::Sound internally manages an OpenAL sound resource, so it's not trivial to copy and destroy.
Logged
Laurent Gomila - SFML developer
Print
Pages: [
1
]
SFML community forums
»
Help
»
Audio
»
sf::Sound by value
anything