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
1ec7a703
Commit
1ec7a703
authored
Feb 22, 2016
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avutil/pixdesc: Make get_color_type() aware of CIE XYZ formats
Signed-off-by:
Michael Niedermayer
<
michael@niedermayer.cc
>
parent
67f8a0be
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
pixdesc.c
libavutil/pixdesc.c
+4
-0
No files found.
libavutil/pixdesc.c
View file @
1ec7a703
...
...
@@ -2273,6 +2273,7 @@ enum AVPixelFormat av_pix_fmt_swap_endianness(enum AVPixelFormat pix_fmt)
#define FF_COLOR_GRAY 1
/**< gray color space */
#define FF_COLOR_YUV 2
/**< YUV color space. 16 <= Y <= 235, 16 <= U, V <= 240 */
#define FF_COLOR_YUV_JPEG 3
/**< YUV color space. 0 <= Y <= 255, 0 <= U, V <= 255 */
#define FF_COLOR_XYZ 4
#define pixdesc_has_alpha(pixdesc) \
((pixdesc)->nb_components == 2 || (pixdesc)->nb_components == 4 || (pixdesc)->flags & AV_PIX_FMT_FLAG_PAL)
...
...
@@ -2288,6 +2289,9 @@ static int get_color_type(const AVPixFmtDescriptor *desc) {
if
(
desc
->
name
&&
!
strncmp
(
desc
->
name
,
"yuvj"
,
4
))
return
FF_COLOR_YUV_JPEG
;
if
(
desc
->
name
&&
!
strncmp
(
desc
->
name
,
"xyz"
,
3
))
return
FF_COLOR_XYZ
;
if
(
desc
->
flags
&
AV_PIX_FMT_FLAG_RGB
)
return
FF_COLOR_RGB
;
...
...
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