mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-11-26 21:30:07 +00:00
Make spvParseTargetEnv public (#2362)
This CL moves the method to parse the SPIRV environment into the public headers. This will allow other applications to re-use the same parsing logic.
This commit is contained in:
parent
cf21146137
commit
39bfb6b978
@ -445,6 +445,10 @@ typedef enum {
|
|||||||
// Returns a string describing the given SPIR-V target environment.
|
// Returns a string describing the given SPIR-V target environment.
|
||||||
SPIRV_TOOLS_EXPORT const char* spvTargetEnvDescription(spv_target_env env);
|
SPIRV_TOOLS_EXPORT const char* spvTargetEnvDescription(spv_target_env env);
|
||||||
|
|
||||||
|
// Parses s into *env and returns true if successful. If unparsable, returns
|
||||||
|
// false and sets *env to SPV_ENV_UNIVERSAL_1_0.
|
||||||
|
SPIRV_TOOLS_EXPORT bool spvParseTargetEnv(const char* s, spv_target_env* env);
|
||||||
|
|
||||||
// Creates a context object. Returns null if env is invalid.
|
// Creates a context object. Returns null if env is invalid.
|
||||||
SPIRV_TOOLS_EXPORT spv_context spvContextCreate(spv_target_env env);
|
SPIRV_TOOLS_EXPORT spv_context spvContextCreate(spv_target_env env);
|
||||||
|
|
||||||
|
@ -19,10 +19,6 @@
|
|||||||
|
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
|
|
||||||
// Parses s into *env and returns true if successful. If unparsable, returns
|
|
||||||
// false and sets *env to SPV_ENV_UNIVERSAL_1_0.
|
|
||||||
bool spvParseTargetEnv(const char* s, spv_target_env* env);
|
|
||||||
|
|
||||||
// Returns true if |env| is a VULKAN environment, false otherwise.
|
// Returns true if |env| is a VULKAN environment, false otherwise.
|
||||||
bool spvIsVulkanEnv(spv_target_env env);
|
bool spvIsVulkanEnv(spv_target_env env);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user