-
-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rename AudioStreamPlayer{,2D,3D}
or VideoPlayer
for consistency
#3624
Comments
Sorry if wrong place to as but isn't stream player like player what reads data from disk as it plays? (This is how it was teached to me long ago I studied game engines). I tried to look from documentation but there wasn't anything how to play audio file from preloaded audio file, so I guess this handles all in one / only way to play data? |
If you have no project that needs this, why should it be done? |
@amatrelan The AudioStreamPlayer is called like so because it plays the audio from its AudioStream |
I'm not sure I understand what this accomplishes. Less typing I guess, but I can't remember the last time I typed "AudioStreamPlayer" other than while providing help for people in the Discord. I usually just have to type "audio" into the node type picker dialog and then I click on the one I want. Also correct me if I'm wrong but we're likely removing the video player in 4.0 so that solves our consistency problem. |
I have not found any suggestions to remove VideoPlayer.
In this case, nothing will change for you either. |
It wasn't so much suggested, as it was decided due to problems with supporting it. You can find Calinou mentioning the likelihood of it in various "VideoPlayer" related proposals, for example. |
That's not quite true though, because all my projects will break, and all of everybody else's projects will also break. Not badly, but there are already people using Godot 4 so it's something to consider. While I wouldn't hesitate to break everyone's projects to make a rename that would clear up some confusion, this rename seems like it doesn't really solve confusion as much as making things shorter. I don't know. I think my stance on this is pretty neutral but I don't agree that it's zero-cost. |
I'm not sure if something doesn't work very well, then we can just delete it altogether.
This argument works even if the
Yes, I agree that this is not zero cost. But IMO this is a very small cost.
These people are using an unstable version (even alpha testing has not started yet), so they should be prepared for the fact that backward compatibility can break several times before release. |
Edit: Following reduz's comment below, I no longer think renaming AudioStreamPlayer nodes to AudioPlayer is a good idea. Renaming AudioStreamPlayer to AudioPlayer seems good to me. Since streaming is something that happens automatically behind the scenes (and the user doesn't need to know about it), I feel like "Stream" isn't a necessary distinction here. There is also no more non-streamed audio playback since Godot 3.0.
The VideoPlayer node won't be removed in 4.0, but the core video decoders will be. There will still be a GDExtension interface that will be used in an official add-on to support video playback. |
I agree, in this stage it's useless even think that master branch is not breaking things for backwards compatibility. And to rename all |
We don't stream audio from disk though, do we? Some AudioStreams are actual streams like microphone input, but AudioStreamSample, AudioStreamOggVorbis and AudioStreamMP3 all just load the whole file into memory I think. |
If However, if we rename the base class We also have to keep in mind that Godot tries to follow the convention of naming classes according to the base. Yet
There's |
There is a clear difference between VideoPlayer and AudioStreamPlayer. VideoPlayer plays a video file, it does not do streaming. AudioStream plays a stream of audio, which can be the an audio file or sound generated by a multitude of ways (microphone, sound generator, etc). An AudioStream is not necesarily a file. As such, AudioStreamPlayer makes more sense. The problem is more because of VideoPlayer more limited nature. This class is very seldom used so we will eventually move the video decoding code to an external extension for Godot 4.0. As such, I think these classes should be revisited, determine if VideoStream actually meets that expectation and either rename VideoStream to VideoFile, or VideoPlayer to VideoStreamPlayer. |
Regardless of file or stream-based approaches, I think this should rather be an implementation detail anyway, especially for the engine like Godot, where simplicity is preferred over complexity for the most part, if I'm not mistaken. |
I suggest renaming VideoPlayer to VideoStreamPlayer, which solves the ambiguity and is consistent with other classes:
Starting with Godot 3, and even more so with Godot 4, we've gone to great length to make the API more explicit, and I don't see much gain here in removing the explicitness. Moreover, VideoPlayer is used a lot less than AudioStreamPlayer, so renaming VideoPlayer has much less impact on users and documentation/tutorials. |
This is also a good option, and this is what I originally suggested. The reverse was my second idea, but it got much more support. Both options are good, but the option that people support is doubly good. I think people supported the simplification option because in this case the clarification is really unnecessary, the user does not care what the audio is: a file or a stream. I think clarifications are only needed when their absence would cause confusion for the user. If the purpose of the node is clear without clarification, then it is superfluous. And besides, we have other examples of abbreviations, like |
By now there are several solutions:
Therefore, I think there's no consensus here (yet). |
I love that people are so passionate about improving Godot audio, but in my opinion this is far from the biggest problem we have right now. There is at least one major crashing bug remaining in the 4.0 audio system that I don't really have time to fix, and there are several quality of life improvements we could make with a bit of effort. If you're interested in Godot audio, here are some bugs that need fixing right now that would be good for a new contributor. godotengine/godot#54821, godotengine/godot#53718 and godotengine/godot#52853 come to mind. I'm happy to provide guidance on any of these, especially the last two (they should be addressed at the same time and may require some discussion). godotengine/godot#55608 (and related issues) would be another good one to address for 4.0, but will be a bit more involved. I'm not trying to derail discussion here, but I just want to recognize that we're all here because we want what's best for the engine, and I want to suggest some alternate ways we could spend our time. Because like @Xrayez said, we don't have a consensus and getting to a consensus will require some work on the part of all of us that we could be spending making the existing audio system behave correctly. Edit: I know this isn't zero-sum, but I'm swamped by these bugs so I just wanted to ask for help :) |
I'm sorry if I brought some controversy to the community with my proposal, I didn't mean it. This was supposed to be just one of the many 4.0 renames that are already happening. I am not trying to be principled and do not rate this as any significant or even important contribution. It's just an opportunity to make Godot a little better. That which is within the limits of my small knowledge and capabilities. But I donβt think this proposal is wasting the contributors' time in any way. In Open Source, people spend time on what they want to spend time on, no matter how important the problem is. You cannot get people to βdo more important things,β even if they are really more important. And sometimes it is difficult to assess the importance of the problem. |
I'm not trying to force anyone to do anything, merely asking for help. Sorry. |
If it's an audio file it's not streaming. From Wikipedia:
Therefore using |
Streaming has multiple meanings and that's the "newest" one. Streaming in software can be also streaming from files, you read it as you play it, what also in a sense is Streaming. Another way to take data is to load whole file in memory, what is generally used in Game engines in sound effects what can be played multiple times and kept in memory even after play ends, so it can be played again without any delay. |
@ellenhp here's my proposal: lets rename the class as proposed here ( |
You're very welcome to help fix audio issues, but proposing a barter like this to lobby for an unrelated proposal is not appropriate. |
Fair. But in this case, the argument "there are more important problems" does not work either. This proposal should be considered on its own, whether there are more important issues or not. Since this comment, our discussion has veered in the wrong direction. |
I explained it here, but I will paste the same comment here:
In any case, if you want to leave this proposal open I am fine, but for the time being you don't have my consensus to go forward with it. |
This is a pretty bad attitude to have and I would suggest refraining from doing similar comments in the future. It's up to you to fix bugs or not, but do not condition your help to others based on their design choices. |
@dalexeev yes, you are right. "ΠΠ°ΠΊ Π°ΡΠΊΠ½Π΅ΡΡΡ, ΡΠ°ΠΊ ΠΈ ΠΎΡΠΊΠ»ΠΈΠΊΠ½Π΅ΡΡΡ" (for non-Russian speakers, this means: "What goes around, comes around"). |
In this case, following @reduz 's comment, the conclusion of this proposal would be to rename |
Done: godotengine/godot#55670. |
Democracy... has not won. π But if this is the vision of the project maintainers, I will no longer argue and support this decision. |
It's a player for `VideoStream` resources, just like `AudioStreamPlayer` is a player for `AudioStream` resources. Closes godotengine/godot-proposals#3624.
Either way works, but I don't understand how adding/keeping "Stream" makes it more clear. I mean, sure it makes it more explicit that it plays streams of audio, but it doesn't reduce ambiguity or add clarity. With things like StaticBody -> StaticBody3D, there is confusion with the similarly named StaticBody2D, so the 3D suffix differentiates it. With AudioStreamPlayer, if there aren't any non-stream audio player nodes, then what is the point of the "Stream" part? There aren't any non-stream audio players to disambiguate it from. Similarly, if we wanted to rename StaticBody3D to PhysicsStaticBody3D, you could say that the "Physics" makes it more explicit because it's for physics, but since there aren't any non-physics StaticBody3Ds, how does it help with clarity and disambiguity? |
Describe the project you are working on
Not related.
Describe the problem or limitation you are having in your project
@dalexeev godotengine/godot#16863 (comment) (6 π)
godotengine/godot#46997 (11 π 4 π)
@mhilbrunner
@madmiraal
@mhilbrunner
Describe the feature / enhancement and how it helps to overcome the problem or limitation
We have to choose one of the options:
VideoPlayer
toVideoStreamPlayer
.Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
Just renaming.
If this enhancement will not be used often, can it be worked around with a few lines of script?
No.
Is there a reason why this should be core and not an add-on in the asset library?
This is part of the renaming in 4.0 aimed at improving naming consistency.
The text was updated successfully, but these errors were encountered: