Fix small defects

git-svn-id: http://php-reader.googlecode.com/svn/trunk@112 51a70ab9-7547-0410-9469-37e369ee0574
This commit is contained in:
svollbehr
2008-09-21 17:56:29 +00:00
parent 9a76bb7e06
commit 07a5e6bd3c
2 changed files with 10 additions and 5 deletions

View File

@@ -48,6 +48,7 @@ require_once("ISO14496/Box/Full.php");
* @package php-reader
* @subpackage ISO 14496
* @author Sven Vollbehr <svollbehr@gmail.com>
* @author Anders Ödlund <odlund@gmail.com>
* @copyright Copyright (c) 2008 The PHP Reader Project Workgroup
* @license http://code.google.com/p/php-reader/wiki/License New BSD License
* @version $Rev$
@@ -58,7 +59,10 @@ final class ISO14496_Box_TFHD extends ISO14496_Box_Full
private $_trackId;
/** @var integer */
private $_defaultSampleDescriptionIndex;
private $_baseDataOffset;
/** @var integer */
private $_sampleDescriptionIndex;
/** @var integer */
private $_defaultSampleDuration;
@@ -95,7 +99,7 @@ final class ISO14496_Box_TFHD extends ISO14496_Box_Full
const DEFAULT_SAMPLE_SIZE = 0x10;
/** Indicates the precense of the defaultSampleFlags field. */
const DEFAULT_SAMPLE_DURATION = 0x20;
const DEFAULT_SAMPLE_FLAGS = 0x20;
/**
* Indicates that the duration provided in either defaultSampleDuration, or by
@@ -155,7 +159,7 @@ final class ISO14496_Box_TFHD extends ISO14496_Box_Full
*/
public function getSampleDescriptionIndex()
{
return $this->_defaultSampleDescriptionIndex;
return $this->_sampleDescriptionIndex;
}
/**

View File

@@ -47,6 +47,7 @@ require_once("ISO14496/Box/Full.php");
* @package php-reader
* @subpackage ISO 14496
* @author Sven Vollbehr <svollbehr@gmail.com>
* @author Anders Ödlund <odlund@gmail.com>
* @copyright Copyright (c) 2008 The PHP Reader Project Workgroup
* @license http://code.google.com/p/php-reader/wiki/License New BSD License
* @version $Rev$
@@ -120,7 +121,7 @@ final class ISO14496_Box_TRUN extends ISO14496_Box_Full
$sample["size"] = $this->_reader->readUInt32BE();
if ($this->hasFlag(self::SAMPLE_FLAGS))
$sample["flags"] = $this->_reader->readUInt32BE();
if ($this->hasFlag(self::SAMPLE_COMPOSITION_TIME_OFFSET))
if ($this->hasFlag(self::SAMPLE_COMPOSITION_TIME_OFFSETS))
$sample["compositionTimeOffset"] = $this->_reader->readUInt32BE();
$this->_samples[] = $sample;
$this->_flags = $flags;
@@ -134,7 +135,7 @@ final class ISO14496_Box_TRUN extends ISO14496_Box_Full
*/
public function getDataOffset()
{
return $this->_trackId;
return $this->_dataOffset;
}
/**