mirror of
https://github.com/k4yt3x/video2x.git
synced 2026-02-04 03:22:07 +08:00
feat(libplacebo): added Vulkan device selection for libplacebo
Signed-off-by: k4yt3x <i@k4yt3x.com>
This commit is contained in:
@@ -9,13 +9,13 @@ extern "C" {
|
||||
}
|
||||
|
||||
int init_libplacebo(
|
||||
AVBufferRef *hw_ctx,
|
||||
AVFilterGraph **filter_graph,
|
||||
AVFilterContext **buffersrc_ctx,
|
||||
AVFilterContext **buffersink_ctx,
|
||||
AVCodecContext *dec_ctx,
|
||||
int out_width,
|
||||
int out_height,
|
||||
uint32_t vk_device_index,
|
||||
const std::filesystem::path &shader_path
|
||||
);
|
||||
|
||||
|
||||
@@ -17,15 +17,21 @@ class LibplaceboFilter : public Filter {
|
||||
AVFilterGraph *filter_graph;
|
||||
AVFilterContext *buffersrc_ctx;
|
||||
AVFilterContext *buffersink_ctx;
|
||||
uint32_t vk_device_index;
|
||||
const std::filesystem::path shader_path;
|
||||
int out_width;
|
||||
int out_height;
|
||||
const std::filesystem::path shader_path;
|
||||
AVRational in_time_base;
|
||||
AVRational out_time_base;
|
||||
|
||||
public:
|
||||
// Constructor
|
||||
LibplaceboFilter(int width, int height, const std::filesystem::path &shader_path);
|
||||
LibplaceboFilter(
|
||||
uint32_t vk_device_index,
|
||||
const std::filesystem::path &shader_path,
|
||||
int width,
|
||||
int height
|
||||
);
|
||||
|
||||
// Destructor
|
||||
virtual ~LibplaceboFilter() override;
|
||||
|
||||
Reference in New Issue
Block a user