Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
F
ffmpeg
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ffmpeg
Commits
1a5e9ae4
Commit
1a5e9ae4
authored
Mar 15, 2020
by
Lynne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
scale_vulkan: add support for RGB->YUV conversions
Only top-left chroma position supported for now.
parent
ecc3dcef
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
0 deletions
+17
-0
vf_scale_vulkan.c
libavfilter/vf_scale_vulkan.c
+0
-0
vulkan.c
libavfilter/vulkan.c
+12
-0
vulkan.h
libavfilter/vulkan.h
+5
-0
No files found.
libavfilter/vf_scale_vulkan.c
View file @
1a5e9ae4
This diff is collapsed.
Click to expand it.
libavfilter/vulkan.c
View file @
1a5e9ae4
...
...
@@ -666,6 +666,18 @@ VkSampler *ff_vk_init_sampler(AVFilterContext *avctx, int unnorm_coords,
return
sampler
;
}
int
ff_vk_mt_is_np_rgb
(
enum
AVPixelFormat
pix_fmt
)
{
if
(
pix_fmt
==
AV_PIX_FMT_ABGR
||
pix_fmt
==
AV_PIX_FMT_BGRA
||
pix_fmt
==
AV_PIX_FMT_RGBA
||
pix_fmt
==
AV_PIX_FMT_RGB24
||
pix_fmt
==
AV_PIX_FMT_BGR24
||
pix_fmt
==
AV_PIX_FMT_RGB48
||
pix_fmt
==
AV_PIX_FMT_RGBA64
||
pix_fmt
==
AV_PIX_FMT_RGB565
||
pix_fmt
==
AV_PIX_FMT_BGR565
||
pix_fmt
==
AV_PIX_FMT_BGR0
||
pix_fmt
==
AV_PIX_FMT_0BGR
||
pix_fmt
==
AV_PIX_FMT_RGB0
)
return
1
;
return
0
;
}
const
char
*
ff_vk_shader_rep_fmt
(
enum
AVPixelFormat
pixfmt
)
{
const
AVPixFmtDescriptor
*
desc
=
av_pix_fmt_desc_get
(
pixfmt
);
...
...
libavfilter/vulkan.h
View file @
1a5e9ae4
...
...
@@ -174,6 +174,11 @@ void ff_vk_filter_uninit (AVFilterContext *avctx);
*/
const
char
*
ff_vk_ret2str
(
VkResult
res
);
/**
* Returns 1 if the image is any sort of supported RGB
*/
int
ff_vk_mt_is_np_rgb
(
enum
AVPixelFormat
pix_fmt
);
/**
* Gets the glsl format string for a pixel format
*/
...
...
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