Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: SFML 3 - What is your vision?  (Read 94008 times)

0 Members and 1 Guest are viewing this topic.

binary1248

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1374
  • I am awesome.
    • View Profile
    • The server that really shouldn't be running
Re: SFML 3 - What is your vision?
« Reply #210 on: July 05, 2014, 04:59:11 am »
It all depends on the underlying audio format... Some formats save their sample count in the header of the file, which is the first thing that gets read by sf::SoundBuffer. It would be able to return the total sample count without having to load the whole file that way. Also, if you have worked with std::fstream before, you would know that it too supports reporting the number of bytes in a file without actually having to load it all into memory. It most probably makes use of lower level filesystem APIs to get this done.

I can assure you that given the right conditions, you can get true sample by sample streaming, even if the file is multiple gigabytes large ;).
SFGUI # SFNUL # GLS # Wyrm <- Why do I waste my time on such a useless project? Because I am awesome (first meaning).

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32060
    • View Profile
    • SFML's website
    • Email
Re: SFML 3 - What is your vision?
« Reply #211 on: July 05, 2014, 08:44:56 am »
EFX is supported by OpenAL Soft, so it would work on Windows, most Linuxes and Android. But I have no idea if these extensions are supported on Mac OS X and iOS. It could be worth investigating.
Laurent Gomila - SFML developer

achpile

  • Full Member
  • ***
  • Posts: 221
    • View Profile
    • Achpile's homepage
    • Email
Re: SFML 3 - What is your vision?
« Reply #212 on: July 15, 2014, 01:06:01 am »
The thing I always wanted is z-index for Drawable class  ;D

Hanmac

  • Newbie
  • *
  • Posts: 20
    • View Profile
    • Email
Re: SFML 3 - What is your vision?
« Reply #213 on: July 15, 2014, 05:48:43 am »
i was thinking a bit about Spites and SoundSource and SoundListener ...
hm first, make a BaseInterface moveable, its for controling the Position and Direction of Sprite/(BigSprite)/SoundSource ... so you can both add Sprites and SoundSources into an Array and move them around ...

then i was thinking about a helper template like SpriteWithSound<sf::Sprite,sf::SoundSource> ... with that you have a moveable sprite and the SoundSource is always connected to the Sprite postion and location, same for SpriteWithSoundListener<sf::Sprite> (because the Listener is some kind of singleton?)

my idea was so that you can move around the WithSound objects and the 3d sound effect is already managed for you?

PS: that was only an idea, i dont know if its to high or low for SFML itself (only the Moveable interface might be interesting, but it might be collide, with Transformable)

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32060
    • View Profile
    • SFML's website
    • Email
Re: SFML 3 - What is your vision?
« Reply #214 on: July 15, 2014, 07:40:41 am »
Quote
i was thinking a bit about Spites and SoundSource and SoundListener ...
hm first, make a BaseInterface moveable, its for controling the Position and Direction of Sprite/(BigSprite)/SoundSource ..
No no no... Sounds have 3D positions, sprites have 2D positions. Sounds have no direction. And most important: there's no dependency between the audio and graphics modules, and there will never be. It's up to you to synchronize audio and graphics, this is a high level task.
Laurent Gomila - SFML developer

Flaco

  • Newbie
  • *
  • Posts: 36
  • Glory to Arztotzka!
    • View Profile
    • Core Unit
    • Email
Re: SFML 3 - What is your vision?
« Reply #215 on: July 15, 2014, 12:25:24 pm »
That's a great thread, nice idea here. :)

I don't really know, since I never have been in the depth of SFML and its use.
But here's a little list:

  • Making C++11 use and integration non-optional
  • Integrating some of Tor features directly in SFML functions if there's high-level or "misc." functions, providing them as well in a dedicated module
  • Maybe supporting vectorial files (.swg and such)?

Thanks! :)

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6155
  • Thor Developer
    • View Profile
    • Bromeon
Re: SFML 3 - What is your vision?
« Reply #216 on: July 15, 2014, 04:04:37 pm »
Integrating some of Tor features directly in SFML functions if there's high-level or "misc." functions, providing them as well in a dedicated module
Just a note for al future posters: The main idea is to add features to SFML that extension libraries (like Thor, sfeMovie, SFGUI) wouldn't be able to implement because of a limitation within SFML itself. They are built on top of SFML and provide higher-level functionality as Laurent already said. Suggestions here should be targeted towards lower level things that have to be in core SFML to be made accessible to said higher-level libraries or your own code.

I have the feeling that this is not the last time we post this here ;)

By the way, Tor is something different :)
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development: first SFML book

Hanmac

  • Newbie
  • *
  • Posts: 20
    • View Profile
    • Email
Re: SFML 3 - What is your vision?
« Reply #217 on: July 15, 2014, 04:14:42 pm »
Quote
i was thinking a bit about Spites and SoundSource and SoundListener ...
hm first, make a BaseInterface moveable, its for controling the Position and Direction of Sprite/(BigSprite)/SoundSource ..
No no no... Sounds have 3D positions, sprites have 2D positions. Sounds have no direction. And most important: there's no dependency between the audio and graphics modules, and there will never be. It's up to you to synchronize audio and graphics, this is a high level task.

 ??? now i am ashamed ... Listener did had direction, not SoundSource ... and yeah i did think about to connect them, but i did also think about that it might be complications with other stuff like Thor Animation and Particle System i did use so when they should animate the object, the Sound might not follow the Sprite
(i need to experiment a bit with that)

hmmm now i am thinking if SoundSource should have a direction too, so like you can only hear it if the speaker is showing into your direction ...
hmmm2: i also did think there might be some value for the current acceleration of the SoundSourceObject so it might the detect if its moving to you or away from you, (for the Doppler Effect) or is that already managed by AL?

PS: thats my thoughts as i did thougt about a 3d-sound sample for SFML itself

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6155
  • Thor Developer
    • View Profile
    • Bromeon
Re: SFML 3 - What is your vision?
« Reply #218 on: July 15, 2014, 04:20:53 pm »
??? now i am ashamed ... Listener did had direction, not SoundSource ...
It still has, but that doesn't change the fact that it doesn't make sense to store sprites and sounds or sound listeners together. What you actually want is an abstraction layer in between, most likely a scene graph. This is definitely not SFML's task.

but i did also think about that it might be complications with other stuff like Thor Animation and Particle System i did use so when they should animate the object, the Sound might not follow the Sprite
That sounds very confused. Animations, particles and sounds are widely independent components, how you combine them depends entirely on your game's code design. Again not something SFML should care about.

hmmm now i am thinking if SoundSource should have a direction too, so like you can only hear it if the speaker is showing into your direction ...
hmmm2: i also did think there might be some value for the current acceleration of the SoundSourceObject so it might the detect if its moving to you or away from you, (for the Doppler Effect) or is that already managed by AL?
Are you actually requiring those features or are those just spontaneous ideas? I ask because we have enough ideas on what would be possible, but we prefer implementing the useful ones first ;)

(Apart from that, these are also things that depend highly on the game, and can be implemented without modifying SFML; e.g. by changing frequency and volume depending on the position and orientation)
« Last Edit: July 15, 2014, 04:23:04 pm by Nexus »
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development: first SFML book

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32060
    • View Profile
    • SFML's website
    • Email
Re: SFML 3 - What is your vision?
« Reply #219 on: July 15, 2014, 04:24:35 pm »
Quote
hmmm now i am thinking if SoundSource should have a direction too, so like you can only hear it if the speaker is showing into your direction ...
This doesn't make sense (even in real life), sounds propagate in all directions.

Doppler effect is supported by OpenAL but it is not exposed by SFML.
Laurent Gomila - SFML developer

Hanmac

  • Newbie
  • *
  • Posts: 20
    • View Profile
    • Email
Re: SFML 3 - What is your vision?
« Reply #220 on: July 15, 2014, 04:41:54 pm »

??? now i am ashamed ... Listener did had direction, not SoundSource ...
It still has, but that doesn't change the fact that it doesn't make sense to store sprites and sounds or sound listeners together. What you actually want is an abstraction layer in between, most likely a scene graph. This is definitely not SFML's task.
i also did thought about some kind of SceneGraph ... currently i dont know if i can get it working right impl drawable into that SceneGraph might not be a problem, but Transformable for sample is, because its functions are not virtual for overloading ... :/
but like i said i need to test stuff until it works right

Quote
hmmm now i am thinking if SoundSource should have a direction too, so like you can only hear it if the speaker is showing into your direction ...
This doesn't make sense (even in real life), sounds propagate in all directions.

Doppler effect is supported by OpenAL but it is not exposed by SFML.
i was thinking in form of PC speakers ... like for them you cant hear them (right) when you are on the wrong end ...
Oh ok if doppler already exist in AL then its okay ... i didnt know that and i thought SFML might need more work than just "exposing"

paupav

  • Full Member
  • ***
  • Posts: 155
    • View Profile
    • Email
Re: SFML 3 - What is your vision?
« Reply #221 on: July 16, 2014, 07:36:56 am »
Blender Support.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32060
    • View Profile
    • SFML's website
    • Email
Re: SFML 3 - What is your vision?
« Reply #222 on: July 16, 2014, 08:32:45 am »
Quote
Blender Support.
Thank you for this amazing contribution.

This "idea" seems to be completely off-topic, but you can explain it with more details if you want...
Laurent Gomila - SFML developer

paupav

  • Full Member
  • ***
  • Posts: 155
    • View Profile
    • Email
Re: SFML 3 - What is your vision?
« Reply #223 on: July 16, 2014, 12:12:23 pm »
Quote
Blender Support.
Thank you for this amazing contribution.

This "idea" seems to be completely off-topic, but you can explain it with more details if you want...
I'm thinking about something like allegro5/Blender.
Also why are you so arrogant?
« Last Edit: July 16, 2014, 12:21:46 pm by paupav »

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32060
    • View Profile
    • SFML's website
    • Email
Re: SFML 3 - What is your vision?
« Reply #224 on: July 16, 2014, 12:46:27 pm »
Because I don't like your attitude. In this thread, we try to collect detailed and meaningful ideas for the future of SFML. Posting a reply with only two words in it, that only you understand, is not respectful for the community and the SFML team. You didn't even care to write a proper sentence.

So please explain what you want (ok, Allegro 5 has it... I still don't know what it is) or stop posting. Thank you.
Laurent Gomila - SFML developer

 

anything