Home | History | Annotate | Download | only in videoencoder
      1 /*
      2 * Copyright (c) 2009-2011 Intel Corporation.  All rights reserved.
      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 express or implied.
     13 * See the License for the specific language governing permissions and
     14 * limitations under the License.
     15 */
     16 
     17 #ifndef __VIDEO_ENCODER_VP8_H__
     18 #define __VIDEO_ENCODER_VP8_H__
     19 
     20 #include "VideoEncoderBase.h"
     21 
     22 /**
     23   * VP8 Encoder class, derived from VideoEncoderBase
     24   */
     25 class VideoEncoderVP8: public VideoEncoderBase {
     26 public:
     27     VideoEncoderVP8();
     28     virtual ~VideoEncoderVP8();
     29     virtual Encode_Status start();
     30 
     31 
     32 
     33 protected:
     34     virtual Encode_Status sendEncodeCommand(EncodeTask *task);
     35     virtual Encode_Status derivedSetParams(VideoParamConfigSet *videoEncParams);
     36     virtual Encode_Status derivedGetParams(VideoParamConfigSet *videoEncParams);
     37     virtual Encode_Status derivedGetConfig(VideoParamConfigSet *videoEncConfig);
     38     virtual Encode_Status derivedSetConfig(VideoParamConfigSet *videoEncConfig);
     39     virtual Encode_Status getExtFormatOutput(VideoEncOutputBuffer *) {
     40         return ENCODE_NOT_SUPPORTED;
     41     }
     42 
     43     // Local Methods
     44 private:
     45         Encode_Status renderSequenceParams();
     46         Encode_Status renderPictureParams(EncodeTask *task);
     47         Encode_Status renderRCParams(uint32_t layer_id, bool total_bitrate);
     48         Encode_Status renderHRDParams(void);
     49         Encode_Status renderFrameRateParams(uint32_t layer_id, bool total_framerate);
     50         Encode_Status renderMaxFrameSizeParams(void);
     51         Encode_Status renderLayerStructureParam(void);
     52 
     53         VideoConfigVP8 mVideoConfigVP8;
     54         VideoParamsVP8 mVideoParamsVP8;
     55         VideoConfigVP8ReferenceFrame mVideoConfigVP8ReferenceFrame;
     56 };
     57 
     58 #endif /* __VIDEO_ENCODER_VP8_H__ */
     59