[FFmpeg-cvslog] avcodec/h264_sei: remove redundant prefix to H264SEIFramePacking fields
James Almer
git at videolan.org
Fri Dec 1 06:37:44 EET 2017
ffmpeg | branch: master | James Almer <jamrial at gmail.com> | Fri Dec 1 01:09:43 2017 -0300| [5e9b39b373215104dbcf59e161b3755466f18859] | committer: James Almer
avcodec/h264_sei: remove redundant prefix to H264SEIFramePacking fields
Cosmetic change.
Signed-off-by: James Almer <jamrial at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=5e9b39b373215104dbcf59e161b3755466f18859
---
libavcodec/h264_parser.c | 2 +-
libavcodec/h264_sei.c | 18 +++++++++---------
libavcodec/h264_sei.h | 8 ++++----
libavcodec/h264_slice.c | 6 +++---
libavcodec/h264dec.c | 2 +-
5 files changed, 18 insertions(+), 18 deletions(-)
diff --git a/libavcodec/h264_parser.c b/libavcodec/h264_parser.c
index 39f97e00a6..65d9d44b50 100644
--- a/libavcodec/h264_parser.c
+++ b/libavcodec/h264_parser.c
@@ -259,7 +259,7 @@ static inline int parse_nal_units(AVCodecParserContext *s,
s->picture_structure = AV_PICTURE_STRUCTURE_UNKNOWN;
ff_h264_sei_uninit(&p->sei);
- p->sei.frame_packing.frame_packing_arrangement_cancel_flag = -1;
+ p->sei.frame_packing.arrangement_cancel_flag = -1;
if (!buf_size)
return 0;
diff --git a/libavcodec/h264_sei.c b/libavcodec/h264_sei.c
index 27a37247b5..9defcb80b9 100644
--- a/libavcodec/h264_sei.c
+++ b/libavcodec/h264_sei.c
@@ -313,12 +313,12 @@ static int decode_buffering_period(H264SEIBufferingPeriod *h, GetBitContext *gb,
static int decode_frame_packing_arrangement(H264SEIFramePacking *h,
GetBitContext *gb)
{
- h->frame_packing_arrangement_id = get_ue_golomb_long(gb);
- h->frame_packing_arrangement_cancel_flag = get_bits1(gb);
- h->present = !h->frame_packing_arrangement_cancel_flag;
+ h->arrangement_id = get_ue_golomb_long(gb);
+ h->arrangement_cancel_flag = get_bits1(gb);
+ h->present = !h->arrangement_cancel_flag;
if (h->present) {
- h->frame_packing_arrangement_type = get_bits(gb, 7);
+ h->arrangement_type = get_bits(gb, 7);
h->quincunx_sampling_flag = get_bits1(gb);
h->content_interpretation_type = get_bits(gb, 6);
@@ -328,10 +328,10 @@ static int decode_frame_packing_arrangement(H264SEIFramePacking *h,
// frame0_self_contained_flag, frame1_self_contained_flag
skip_bits(gb, 2);
- if (!h->quincunx_sampling_flag && h->frame_packing_arrangement_type != 5)
+ if (!h->quincunx_sampling_flag && h->arrangement_type != 5)
skip_bits(gb, 16); // frame[01]_grid_position_[xy]
skip_bits(gb, 8); // frame_packing_arrangement_reserved_byte
- h->frame_packing_arrangement_repetition_period = get_ue_golomb_long(gb);
+ h->arrangement_repetition_period = get_ue_golomb_long(gb);
}
skip_bits1(gb); // frame_packing_arrangement_extension_flag
@@ -465,8 +465,8 @@ int ff_h264_sei_decode(H264SEIContext *h, GetBitContext *gb,
const char *ff_h264_sei_stereo_mode(const H264SEIFramePacking *h)
{
- if (h->frame_packing_arrangement_cancel_flag == 0) {
- switch (h->frame_packing_arrangement_type) {
+ if (h->arrangement_cancel_flag == 0) {
+ switch (h->arrangement_type) {
case H264_SEI_FPA_TYPE_CHECKERBOARD:
if (h->content_interpretation_type == 2)
return "checkerboard_rl";
@@ -501,7 +501,7 @@ const char *ff_h264_sei_stereo_mode(const H264SEIFramePacking *h)
default:
return "mono";
}
- } else if (h->frame_packing_arrangement_cancel_flag == 1) {
+ } else if (h->arrangement_cancel_flag == 1) {
return "mono";
} else {
return NULL;
diff --git a/libavcodec/h264_sei.h b/libavcodec/h264_sei.h
index 817b4eaae9..9488382b9f 100644
--- a/libavcodec/h264_sei.h
+++ b/libavcodec/h264_sei.h
@@ -119,10 +119,10 @@ typedef struct H264SEIBufferingPeriod {
typedef struct H264SEIFramePacking {
int present;
- int frame_packing_arrangement_id;
- int frame_packing_arrangement_cancel_flag; ///< is previous arrangement canceled, -1 if never received
- H264_SEI_FpaType frame_packing_arrangement_type;
- int frame_packing_arrangement_repetition_period;
+ int arrangement_id;
+ int arrangement_cancel_flag; ///< is previous arrangement canceled, -1 if never received
+ H264_SEI_FpaType arrangement_type;
+ int arrangement_repetition_period;
int content_interpretation_type;
int quincunx_sampling_flag;
int current_frame_is_frame0_flag;
diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c
index fff3112649..d9377a8a1c 100644
--- a/libavcodec/h264_slice.c
+++ b/libavcodec/h264_slice.c
@@ -1198,13 +1198,13 @@ static int h264_export_frame_props(H264Context *h)
}
if (h->sei.frame_packing.present &&
- h->sei.frame_packing.frame_packing_arrangement_type <= 6 &&
+ h->sei.frame_packing.arrangement_type <= 6 &&
h->sei.frame_packing.content_interpretation_type > 0 &&
h->sei.frame_packing.content_interpretation_type < 3) {
H264SEIFramePacking *fp = &h->sei.frame_packing;
AVStereo3D *stereo = av_stereo3d_create_side_data(cur->f);
if (stereo) {
- switch (fp->frame_packing_arrangement_type) {
+ switch (fp->arrangement_type) {
case 0:
stereo->type = AV_STEREO3D_CHECKERBOARD;
break;
@@ -1234,7 +1234,7 @@ static int h264_export_frame_props(H264Context *h)
if (fp->content_interpretation_type == 2)
stereo->flags = AV_STEREO3D_FLAG_INVERT;
- if (fp->frame_packing_arrangement_type == 5) {
+ if (fp->arrangement_type == 5) {
if (fp->current_frame_is_frame0_flag)
stereo->view = AV_STEREO3D_VIEW_LEFT;
else
diff --git a/libavcodec/h264dec.c b/libavcodec/h264dec.c
index b03024d4a3..1d99ed5f4c 100644
--- a/libavcodec/h264dec.c
+++ b/libavcodec/h264dec.c
@@ -319,7 +319,7 @@ static int h264_init_context(AVCodecContext *avctx, H264Context *h)
h->x264_build = -1;
h->frame_recovered = 0;
h->poc.prev_frame_num = -1;
- h->sei.frame_packing.frame_packing_arrangement_cancel_flag = -1;
+ h->sei.frame_packing.arrangement_cancel_flag = -1;
h->sei.unregistered.x264_build = -1;
h->next_outputed_poc = INT_MIN;
More information about the ffmpeg-cvslog
mailing list