flat assembler
Message board for the users of flat assembler.
Index
> Windows > music player |
Author |
|
r22 06 Jul 2011, 13:14
For playback mciSendStringA API
http://board.flatassembler.net/topic.php?t=12888 For listing files FindFirstFile and FindNextFile APIs http://msdn.microsoft.com/en-us/library/aa364419%28v=vs.85%29.aspx Or you could use the open file dialog GetOpenFileName API http://msdn.microsoft.com/en-us/library/ms646927%28v=vs.85%29.aspx For visualizing the data it gets a little tricky. You need the sound data in PCM format (bytes/words that represent the amplitude of the wave). I high pitched sound PCM would be like 0 5 10 20 30 20 10 5 0 A low frequency sound PCM would be 0 1 2 3 4 5 6 7 8 9 8 7 6 5 4 3 2 1 You'd plot it on the screen or in a graphics engine like the windows sound recorder does. You could use a library like LAME or other library to convert MP3 to WAV then you'd be able to play the sound in OpenAL and visualize it with OpenGL mp3 to wav libmad http://www.codeproject.com/KB/audio-video/madlldlib.aspx open al play wav http://www.edenwaith.com/products/pige/tutorials/openal.php#code |
|||
06 Jul 2011, 13:14 |
|
edfed 06 Jul 2011, 14:37
cool.
about the signal representation, lets say it will use only the envellope of the song. for very short files like samples, the signal will be displayed dot per dot. this is the scope part. thank you for the playback part keywords, now i will learn more about this openAL thing, i hope it is something like win9x compatible. then, if you believe it is forced to use something like lame to convert mp3 to wav, i will do it, because i don't want (and don't have hability) to code the mp3 decoder now. but latter, it can be interresting to write something like MP3 codec in asm. then, lets go for the reading. |
|||
06 Jul 2011, 14:37 |
|
goldenspider 09 Jul 2011, 15:13
You can use mpg123 ,LAME or other library to convert MP3 to WAV .
http://www.mpg123.de/ http://www.asmcommunity.net/board/index.php?topic=30509.0 |
|||
09 Jul 2011, 15:13 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.