Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
小白菜888
Ffmpeg
提交
3a057670
F
Ffmpeg
项目概览
小白菜888
/
Ffmpeg
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
F
Ffmpeg
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
3a057670
编写于
2月 13, 2014
作者:
V
Vittorio Giovara
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
h264: store current_sps_id inside the current sps
In preparation for MVC support.
上级
73e8fab3
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
4 addition
and
5 deletion
+4
-5
libavcodec/h264.c
libavcodec/h264.c
+2
-3
libavcodec/h264.h
libavcodec/h264.h
+1
-1
libavcodec/h264_ps.c
libavcodec/h264_ps.c
+1
-1
未找到文件。
libavcodec/h264.c
浏览文件 @
3a057670
...
@@ -3414,12 +3414,11 @@ static int decode_slice_header(H264Context *h, H264Context *h0)
...
@@ -3414,12 +3414,11 @@ static int decode_slice_header(H264Context *h, H264Context *h0)
return
AVERROR_INVALIDDATA
;
return
AVERROR_INVALIDDATA
;
}
}
if
(
h
->
pps
.
sps_id
!=
h
->
current_
sps_id
||
if
(
h
->
pps
.
sps_id
!=
h
->
sps
.
sps_id
||
h0
->
sps_buffers
[
h
->
pps
.
sps_id
]
->
new
)
{
h0
->
sps_buffers
[
h
->
pps
.
sps_id
]
->
new
)
{
h0
->
sps_buffers
[
h
->
pps
.
sps_id
]
->
new
=
0
;
h0
->
sps_buffers
[
h
->
pps
.
sps_id
]
->
new
=
0
;
h
->
current_sps_id
=
h
->
pps
.
sps_id
;
h
->
sps
=
*
h0
->
sps_buffers
[
h
->
pps
.
sps_id
];
h
->
sps
=
*
h0
->
sps_buffers
[
h
->
pps
.
sps_id
];
if
(
h
->
bit_depth_luma
!=
h
->
sps
.
bit_depth_luma
||
if
(
h
->
bit_depth_luma
!=
h
->
sps
.
bit_depth_luma
||
h
->
chroma_format_idc
!=
h
->
sps
.
chroma_format_idc
)
{
h
->
chroma_format_idc
!=
h
->
sps
.
chroma_format_idc
)
{
...
...
libavcodec/h264.h
浏览文件 @
3a057670
...
@@ -146,6 +146,7 @@ typedef enum {
...
@@ -146,6 +146,7 @@ typedef enum {
* Sequence parameter set
* Sequence parameter set
*/
*/
typedef
struct
SPS
{
typedef
struct
SPS
{
unsigned
int
sps_id
;
int
profile_idc
;
int
profile_idc
;
int
level_idc
;
int
level_idc
;
int
chroma_format_idc
;
int
chroma_format_idc
;
...
@@ -353,7 +354,6 @@ typedef struct H264Context {
...
@@ -353,7 +354,6 @@ typedef struct H264Context {
ptrdiff_t
mb_linesize
;
///< may be equal to s->linesize or s->linesize * 2, for mbaff
ptrdiff_t
mb_linesize
;
///< may be equal to s->linesize or s->linesize * 2, for mbaff
ptrdiff_t
mb_uvlinesize
;
ptrdiff_t
mb_uvlinesize
;
unsigned
current_sps_id
;
///< id of the current SPS
SPS
sps
;
///< current sps
SPS
sps
;
///< current sps
/**
/**
...
...
libavcodec/h264_ps.c
浏览文件 @
3a057670
...
@@ -318,6 +318,7 @@ int ff_h264_decode_seq_parameter_set(H264Context *h)
...
@@ -318,6 +318,7 @@ int ff_h264_decode_seq_parameter_set(H264Context *h)
if
(
!
sps
)
if
(
!
sps
)
return
AVERROR
(
ENOMEM
);
return
AVERROR
(
ENOMEM
);
sps
->
sps_id
=
sps_id
;
sps
->
time_offset_length
=
24
;
sps
->
time_offset_length
=
24
;
sps
->
profile_idc
=
profile_idc
;
sps
->
profile_idc
=
profile_idc
;
sps
->
constraint_set_flags
=
constraint_set_flags
;
sps
->
constraint_set_flags
=
constraint_set_flags
;
...
@@ -504,7 +505,6 @@ int ff_h264_decode_seq_parameter_set(H264Context *h)
...
@@ -504,7 +505,6 @@ int ff_h264_decode_seq_parameter_set(H264Context *h)
av_free
(
h
->
sps_buffers
[
sps_id
]);
av_free
(
h
->
sps_buffers
[
sps_id
]);
h
->
sps_buffers
[
sps_id
]
=
sps
;
h
->
sps_buffers
[
sps_id
]
=
sps
;
h
->
sps
=
*
sps
;
h
->
sps
=
*
sps
;
h
->
current_sps_id
=
sps_id
;
return
0
;
return
0
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录