| 767 | } |
| 768 | |
| 769 | reshade::api::effect_technique reshade::runtime::find_technique(const char *effect_name_in, const char *technique_name_in) |
| 770 | { |
| 771 | if (is_loading() || technique_name_in == nullptr) |
| 772 | return { 0 }; |
| 773 | |
| 774 | const std::filesystem::path effect_name = effect_name_in != nullptr ? std::filesystem::u8path(effect_name_in) : std::filesystem::path(); |
| 775 | const std::string_view technique_name(technique_name_in); |
| 776 | |
| 777 | for (const technique &technique : _techniques) |
| 778 | { |
| 779 | if (effect_name_in != nullptr && _effects[technique.effect_index].source_file.filename() != effect_name) |
| 780 | continue; |
| 781 | |
| 782 | if (technique.name != technique_name) |
| 783 | continue; |
| 784 | |
| 785 | return { reinterpret_cast<uintptr_t>(&technique) }; |
| 786 | } |
| 787 | |
| 788 | return { 0 }; |
| 789 | } |
| 790 | |
| 791 | void reshade::runtime::get_technique_name(api::effect_technique handle, char *value, size_t *size) const |
| 792 | { |
no test coverage detected