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
9bd6ea56
Commit
9bd6ea56
authored
Sep 24, 2016
by
Luca Barbato
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pixfmt: Add yuv444p12 pixel format
parent
0aebbbd0
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
44 additions
and
1 deletion
+44
-1
pixdesc.c
libavutil/pixdesc.c
+25
-0
pixfmt.h
libavutil/pixfmt.h
+4
-0
swscale_unscaled.c
libswscale/swscale_unscaled.c
+3
-1
utils.c
libswscale/utils.c
+2
-0
filter-pixdesc-yuv444p12be
tests/ref/fate/filter-pixdesc-yuv444p12be
+1
-0
filter-pixdesc-yuv444p12le
tests/ref/fate/filter-pixdesc-yuv444p12le
+1
-0
filter-pixfmts-copy
tests/ref/fate/filter-pixfmts-copy
+2
-0
filter-pixfmts-null
tests/ref/fate/filter-pixfmts-null
+2
-0
filter-pixfmts-scale
tests/ref/fate/filter-pixfmts-scale
+2
-0
filter-pixfmts-vflip
tests/ref/fate/filter-pixfmts-vflip
+2
-0
No files found.
libavutil/pixdesc.c
View file @
9bd6ea56
...
...
@@ -1342,6 +1342,30 @@ static const AVPixFmtDescriptor av_pix_fmt_descriptors[AV_PIX_FMT_NB] = {
},
.
flags
=
AV_PIX_FMT_FLAG_BE
|
AV_PIX_FMT_FLAG_PLANAR
,
},
[
AV_PIX_FMT_YUV444P12LE
]
=
{
.
name
=
"yuv444p12le"
,
.
nb_components
=
3
,
.
log2_chroma_w
=
0
,
.
log2_chroma_h
=
0
,
.
comp
=
{
{
0
,
2
,
0
,
0
,
12
,
1
,
11
,
1
},
/* Y */
{
1
,
2
,
0
,
0
,
12
,
1
,
11
,
1
},
/* U */
{
2
,
2
,
0
,
0
,
12
,
1
,
11
,
1
},
/* V */
},
.
flags
=
AV_PIX_FMT_FLAG_PLANAR
,
},
[
AV_PIX_FMT_YUV444P12BE
]
=
{
.
name
=
"yuv444p12be"
,
.
nb_components
=
3
,
.
log2_chroma_w
=
0
,
.
log2_chroma_h
=
0
,
.
comp
=
{
{
0
,
2
,
0
,
0
,
12
,
1
,
11
,
1
},
/* Y */
{
1
,
2
,
0
,
0
,
12
,
1
,
11
,
1
},
/* U */
{
2
,
2
,
0
,
0
,
12
,
1
,
11
,
1
},
/* V */
},
.
flags
=
AV_PIX_FMT_FLAG_BE
|
AV_PIX_FMT_FLAG_PLANAR
,
},
[
AV_PIX_FMT_YUV444P10LE
]
=
{
.
name
=
"yuv444p10le"
,
.
nb_components
=
3
,
...
...
@@ -1892,6 +1916,7 @@ enum AVPixelFormat av_pix_fmt_swap_endianness(enum AVPixelFormat pix_fmt)
PIX_FMT_SWAP_ENDIANNESS
(
YUV444P10
);
PIX_FMT_SWAP_ENDIANNESS
(
YUV420P12
);
PIX_FMT_SWAP_ENDIANNESS
(
YUV422P12
);
PIX_FMT_SWAP_ENDIANNESS
(
YUV444P12
);
PIX_FMT_SWAP_ENDIANNESS
(
YUV420P16
);
PIX_FMT_SWAP_ENDIANNESS
(
YUV422P16
);
PIX_FMT_SWAP_ENDIANNESS
(
YUV444P16
);
...
...
libavutil/pixfmt.h
View file @
9bd6ea56
...
...
@@ -236,6 +236,9 @@ enum AVPixelFormat {
AV_PIX_FMT_YUV422P12BE
,
///< planar YUV 4:2:2, 24bpp, (1 Cr & Cb sample per 2x1 Y samples), big-endian
AV_PIX_FMT_YUV422P12LE
,
///< planar YUV 4:2:2, 24bpp, (1 Cr & Cb sample per 2x1 Y samples), little-endian
AV_PIX_FMT_YUV444P12BE
,
///< planar YUV 4:4:4, 36bpp, (1 Cr & Cb sample per 1x1 Y), big-endian
AV_PIX_FMT_YUV444P12LE
,
///< planar YUV 4:4:4, 36bpp, (1 Cr & Cb sample per 1x1 Y), little-endian
AV_PIX_FMT_NB
,
///< number of pixel formats, DO NOT USE THIS if you want to link with shared libav* because the number of formats might differ between versions
};
...
...
@@ -271,6 +274,7 @@ enum AVPixelFormat {
#define AV_PIX_FMT_YUV444P10 AV_PIX_FMT_NE(YUV444P10BE, YUV444P10LE)
#define AV_PIX_FMT_YUV420P12 AV_PIX_FMT_NE(YUV420P12BE, YUV420P12LE)
#define AV_PIX_FMT_YUV422P12 AV_PIX_FMT_NE(YUV422P12BE, YUV422P12LE)
#define AV_PIX_FMT_YUV444P12 AV_PIX_FMT_NE(YUV444P12BE, YUV444P12LE)
#define AV_PIX_FMT_YUV420P16 AV_PIX_FMT_NE(YUV420P16BE, YUV420P16LE)
#define AV_PIX_FMT_YUV422P16 AV_PIX_FMT_NE(YUV422P16BE, YUV422P16LE)
#define AV_PIX_FMT_YUV444P16 AV_PIX_FMT_NE(YUV444P16BE, YUV444P16LE)
...
...
libswscale/swscale_unscaled.c
View file @
9bd6ea56
...
...
@@ -1159,10 +1159,12 @@ void ff_get_unscaled_swscale(SwsContext *c)
dstFormat
!=
AV_PIX_FMT_P010LE
&&
dstFormat
!=
AV_PIX_FMT_P010BE
&&
dstFormat
!=
AV_PIX_FMT_YUV420P12LE
&&
dstFormat
!=
AV_PIX_FMT_YUV420P12BE
&&
dstFormat
!=
AV_PIX_FMT_YUV422P12LE
&&
dstFormat
!=
AV_PIX_FMT_YUV422P12BE
&&
dstFormat
!=
AV_PIX_FMT_YUV444P12LE
&&
dstFormat
!=
AV_PIX_FMT_YUV444P12BE
&&
srcFormat
!=
AV_PIX_FMT_NV12
&&
srcFormat
!=
AV_PIX_FMT_NV21
&&
srcFormat
!=
AV_PIX_FMT_P010LE
&&
srcFormat
!=
AV_PIX_FMT_P010BE
&&
srcFormat
!=
AV_PIX_FMT_YUV420P12LE
&&
srcFormat
!=
AV_PIX_FMT_YUV420P12BE
&&
srcFormat
!=
AV_PIX_FMT_YUV422P12LE
&&
srcFormat
!=
AV_PIX_FMT_YUV422P12BE
))
srcFormat
!=
AV_PIX_FMT_YUV422P12LE
&&
srcFormat
!=
AV_PIX_FMT_YUV422P12BE
&&
srcFormat
!=
AV_PIX_FMT_YUV444P12LE
&&
srcFormat
!=
AV_PIX_FMT_YUV444P12BE
))
{
if
(
isPacked
(
c
->
srcFormat
))
c
->
swscale
=
packedCopyWrapper
;
...
...
libswscale/utils.c
View file @
9bd6ea56
...
...
@@ -177,6 +177,8 @@ static const FormatEntry format_entries[AV_PIX_FMT_NB] = {
[
AV_PIX_FMT_YUV444P9LE
]
=
{
1
,
1
},
[
AV_PIX_FMT_YUV444P10BE
]
=
{
1
,
1
},
[
AV_PIX_FMT_YUV444P10LE
]
=
{
1
,
1
},
[
AV_PIX_FMT_YUV444P12BE
]
=
{
1
,
1
},
[
AV_PIX_FMT_YUV444P12LE
]
=
{
1
,
1
},
[
AV_PIX_FMT_GBRP
]
=
{
1
,
1
},
[
AV_PIX_FMT_GBRP9LE
]
=
{
1
,
1
},
[
AV_PIX_FMT_GBRP9BE
]
=
{
1
,
1
},
...
...
tests/ref/fate/filter-pixdesc-yuv444p12be
0 → 100644
View file @
9bd6ea56
pixdesc-yuv444p12be f20564006d137df0fc6bb7466fd0fc64
tests/ref/fate/filter-pixdesc-yuv444p12le
0 → 100644
View file @
9bd6ea56
pixdesc-yuv444p12le 9d5db1a9354b62181e09aa93c1ffa19a
tests/ref/fate/filter-pixfmts-copy
View file @
9bd6ea56
...
...
@@ -62,6 +62,8 @@ yuv440p 12000ce709b38aac3f7b7f59b07847ef
yuv444p 628c9d1e10c22e0e512b27c0e03b46e6
yuv444p10be b60d77db54a592ed088ebf7964e2dd5e
yuv444p10le 1752a238eb27fb7c746e349536f60686
yuv444p12be be54f88f9b9034b5b9bc466132bfba10
yuv444p12le 714c3c5789897b56cb9ae6a45688e395
yuv444p16be 8e1e2f04cb2e97f80fdfecbb2c5679a0
yuv444p16le 5677b2caa63e0c075eac6937b03cf2a6
yuv444p9be 5ab55576b180b2966e9ed5a1ea55508a
...
...
tests/ref/fate/filter-pixfmts-null
View file @
9bd6ea56
...
...
@@ -62,6 +62,8 @@ yuv440p 12000ce709b38aac3f7b7f59b07847ef
yuv444p 628c9d1e10c22e0e512b27c0e03b46e6
yuv444p10be b60d77db54a592ed088ebf7964e2dd5e
yuv444p10le 1752a238eb27fb7c746e349536f60686
yuv444p12be be54f88f9b9034b5b9bc466132bfba10
yuv444p12le 714c3c5789897b56cb9ae6a45688e395
yuv444p16be 8e1e2f04cb2e97f80fdfecbb2c5679a0
yuv444p16le 5677b2caa63e0c075eac6937b03cf2a6
yuv444p9be 5ab55576b180b2966e9ed5a1ea55508a
...
...
tests/ref/fate/filter-pixfmts-scale
View file @
9bd6ea56
...
...
@@ -62,6 +62,8 @@ yuv440p 4713a7b7ce80dd06923626d13589c098
yuv444p fd733672651ad5bbffb046fd67151fee
yuv444p10be 34b38d54167df70044bdc08518d91009
yuv444p10le 0812e3371c9589c6621408812f9e7a27
yuv444p12be 936147950ba1b511570da85a0922abf3
yuv444p12le 4a9ec677190371ef5e342ffac1ace735
yuv444p16be e89fe5a4624ed06603580b4a74af9170
yuv444p16le 6944d11048ff4013c5e60359faf1bd2d
yuv444p9be 04a950e843d099eb9ade2ddcea494fb3
...
...
tests/ref/fate/filter-pixfmts-vflip
View file @
9bd6ea56
...
...
@@ -62,6 +62,8 @@ yuv440p fade395d957e1e3b117ac11c09404964
yuv444p a3c2a074c3609226bf1a0bc4de5c0e51
yuv444p10be b02fac8bc5a564a755567a86dc3ceae0
yuv444p10le 88860297f729c90526b157b6bf1e2fcf
yuv444p12be d8af56e4b09130e14a9449c84a03cab0
yuv444p12le 0ccfbd671b8000c0f950b9dfae8ea879
yuv444p16be 26fbffad3c28aa1a6c47f2be6d146173
yuv444p16le 3d13dcea82caec9eb563a1d7a2e4b339
yuv444p9be df39c0778e5b13f306e9928c5b0ddbb2
...
...
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