[FFmpeg-devel] [FFMPEG] [PATCH] cavs encoder

Michael Niedermayer michaelni
Tue Dec 8 19:55:06 CET 2009


On Thu, Nov 19, 2009 at 10:04:02AM +0800, zhihang wang wrote:
> 6. other simple changes
> 
> -- 
> Best Regards
> zhihang wang(???)

> Index: libavcodec/mpegvideo.h
> ===================================================================
> --- libavcodec/mpegvideo.h	(revision 20544)
> +++ libavcodec/mpegvideo.h	(working copy)
> @@ -85,7 +85,10 @@
>      /**
>       * halfpel luma planes.
>       */
> -    uint8_t *interpolated[3];
> +#define IPL_BUF 16
> +    uint8_t *interpolated[IPL_BUF];
> +    uint16_t* buffer[3]; ///used to save the tmp interpolated pixels
> +    uint16_t* tmp_buf[3];///pointer, points to buffer
>      int16_t (*motion_val_base[2])[2];
>      uint32_t *mb_type_base;
>  #define MB_TYPE_INTRA MB_TYPE_INTRA4x4 //default mb_type if there is just one type
> @@ -191,6 +194,12 @@
>                                    int size, int h);
>  }MotionEstContext;
> 
> +DECLARE_ALIGNED_8(typedef, struct) {
> +    int16_t x;
> +    int16_t y;
> +    int16_t dist;
> +    int16_t ref;
> +} cavs_vector;
>  /**
>   * MpegEncContext.
>   */
> @@ -248,7 +257,9 @@
>      Picture **reordered_input_picture; ///< pointer to the next pictures in codedorder for encoding
> 
>      int start_mb_y;            ///< start mb_y of this thread (so current thread should process start_mb_y <= row < end_mb_y)
> +    int start_mb_x;            ///< start mb_x of this thread (so current thread should process start_mb_x <= column < end_mb_x)
>      int end_mb_y;              ///< end   mb_y of this thread (so current thread should process start_mb_y <= row < end_mb_y)
> +    int end_mb_x;              ///< end   mb_x of this thread (so current thread should process start_mb_x <= row < end_mb_x)
>      struct MpegEncContext *thread_context[MAX_THREADS];
> 
>      /**
> @@ -676,6 +687,8 @@
>  } MpegEncContext;
> 
> 
> +int ff_load_input_picture(MpegEncContext *s, AVFrame *pic_arg);
> +void ff_select_input_picture(MpegEncContext *s);
>  void MPV_decode_defaults(MpegEncContext *s);
>  int MPV_common_init(MpegEncContext *s);
>  void MPV_common_end(MpegEncContext *s);

iam not sure what a cavs encoder has in common with mpegvideo, especially
if you arent using the existing motion estimation code it seems there is
not much in common and the code does not belong in here.
but maybe iam missing something ...


[...]

> Index: doc/developer.texi
> ===================================================================
> --- doc/developer.texi	(revision 20544)
> +++ doc/developer.texi	(working copy)
> @@ -252,6 +252,8 @@
>  if it spans multiple files. This makes reviewing your patches much easier
>  for us and greatly increases your chances of getting your patch applied.
> 
> +Use the patcheck tool of ffmpeg to check your patch. The tool is located in the tool directory.
> +
>  Run the regression tests before submitting a patch so that you can
>  verify that there are no big problems.

this hunk is probably ok


[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Avoid a single point of failure, be that a person or equipment.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20091208/e772681d/attachment.pgp>



More information about the ffmpeg-devel mailing list