videoeditorengine/avcedit/inc/sequence.h
changeset 0 951a5db380a0
equal deleted inserted replaced
-1:000000000000 0:951a5db380a0
       
     1 /*
       
     2 * Copyright (c) 2010 Ixonos Plc.
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - Initial contribution
       
    11 *
       
    12 * Contributors:
       
    13 * Ixonos Plc
       
    14 *
       
    15 * Description:
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 #ifndef _SEQUENCE_H_
       
    21 #define _SEQUENCE_H_
       
    22 
       
    23 
       
    24 #include "globals.h"
       
    25 #include "framebuffer.h"
       
    26 #include "slice.h"
       
    27 #include "bitbuffer.h"
       
    28 
       
    29 
       
    30 /*
       
    31  * Definitions of NAL types
       
    32  */
       
    33 #define NAL_TYPE_UNSPECIFIED      0
       
    34 #define NAL_TYPE_CODED_SLICE      1
       
    35 #define NAL_TYPE_CODED_SLICE_P_A  2
       
    36 #define NAL_TYPE_CODED_SLICE_P_B  3
       
    37 #define NAL_TYPE_CODED_SLICE_P_C  4
       
    38 #define NAL_TYPE_CODED_SLICE_IDR  5
       
    39 #define NAL_TYPE_SEI              6
       
    40 #define NAL_TYPE_SPS              7
       
    41 #define NAL_TYPE_PPS              8
       
    42 #define NAL_TYPE_PIC_DELIMITER    9
       
    43 #define NAL_TYPE_END_SEQ          10
       
    44 #define NAL_TYPE_END_STREAM       11
       
    45 #define NAL_TYPE_FILLER_DATA      12
       
    46 
       
    47 
       
    48 typedef struct _sequence_s 
       
    49 {
       
    50 
       
    51   dpb_s *dpb;
       
    52 
       
    53   frmBuf_s *outputQueue[DPB_MAX_SIZE];
       
    54   int outputQueuePos;
       
    55   int numQueuedOutputPics;
       
    56 
       
    57   bitbuffer_s *bitbuf;
       
    58 
       
    59   int sliceNums[PS_MAX_NUM_SLICE_GROUPS];
       
    60 
       
    61   seq_parameter_set_s *spsList[PS_MAX_NUM_OF_SPS];
       
    62   pic_parameter_set_s *ppsList[PS_MAX_NUM_OF_PPS];
       
    63 
       
    64   slice_s *currSlice;
       
    65   slice_s *nextSlice;
       
    66 
       
    67   int isFirstSliceOfSeq;
       
    68   int isPicBoundary;
       
    69   int isCurrPicFinished;
       
    70   int isDpbStorePending;
       
    71   int isSeqFinished;
       
    72 
       
    73   unsigned int redundantPicCnt;
       
    74 
       
    75   int32 unusedShortTermFrameNum;
       
    76   int32 prevFrameNum;
       
    77   int32 prevRefFrameNum;
       
    78 
       
    79   /* for POC type 0 : */
       
    80   int32 pocMsb;
       
    81   int32 prevPocMsb;
       
    82   int32 prevPocLsb;
       
    83   /* for POC type 1 : */
       
    84   int32 frameNumOffset;
       
    85   int32 prevFrameNumOffset;
       
    86 
       
    87   /* The previous decoded picture in decoding order includes */
       
    88   /* a memory_management_control_operation equal to 5        */
       
    89   int prevPicHasMMCO5; 
       
    90                        
       
    91   mbAttributes_s *mbData;
       
    92   frmBuf_s *recoBuf;
       
    93 
       
    94   TUint iFrameNumber;
       
    95   TUint iFromEncoder;
       
    96   TUint sliceDataModified;
       
    97   	    
       
    98   TBool iEncodeUntilIDR;	//	Encoded beginning of a clip has different SPS than the original
       
    99   TBool iBitShiftInSlice;
       
   100   
       
   101   TUint iNumSPS;
       
   102   TUint iNumPPS;
       
   103   
       
   104   TUint iPreviousPPSId;
       
   105 
       
   106   // [KW]: For testing, remove later!!!
       
   107   TUint iTotalFrameNumber;
       
   108 
       
   109 } sequence_s;
       
   110 
       
   111 
       
   112 #endif