History

avcodec/motion_est: Move ff_h263_round_chroma() to h263.h

Andreas Rheinhardt committed 1 year ago

Commit 35fecd31 parent ec6c8e55 files · +13 −10Browse files

Unified · Split

5 files
  1. libavcodec/h263.h +10 −0
  2. libavcodec/motion_est.c +1 −0
  3. libavcodec/motion_est.h +0 −10
  4. libavcodec/mpegvideo_dec.c +1 −0
  5. libavcodec/mpegvideo_motion.c +1 −0
libavcodec/h263.h+10−0
@@ -27,6 +27,16 @@ · 26 unmodified lines
27 27
28#define H263_GOB_HEIGHT(h) ((h) <= 400 ? 1 : (h) <= 800 ? 2 : 4)28#define H263_GOB_HEIGHT(h) ((h) <= 400 ? 1 : (h) <= 800 ? 2 : 4)
29 29
30static inline int ff_h263_round_chroma(int x)
31{
32 //FIXME static or not?
33 static const uint8_t h263_chroma_roundtab[16] = {
34 // 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
35 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1,
36 };
37 return h263_chroma_roundtab[x & 0xf] + (x >> 3);
38}
39
30av_const int ff_h263_aspect_to_info(AVRational aspect);40av_const int ff_h263_aspect_to_info(AVRational aspect);
31int16_t *ff_h263_pred_motion(MpegEncContext * s, int block, int dir,41int16_t *ff_h263_pred_motion(MpegEncContext * s, int block, int dir,
32 int *px, int *py);42 int *px, int *py);
libavcodec/motion_est.c+1−0
@@ -32,6 +32,7 @@ · 31 unmodified lines
32#include <limits.h>32#include <limits.h>
33 33
34#include "avcodec.h"34#include "avcodec.h"
35#include "h263.h"
35#include "mathops.h"36#include "mathops.h"
36#include "motion_est.h"37#include "motion_est.h"
37#include "mpegutils.h"38#include "mpegutils.h"
libavcodec/motion_est.h+0−10
@@ -106,16 +106,6 @@ typedef struct MotionEstContext { · 105 unmodified lines
106 int size, int h);106 int size, int h);
107} MotionEstContext;107} MotionEstContext;
108 108
109static inline int ff_h263_round_chroma(int x)
110{
111 //FIXME static or not?
112 static const uint8_t h263_chroma_roundtab[16] = {
113 // 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
114 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1,
115 };
116 return h263_chroma_roundtab[x & 0xf] + (x >> 3);
117}
118
119/**109/**
120 * Performs one-time initialization of the MotionEstContext.110 * Performs one-time initialization of the MotionEstContext.
121 */111 */
libavcodec/mpegvideo_dec.c+1−0
@@ -32,6 +32,7 @@ · 31 unmodified lines
32 32
33#include "avcodec.h"33#include "avcodec.h"
34#include "decode.h"34#include "decode.h"
35#include "h263.h"
35#include "h264chroma.h"36#include "h264chroma.h"
36#include "internal.h"37#include "internal.h"
37#include "mpegutils.h"38#include "mpegutils.h"
libavcodec/mpegvideo_motion.c+1−0
@@ -29,6 +29,7 @@ · 28 unmodified lines
29 29
30#include "avcodec.h"30#include "avcodec.h"
31#include "h261.h"31#include "h261.h"
32#include "h263.h"
32#include "mpegutils.h"33#include "mpegutils.h"
33#include "mpegvideo.h"34#include "mpegvideo.h"
34#include "mpeg4videodec.h"35#include "mpeg4videodec.h"

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t