Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ffmpeg
Commits
1ef9e837
Commit
1ef9e837
authored
Aug 03, 2014
by
Kieran Kunhya
Committed by
Diego Biurrun
Aug 03, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avcodec: Deprecate dtg_active_format field in favor of avframe side-data
Signed-off-by:
Diego Biurrun
<
diego@biurrun.de
>
parent
d0393d79
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
50 additions
and
4 deletions
+50
-4
APIchanges
doc/APIchanges
+4
-0
avcodec.h
libavcodec/avcodec.h
+4
-1
mpeg12dec.c
libavcodec/mpeg12dec.c
+19
-1
version.h
libavcodec/version.h
+4
-1
vf_showinfo.c
libavfilter/vf_showinfo.c
+3
-0
frame.h
libavutil/frame.h
+15
-0
version.h
libavutil/version.h
+1
-1
No files found.
doc/APIchanges
View file @
1ef9e837
...
@@ -13,6 +13,10 @@ libavutil: 2013-12-xx
...
@@ -13,6 +13,10 @@ libavutil: 2013-12-xx
API changes, most recent first:
API changes, most recent first:
2014-08-xx - xxxxxxx - lavc 55.57.2 - avcodec.h
2014-08-xx - xxxxxxx - lavu 53.20.0 - frame.h
Deprecate AVCodecContext.dtg_active_format and use side-data instead.
2014-08-xx - xxxxxxx - lavc 55.57.1 - avcodec.h
2014-08-xx - xxxxxxx - lavc 55.57.1 - avcodec.h
Deprecate unused FF_IDCT_IPP define and ipp avcodec option.
Deprecate unused FF_IDCT_IPP define and ipp avcodec option.
Deprecate unused FF_DEBUG_PTS define and pts avcodec option.
Deprecate unused FF_DEBUG_PTS define and pts avcodec option.
...
...
libavcodec/avcodec.h
View file @
1ef9e837
...
@@ -1503,6 +1503,7 @@ typedef struct AVCodecContext {
...
@@ -1503,6 +1503,7 @@ typedef struct AVCodecContext {
*/
*/
int
me_subpel_quality
;
int
me_subpel_quality
;
#if FF_API_AFD
/**
/**
* DTG active format information (additional aspect ratio
* DTG active format information (additional aspect ratio
* information only used in DVB MPEG-2 transport streams)
* information only used in DVB MPEG-2 transport streams)
...
@@ -1510,8 +1511,9 @@ typedef struct AVCodecContext {
...
@@ -1510,8 +1511,9 @@ typedef struct AVCodecContext {
*
*
* - encoding: unused
* - encoding: unused
* - decoding: Set by decoder.
* - decoding: Set by decoder.
* @deprecated Deprecated in favor of AVSideData
*/
*/
int
dtg_active_format
;
attribute_deprecated
int
dtg_active_format
;
#define FF_DTG_AFD_SAME 8
#define FF_DTG_AFD_SAME 8
#define FF_DTG_AFD_4_3 9
#define FF_DTG_AFD_4_3 9
#define FF_DTG_AFD_16_9 10
#define FF_DTG_AFD_16_9 10
...
@@ -1519,6 +1521,7 @@ typedef struct AVCodecContext {
...
@@ -1519,6 +1521,7 @@ typedef struct AVCodecContext {
#define FF_DTG_AFD_4_3_SP_14_9 13
#define FF_DTG_AFD_4_3_SP_14_9 13
#define FF_DTG_AFD_16_9_SP_14_9 14
#define FF_DTG_AFD_16_9_SP_14_9 14
#define FF_DTG_AFD_SP_4_3 15
#define FF_DTG_AFD_SP_4_3 15
#endif
/* FF_API_AFD */
/**
/**
* maximum motion estimation search range in subpel units
* maximum motion estimation search range in subpel units
...
...
libavcodec/mpeg12dec.c
View file @
1ef9e837
...
@@ -54,6 +54,8 @@ typedef struct Mpeg1Context {
...
@@ -54,6 +54,8 @@ typedef struct Mpeg1Context {
int
has_stereo3d
;
int
has_stereo3d
;
uint8_t
*
a53_caption
;
uint8_t
*
a53_caption
;
int
a53_caption_size
;
int
a53_caption_size
;
uint8_t
afd
;
int
has_afd
;
int
slice_count
;
int
slice_count
;
int
save_aspect_info
;
int
save_aspect_info
;
int
save_width
,
save_height
,
save_progressive_seq
;
int
save_width
,
save_height
,
save_progressive_seq
;
...
@@ -1631,6 +1633,18 @@ static int mpeg_field_start(MpegEncContext *s, const uint8_t *buf, int buf_size)
...
@@ -1631,6 +1633,18 @@ static int mpeg_field_start(MpegEncContext *s, const uint8_t *buf, int buf_size)
*
stereo
=
s1
->
stereo3d
;
*
stereo
=
s1
->
stereo3d
;
s1
->
has_stereo3d
=
0
;
s1
->
has_stereo3d
=
0
;
}
}
if
(
s1
->
has_afd
)
{
AVFrameSideData
*
sd
=
av_frame_new_side_data
(
s
->
current_picture_ptr
->
f
,
AV_FRAME_DATA_AFD
,
1
);
if
(
!
sd
)
return
AVERROR
(
ENOMEM
);
*
sd
->
data
=
s1
->
afd
;
s1
->
has_afd
=
0
;
}
if
(
HAVE_THREADS
&&
(
avctx
->
active_thread_type
&
FF_THREAD_FRAME
))
if
(
HAVE_THREADS
&&
(
avctx
->
active_thread_type
&
FF_THREAD_FRAME
))
ff_thread_finish_setup
(
avctx
);
ff_thread_finish_setup
(
avctx
);
}
else
{
// second field
}
else
{
// second field
...
@@ -2221,6 +2235,7 @@ static void mpeg_decode_user_data(AVCodecContext *avctx,
...
@@ -2221,6 +2235,7 @@ static void mpeg_decode_user_data(AVCodecContext *avctx,
const
uint8_t
*
p
,
int
buf_size
)
const
uint8_t
*
p
,
int
buf_size
)
{
{
const
uint8_t
*
buf_end
=
p
+
buf_size
;
const
uint8_t
*
buf_end
=
p
+
buf_size
;
Mpeg1Context
*
s1
=
avctx
->
priv_data
;
/* we parse the DTG active format information */
/* we parse the DTG active format information */
if
(
buf_end
-
p
>=
5
&&
if
(
buf_end
-
p
>=
5
&&
...
@@ -2234,7 +2249,11 @@ static void mpeg_decode_user_data(AVCodecContext *avctx,
...
@@ -2234,7 +2249,11 @@ static void mpeg_decode_user_data(AVCodecContext *avctx,
if
(
flags
&
0x40
)
{
if
(
flags
&
0x40
)
{
if
(
buf_end
-
p
<
1
)
if
(
buf_end
-
p
<
1
)
return
;
return
;
#if FF_API_AFD
avctx
->
dtg_active_format
=
p
[
0
]
&
0x0f
;
avctx
->
dtg_active_format
=
p
[
0
]
&
0x0f
;
#endif
/* FF_API_AFD */
s1
->
has_afd
=
1
;
s1
->
afd
=
p
[
0
]
&
0x0f
;
}
}
}
else
if
(
buf_end
-
p
>=
6
&&
}
else
if
(
buf_end
-
p
>=
6
&&
p
[
0
]
==
'J'
&&
p
[
1
]
==
'P'
&&
p
[
2
]
==
'3'
&&
p
[
3
]
==
'D'
&&
p
[
0
]
==
'J'
&&
p
[
1
]
==
'P'
&&
p
[
2
]
==
'3'
&&
p
[
3
]
==
'D'
&&
...
@@ -2246,7 +2265,6 @@ static void mpeg_decode_user_data(AVCodecContext *avctx,
...
@@ -2246,7 +2265,6 @@ static void mpeg_decode_user_data(AVCodecContext *avctx,
S3D_video_format_type
==
0x04
||
S3D_video_format_type
==
0x04
||
S3D_video_format_type
==
0x08
||
S3D_video_format_type
==
0x08
||
S3D_video_format_type
==
0x23
)
{
S3D_video_format_type
==
0x23
)
{
Mpeg1Context
*
s1
=
avctx
->
priv_data
;
s1
->
has_stereo3d
=
1
;
s1
->
has_stereo3d
=
1
;
...
...
libavcodec/version.h
View file @
1ef9e837
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
#define LIBAVCODEC_VERSION_MAJOR 55
#define LIBAVCODEC_VERSION_MAJOR 55
#define LIBAVCODEC_VERSION_MINOR 57
#define LIBAVCODEC_VERSION_MINOR 57
#define LIBAVCODEC_VERSION_MICRO
1
#define LIBAVCODEC_VERSION_MICRO
2
#define LIBAVCODEC_VERSION_INT AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \
#define LIBAVCODEC_VERSION_INT AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \
LIBAVCODEC_VERSION_MINOR, \
LIBAVCODEC_VERSION_MINOR, \
...
@@ -147,5 +147,8 @@
...
@@ -147,5 +147,8 @@
#ifndef FF_API_CODEC_NAME
#ifndef FF_API_CODEC_NAME
#define FF_API_CODEC_NAME (LIBAVCODEC_VERSION_MAJOR < 57)
#define FF_API_CODEC_NAME (LIBAVCODEC_VERSION_MAJOR < 57)
#endif
#endif
#ifndef FF_API_AFD
#define FF_API_AFD (LIBAVCODEC_VERSION_MAJOR < 57)
#endif
#endif
/* AVCODEC_VERSION_H */
#endif
/* AVCODEC_VERSION_H */
libavfilter/vf_showinfo.c
View file @
1ef9e837
...
@@ -122,6 +122,9 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
...
@@ -122,6 +122,9 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
av_log
(
ctx
,
AV_LOG_INFO
,
"displaymatrix: rotation of %.2f degrees"
,
av_log
(
ctx
,
AV_LOG_INFO
,
"displaymatrix: rotation of %.2f degrees"
,
av_display_rotation_get
((
int32_t
*
)
sd
->
data
));
av_display_rotation_get
((
int32_t
*
)
sd
->
data
));
break
;
break
;
case
AV_FRAME_DATA_AFD
:
av_log
(
ctx
,
AV_LOG_INFO
,
"afd: value of %"
PRIu8
,
sd
->
data
[
0
]);
break
;
default:
default:
av_log
(
ctx
,
AV_LOG_WARNING
,
"unknown side data type %d (%d bytes)"
,
av_log
(
ctx
,
AV_LOG_WARNING
,
"unknown side data type %d (%d bytes)"
,
sd
->
type
,
sd
->
size
);
sd
->
type
,
sd
->
size
);
...
...
libavutil/frame.h
View file @
1ef9e837
...
@@ -82,6 +82,21 @@ enum AVFrameSideDataType {
...
@@ -82,6 +82,21 @@ enum AVFrameSideDataType {
* See libavutil/display.h for a detailed description of the data.
* See libavutil/display.h for a detailed description of the data.
*/
*/
AV_FRAME_DATA_DISPLAYMATRIX
,
AV_FRAME_DATA_DISPLAYMATRIX
,
/**
* Active Format Description data consisting of a single byte as specified
* in ETSI TS 101 154 using enum AVActiveFormatDescription.
*/
AV_FRAME_DATA_AFD
,
};
enum
AVActiveFormatDescription
{
AV_AFD_SAME
=
8
,
AV_AFD_4_3
=
9
,
AV_AFD_16_9
=
10
,
AV_AFD_14_9
=
11
,
AV_AFD_4_3_SP_14_9
=
13
,
AV_AFD_16_9_SP_14_9
=
14
,
AV_AFD_SP_4_3
=
15
,
};
};
typedef
struct
AVFrameSideData
{
typedef
struct
AVFrameSideData
{
...
...
libavutil/version.h
View file @
1ef9e837
...
@@ -54,7 +54,7 @@
...
@@ -54,7 +54,7 @@
*/
*/
#define LIBAVUTIL_VERSION_MAJOR 53
#define LIBAVUTIL_VERSION_MAJOR 53
#define LIBAVUTIL_VERSION_MINOR
19
#define LIBAVUTIL_VERSION_MINOR
20
#define LIBAVUTIL_VERSION_MICRO 0
#define LIBAVUTIL_VERSION_MICRO 0
#define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
#define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment