MP4(3)

πŸ“¦ version 2.1.0, in fedora 43, fedora 44

πŸŽ€ NAME πŸŽ€

ok so bestie, MP4GetTrackAudioType β€” it gets the encoding type of an audio track πŸ’– that's literally it, that's the whole job, and honestly? iconic.


✨ SYNTAX ✨

#include <mp4.h>

u_int8_t MP4GetTrackAudioType(
     MP4FileHandle hFile,
     MP4TrackId trackId
)

no cap, that's the whole thing. two arguments, one little u_int8_t coming back at you 🌸


🫢 ARGUMENTS 🫢

  • hFile β€” this is the mp4 file we're doing the operation on, okay? like the actual file handle, the main character of the whole situation πŸ‘‘
  • trackId β€” and this one specifies the track whose audio type you're tryna find out. the specific track. the one you want. 🎯

πŸ’… RETURN VALUES πŸ’…

bestie, listen:

  • if it works? you get the audio type of the track. slay. πŸ¦‹
  • if it does NOT work? you get MP4_INVALID_AUDIO_TYPE back. not slay. 😭
so like… always check, fr fr. don't just assume the vibe was good.

🌈 DESCRIPTION 🌈

MP4GetTrackAudioType returns the encoding type of the specified audio track in the mp4 file. that's the whole plot πŸ“

and here's the tea β€” these are the known audio encoding types, the whole roster, no skips:

  • MP4_MPEG1_AUDIO_TYPE β€” MPEG-1 Audio Layers I, II, & III ⭐
  • MP4_MPEG2_AUDIO_TYPE β€” MPEG-2 low bitrate extensions to MPEG-1 Audio. also, plot twist: MP4_MP3_AUDIO_TYPE is an alias for this value πŸ‘€ (yes really, they're the same thing, don't let anyone tell you otherwise)
  • MP4_MPEG2_AAC_MAIN_AUDIO_TYPE β€” MPEG-2 AAC Main profile 🎧
  • MP4_MPEG2_AAC_LC_AUDIO_TYPE β€” MPEG-2 AAC Low Complexity profile 🧚
  • MP4_MPEG2_AAC_SSR_AUDIO_TYPE β€” MPEG-2 AAC SSR profile ✨
  • MP4_MPEG4_AUDIO_TYPE β€” MPEG-4 Audio, and it includes MPEG-4 extensions to AAC. highkey a lot going on in this one πŸ’œ
  • MP4_PRIVATE_AUDIO_TYPE β€” user private type. it's giving mysterious. it's giving you know what you put in there πŸ™ˆ

πŸ”₯ SEE ALSO πŸ”₯

like obviously go read those too, iykyk πŸ“š


and that's the whole page bestie, from the mp4 file format library β€” brought to you by Cisco Systems Inc., Version 0.9, and the entire MP4(3) manual moment πŸ’–βœ¨ go forth and check your audio types, periodt πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from