From e1b7e6eaf2e9247fabee716ad7a1f494280ed1b6 Mon Sep 17 00:00:00 2001 From: Michael Fabian 'Xaymar' Dirks Date: Thu, 25 Nov 2021 21:07:56 +0100 Subject: [PATCH] gfx/shader: Get-er for currently loaded shader file --- source/gfx/shader/gfx-shader.cpp | 5 +++++ source/gfx/shader/gfx-shader.hpp | 2 ++ 2 files changed, 7 insertions(+) diff --git a/source/gfx/shader/gfx-shader.cpp b/source/gfx/shader/gfx-shader.cpp index cfb85d85..3a602dc2 100644 --- a/source/gfx/shader/gfx-shader.cpp +++ b/source/gfx/shader/gfx-shader.cpp @@ -620,3 +620,8 @@ obs_source_t* streamfx::gfx::shader::shader::get() { return _self; } + +std::filesystem::path streamfx::gfx::shader::shader::get_shader_file() +{ + return _shader_file; +} diff --git a/source/gfx/shader/gfx-shader.hpp b/source/gfx/shader/gfx-shader.hpp index f47d8de5..73ce05b3 100644 --- a/source/gfx/shader/gfx-shader.hpp +++ b/source/gfx/shader/gfx-shader.hpp @@ -117,6 +117,8 @@ namespace streamfx::gfx { obs_source_t* get(); + std::filesystem::path get_shader_file(); + public: void set_size(uint32_t w, uint32_t h);