Home | History | Annotate | Download | only in include
      1 /* ------------------------------------------------------------------
      2  * Copyright (C) 1998-2009 PacketVideo
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License");
      5  * you may not use this file except in compliance with the License.
      6  * You may obtain a copy of the License at
      7  *
      8  *      http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS,
     12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
     13  * express or implied.
     14  * See the License for the specific language governing permissions
     15  * and limitations under the License.
     16  * -------------------------------------------------------------------
     17  */
     18 /*
     19     This DecoderSpecificInfo Class that holds the Mpeg4 VOL header for the
     20     video stream
     21 */
     22 
     23 #ifndef DECODERSPECIFICINFO_H_INCLUDED
     24 #define DECODERSPECIFICINFO_H_INCLUDED
     25 
     26 #ifndef OSCL_BASE_H_INCLUDED
     27 #include "oscl_base.h"
     28 #endif
     29 #ifndef OSCL_FILE_IO_H_INCLUDED
     30 #include "oscl_file_io.h"
     31 #endif
     32 #ifndef BASEDESCRIPTOR_H_INCLUDED
     33 #include "basedescriptor.h"
     34 #endif
     35 
     36 class DecoderSpecificInfo : BaseDescriptor
     37 {
     38 
     39     public:
     40         DecoderSpecificInfo(MP4_FF_FILE *fp, bool o3GPPTrack = false,
     41                             bool read_struct = true); // Stream-in Constructor
     42         virtual ~DecoderSpecificInfo(); // Destructor
     43 
     44         // Member get methods
     45         uint32 getInfoSize() const
     46         {
     47             return _infoSize;    // Returns the size of the info data
     48         }
     49         uint8 *getInfo() const
     50         {
     51             return _pinfo;    // Returns the byte pointer to info
     52         }
     53 
     54         uint32 getSizeOfClass() const
     55         {
     56             return _infoSize + 4;
     57         }
     58 
     59         void setInfoSize(uint32 size)
     60         {
     61             _infoSize = size;
     62         }
     63 
     64         void setInfo(uint8* info)
     65         {
     66             _pinfo = info;
     67         }
     68 
     69     private:
     70         uint8 *_pinfo;
     71         int32 _infoSize;
     72 };
     73 
     74 #endif // DECODERSPECIFICINFO_H_INCLUDED
     75 
     76