$RIFFheader =
$this->
fread(12
);
$offset =
$this->
ftell();
$RIFFtype =
substr($RIFFheader, 0, 4
);
$RIFFsize =
substr($RIFFheader, 4, 4
);
$RIFFsubtype =
substr($RIFFheader, 8, 4
);
switch ($RIFFtype) { case 'FORM': // AIFF, AIFC
//$info['fileformat'] = 'aiff';
$this->container = 'aiff';
$thisfile_riff['header_size'
] =
$this->
EitherEndian2Int($RIFFsize);
$thisfile_riff[$RIFFsubtype] =
$this->
ParseRIFF($offset,
($offset +
$thisfile_riff['header_size'
] - 4
));
break;
case 'RIFF': // AVI, WAV, etc
case 'SDSS': // SDSS is identical to RIFF, just renamed. Used by SmartSound QuickTracks (www.smartsound.com)
case 'RMP3': // RMP3 is identical to RIFF, just renamed. Used by [unknown program] when creating RIFF-MP3s
//$info['fileformat'] = 'riff';
$this->container = 'riff';
$thisfile_riff['header_size'
] =
$this->
EitherEndian2Int($RIFFsize);
if ($RIFFsubtype == 'RMP3'
) { // RMP3 is identical to WAVE, just renamed. Used by [unknown program] when creating RIFF-MP3s