aboutsummaryrefslogtreecommitdiff
path: root/Src/Plugins/Input/in_flv/FLVAudioHeader.h
diff options
context:
space:
mode:
authorJean-Francois Mauguit <jfmauguit@mac.com>2024-09-24 09:03:25 -0400
committerGitHub <noreply@github.com>2024-09-24 09:03:25 -0400
commitbab614c421ed7ae329d26bf028c4a3b1d2450f5a (patch)
tree12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/Plugins/Input/in_flv/FLVAudioHeader.h
parent4bde6044fddf053f31795b9eaccdd2a5a527d21f (diff)
parent20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (diff)
downloadwinamp-bab614c421ed7ae329d26bf028c4a3b1d2450f5a.tar.gz
Merge pull request #5 from WinampDesktop/community
Merge to main
Diffstat (limited to 'Src/Plugins/Input/in_flv/FLVAudioHeader.h')
-rw-r--r--Src/Plugins/Input/in_flv/FLVAudioHeader.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/Src/Plugins/Input/in_flv/FLVAudioHeader.h b/Src/Plugins/Input/in_flv/FLVAudioHeader.h
new file mode 100644
index 00000000..8a749a4a
--- /dev/null
+++ b/Src/Plugins/Input/in_flv/FLVAudioHeader.h
@@ -0,0 +1,31 @@
+#ifndef NULLSOFT_FLVAUDIOHEADER_H
+#define NULLSOFT_FLVAUDIOHEADER_H
+
+namespace FLV
+{
+ const int AUDIO_FORMAT_PCM = 0;
+ const int AUDIO_FORMAT_ADPCM = 1;
+ const int AUDIO_FORMAT_MP3 = 2;
+ const int AUDIO_FORMAT_PCM_LE = 3; // little endian
+ const int AUDIO_FORMAT_NELLYMOSER_16KHZ = 4;
+ const int AUDIO_FORMAT_NELLYMOSER_8KHZ = 5;
+ const int AUDIO_FORMAT_NELLYMOSER = 6;
+ const int AUDIO_FORMAT_A_LAW = 7;
+ const int AUDIO_FORMAT_MU_LAW = 8;
+ const int AUDIO_FORMAT_AAC = 10;
+ const int AUDIO_FORMAT_MP3_8KHZ = 14;
+
+};
+
+class FLVAudioHeader
+{
+public:
+ bool Read(unsigned __int8 *data, size_t size); // size must be >=1, returns "true" if this was a valid header
+
+ // attributes, consider these read-only
+ bool stereo;
+ int bits;
+ int sampleRate;
+ int format;
+};
+#endif \ No newline at end of file