Toggle navigation
Toggle navigation
此项目
正在载入...
Sign in
胡斌
/
merge_av
转到一个项目
Toggle navigation
项目
群组
代码片段
帮助
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
胡斌
2019-12-27 16:48:59 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
1b4fc6901f7d3e7aaba116f9660eccf9568f6c0a
1b4fc690
1 parent
0fa98ff8
V2.0.12
1.在一对一时,强制老师和学生的视频大小一致,且宽高比均为4:3,当不为4:3时,保持视频原始宽高比,水平或垂直居中
隐藏空白字符变更
内嵌
并排对比
正在显示
4 个修改的文件
包含
13 行增加
和
5 行删除
pip/AVTranscoder.cpp
pip/AVTranscoder.h
pip/ReadMe.txt
pip/merge_pip.cpp
pip/AVTranscoder.cpp
查看文件 @
1b4fc69
...
...
@@ -34,7 +34,7 @@ int g_fps;
#define ensure_no_zero(x, v) if(!x) x = v
CAVTranscoder
::
CAVTranscoder
(
bool
bOne2One
,
bool
one2one_same_size
,
bool
one2many_inflat
,
int
width_teacher
,
int
height_teacher
,
int
width_student
,
int
height_student
,
bool
has_teacher
,
int
max_audio
)
:
CAVTranscoder
::
CAVTranscoder
(
bool
bOne2One
,
bool
one2one_same_size
,
bool
one2many_inflat
,
int
width_teacher
,
int
height_teacher
,
int
width_student
,
int
height_student
,
bool
has_teacher
,
int
max_audio
,
int
keep_4_3
)
:
_start_time
(
INT64_MAX
),
_all_processed
(
true
),
_nOutputWidth
(
320
),
...
...
@@ -90,7 +90,12 @@ _one2one_same_size(one2one_same_size)
double
max_ratio
=
max
(
wh_ratio_teacher
,
wh_ratio_student
);
_teacher_width
=
_student_width
=
max_width
;
_teacher_height
=
_student_height
=
(
int
)(
max_width
/
max_ratio
+
0.5
);
if
(
keep_4_3
){
_teacher_height
=
_student_height
=
_teacher_width
*
3
/
4
;
}
else
{
_teacher_height
=
_student_height
=
(
int
)(
max_width
/
max_ratio
+
0.5
);
}
}
_nOutputHeight
=
_teacher_height
+
_student_height
;
...
...
pip/AVTranscoder.h
查看文件 @
1b4fc69
...
...
@@ -5,7 +5,7 @@
class
CAVTranscoder
{
public
:
CAVTranscoder
(
bool
bOne2One
,
bool
one2one_same_size
,
bool
one2many_inflat
,
int
width_teacher
,
int
height_teacher
,
int
student_width
,
int
student_height
,
bool
has_teacher
,
int
max_audio
);
CAVTranscoder
(
bool
bOne2One
,
bool
one2one_same_size
,
bool
one2many_inflat
,
int
width_teacher
,
int
height_teacher
,
int
student_width
,
int
student_height
,
bool
has_teacher
,
int
max_audio
,
int
keep_4_3
=
true
);
virtual
~
CAVTranscoder
();
int
add
(
media_info
&
info
);
...
...
pip/ReadMe.txt
查看文件 @
1b4fc69
...
...
@@ -98,4 +98,7 @@ V2.0.10
2.一对多布局时,支持对不同分辨率的老师视频进行缩放,统一到相同分辨率
V2.0.11
1.修改1对多布局时,缺省不扩大合成视频大小,-t 3参数时才根据学生数量扩大合成视频大小
\ No newline at end of file
1.修改1对多布局时,缺省不扩大合成视频大小,-t 3参数时才根据学生数量扩大合成视频大小
V2.0.12
1.在一对一时,强制老师和学生的视频大小一致,且宽高比均为4:3,当不为4:3时,保持视频原始宽高比,水平或垂直居中
\ No newline at end of file
...
...
pip/merge_pip.cpp
查看文件 @
1b4fc69
...
...
@@ -1223,7 +1223,7 @@ int process_av_files(char * record_info, int piptype, bool one2one_same_size, in
int
main
(
int
argc
,
char
*
argv
[])
{
if
(
argc
<
2
)
{
printf
(
" merge_pip 2.0.1
1
\n
"
);
printf
(
" merge_pip 2.0.1
2
\n
"
);
printf
(
" merge video files to one pip video according to record info file,
\n
usage:"
);
printf
(
"
\n
%s record_info_filename [-t {0,1,2,3}] [-c codec.cfg] [-s {1,0}]"
,
argv
[
0
]);
printf
(
"
\n\n
"
);
...
...
请
注册
或
登录
后发表评论