...software that analyzes an audio file, and translates its length to frames.
This would be a lifesaver for many reasons, but I'll just state a crucial one (for me, at least):
The project I'm working on is voice acting heavy (voice in Earl's head, audio logs, and so on), so having a program
that can give me the exact amount of frames to wait with for a particular audio file would be amazing.
Right now, it's a big mess trying to get it just right, you know?
Of course, nobody has to make this; I'm just suggesting in case anyone would like to give it a try, is all.
That should be easy enough. Just punch in the length in seconds into a calculator and multiply it by 20.
Yeah, that works too.
Just would be nice to have a drag-and-drop type of thing do the calculation for me, because I'm a lazy fuck.
Still, good suggestion. I'll go with it.
To be honest, what you want could be done very quickly in C#. There should be a library that can open a bunch of formats. All somebody had to do is use a tree-view where you select the file and it displays the time in frames. But trust me, using a calculator really isn't a big deal.
Keep in mind that 20 is for events. Within scripts, the number of frames in a second is 40.
Yeah, it isn't a big deal for me to use the calculator, trust me. lol
I mean, I can live without the program, definitely. It's just something that'd be nice to have and use, if it did exist.
Was just trying to see if I could motivate someone to spark it into existence by making this topic.
But yeah, I'm just going to stick with the calculator.
Though, if the program talked about in this topic ever is created, I'll move my penis on over to it.
I will add this to Rpg.NET.
I think I can manage to do it without any third-party libraries. There is only a few formats for RM, so doing a few calculations to determine the duration of the few types won't be that difficult.
MCI, a built-in Window's API, has this ability.
F0, I love you. <3
RPG.NET is seriously going to rock my anal caverns! :D
That reminds me, I should update the thread. I've implemented some pretty nifty new things. Mostly still working on Bitmap manipulation at the moment...
DO IT!
Quote from: Colonel Blinx on July 19, 2014, 12:44:07 am
...software that analyzes an audio file, and translates its length to frames.
This would be a lifesaver for many reasons, but I'll just state a crucial one (for me, at least):
The project I'm working on is voice acting heavy (voice in Earl's head, audio logs, and so on), so having a program
that can give me the exact amount of frames to wait with for a particular audio file would be amazing.
Right now, it's a big mess trying to get it just right, you know?
Of course, nobody has to make this; I'm just suggesting in case anyone would like to give it a try, is all.
Added to Rpg.NET. :)
Made two functiions:
The first returns the duration in milliseconds.
The second gets a frame rate passed to it and will return the duration in number of frames.
Fuck yes! You rock, man. :)
Doesn't work with MIDI, though.
As far as I know, that really isn't going to be possible, or at least within the scope, of this project. I don't know a way to get the duration of a MIDI file except to convert it to another format such as WAV and read it that way. Needless to say, that is not a simple task, and it would be a bigger project to do that than what I am currently doing. There are a very few third-party libraries out there that can do it, but I am not going to add any (rather large) dependencies just to accomplish it. As far as I know, they work as I already said and convert it to another format to read it, which is horrible inefficient.
I don't even use MIDI anyways, lol.
Quote from: ForeverZer0 on July 19, 2014, 11:40:47 am
Doesn't work with MIDI, though.
As far as I know, that really isn't going to be possible, or at least within the scope, of this project. I don't know a way to get the duration of a MIDI file except to convert it to another format such as WAV and read it that way. Needless to say, that is not a simple task, and it would be a bigger project to do that than what I am currently doing. There are a very few third-party libraries out there that can do it, but I am not going to add any (rather large) dependencies just to accomplish it. As far as I know, they work as I already said and convert it to another format to read it, which is horrible inefficient.
Isn't that is because MIDI isn't a music file on it's own, but a kind of sequence. Right?
Quote from: Praelium on July 19, 2014, 12:44:38 pm
Isn't that is because MIDI isn't a music file on it's own, but a kind of sequence. Right?
Exactly, MIDI is just "sheet music" that tells the system which notes to generate, there is no actual sound data. Its nice because it allows for extremely small file sizes compared to audio files, but is such a complete and utter pain in the ass to deal with. When creating programs that use various audio formats, you can more or less deal with them in the same ways, just making some exceptions for the specific type, but MIDI is a whole different animal, and has absolutely nothing in common with other common audio formats. I don't even worry about trying to maintain MIDI compatibility anymore, its just not worth the hassle.
Mostly Incompatible Due to Idiocy
Quote from: ForeverZer0 on July 19, 2014, 12:58:55 pm
Quote from: Praelium on July 19, 2014, 12:44:38 pm
Isn't that is because MIDI isn't a music file on it's own, but a kind of sequence. Right?
Exactly, MIDI is just "sheet music" that tells the system which notes to generate, there is no actual sound data. Its nice because it allows for extremely small file sizes compared to audio files, but is such a complete and utter pain in the ass to deal with. When creating programs that use various audio formats, you can more or less deal with them in the same ways, just making some exceptions for the specific type, but MIDI is a whole different animal, and has absolutely nothing in common with other common audio formats. I don't even worry about trying to maintain MIDI compatibility anymore, its just not worth the hassle.
Though I wish there were more formats that allowed multi-layer audio. Maybe there are formats, but I don't know about them. Someone should make a format where you have all he layers separately and can edit them separately in the most common audio software.
MIDI was a fantastic source of music on PCs while the disk drives and and RAMs were still small. And it's still used today by music producers since they allow you to easily exchange sheet data for songs, etc. But as useful as it is, yes, it's a pain to implement, because there are many, many commands to implement and worse even, every synthesizer usually implements certain things their own way so the reproduction is inconsistent over different synthesizers and systems.