Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
82eba226
Commit
82eba226
authored
Oct 12, 2012
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavd: do not use av_pix_fmt_descriptors directly
Signed-off-by:
Paul B Mahol
<
onemda@gmail.com
>
parent
0d002de4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
4 deletions
+7
-4
caca.c
libavdevice/caca.c
+1
-1
lavfi.c
libavdevice/lavfi.c
+6
-3
No files found.
libavdevice/caca.c
View file @
82eba226
...
@@ -140,7 +140,7 @@ static int caca_write_header(AVFormatContext *s)
...
@@ -140,7 +140,7 @@ static int caca_write_header(AVFormatContext *s)
goto
fail
;
goto
fail
;
}
}
bpp
=
av_get_bits_per_pixel
(
&
av_pix_fmt_descriptors
[
encctx
->
pix_fmt
]
);
bpp
=
av_get_bits_per_pixel
(
av_pix_fmt_desc_get
(
avctx
->
pix_fmt
)
);
c
->
dither
=
caca_create_dither
(
bpp
,
encctx
->
width
,
encctx
->
height
,
c
->
dither
=
caca_create_dither
(
bpp
,
encctx
->
width
,
encctx
->
height
,
bpp
/
8
*
encctx
->
width
,
bpp
/
8
*
encctx
->
width
,
0x0000ff
,
0x00ff00
,
0xff0000
,
0
);
0x0000ff
,
0x00ff00
,
0xff0000
,
0
);
...
...
libavdevice/lavfi.c
View file @
82eba226
...
@@ -54,14 +54,17 @@ static int *create_all_formats(int n)
...
@@ -54,14 +54,17 @@ static int *create_all_formats(int n)
{
{
int
i
,
j
,
*
fmts
,
count
=
0
;
int
i
,
j
,
*
fmts
,
count
=
0
;
for
(
i
=
0
;
i
<
n
;
i
++
)
for
(
i
=
0
;
i
<
n
;
i
++
)
{
if
(
!
(
av_pix_fmt_descriptors
[
i
].
flags
&
PIX_FMT_HWACCEL
))
const
AVPixFmtDescriptor
*
desc
=
av_pix_fmt_desc_get
(
i
);
if
(
!
(
desc
->
flags
&
PIX_FMT_HWACCEL
))
count
++
;
count
++
;
}
if
(
!
(
fmts
=
av_malloc
((
count
+
1
)
*
sizeof
(
int
))))
if
(
!
(
fmts
=
av_malloc
((
count
+
1
)
*
sizeof
(
int
))))
return
NULL
;
return
NULL
;
for
(
j
=
0
,
i
=
0
;
i
<
n
;
i
++
)
{
for
(
j
=
0
,
i
=
0
;
i
<
n
;
i
++
)
{
if
(
!
(
av_pix_fmt_descriptors
[
i
].
flags
&
PIX_FMT_HWACCEL
))
const
AVPixFmtDescriptor
*
desc
=
av_pix_fmt_desc_get
(
i
);
if
(
!
(
desc
->
flags
&
PIX_FMT_HWACCEL
))
fmts
[
j
++
]
=
i
;
fmts
[
j
++
]
=
i
;
}
}
fmts
[
j
]
=
-
1
;
fmts
[
j
]
=
-
1
;
...
...
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