38 lines
705 B
Markdown
38 lines
705 B
Markdown
# ShaderLoader::GetSupportedExtensions
|
|
|
|
## 方法签名
|
|
|
|
```cpp
|
|
Containers::Array<Containers::String> GetSupportedExtensions() const override;
|
|
```
|
|
|
|
## 详细描述
|
|
|
|
返回该加载器支持的文件扩展名列表。支持以下扩展名:
|
|
|
|
- `vert` - 顶点着色器
|
|
- `frag` - 片段着色器
|
|
- `geom` - 几何着色器
|
|
- `comp` - 计算着色器
|
|
- `glsl` - 通用 GLSL 着色器
|
|
- `hlsl` - HLSL 着色器
|
|
- `shader` - 通用着色器
|
|
|
|
## 参数
|
|
|
|
无
|
|
|
|
## 返回值
|
|
|
|
`Containers::Array<Containers::String>` - 支持的文件扩展名数组
|
|
|
|
## 示例
|
|
|
|
```cpp
|
|
ShaderLoader loader;
|
|
auto extensions = loader.GetSupportedExtensions();
|
|
for (const auto& ext : extensions) {
|
|
// 处理每个扩展名
|
|
}
|
|
```
|