fn capability_name(cap: &enums::Capability) -> Option<&'static str> {
    match *cap {
        enums::Capability::CapabilityMatrix => None,        // always supported
        enums::Capability::CapabilityShader => None,        // always supported
        enums::Capability::CapabilityGeometry => Some("geometry_shader"),
        enums::Capability::CapabilityTessellation => Some("tessellation_shader"),
        enums::Capability::CapabilityAddresses => panic!(), // not supported
        enums::Capability::CapabilityLinkage => panic!(),   // not supported
        enums::Capability::CapabilityKernel => panic!(),    // not supported
        enums::Capability::CapabilityVector16 => panic!(),  // not supported
        enums::Capability::CapabilityFloat16Buffer => panic!(), // not supported
        enums::Capability::CapabilityFloat16 => panic!(),   // not supported
        enums::Capability::CapabilityFloat64 => Some("shader_f3264"),
        enums::Capability::CapabilityInt64 => Some("shader_int64"),
        enums::Capability::CapabilityInt64Atomics => panic!(),  // not supported
        enums::Capability::CapabilityImageBasic => panic!(),    // not supported
        enums::Capability::CapabilityImageReadWrite => panic!(),    // not supported
        enums::Capability::CapabilityImageMipmap => panic!(),   // not supported
        enums::Capability::CapabilityPipes => panic!(), // not supported
        enums::Capability::CapabilityGroups => panic!(),    // not supported
        enums::Capability::CapabilityDeviceEnqueue => panic!(), // not supported
        enums::Capability::CapabilityLiteralSampler => panic!(),    // not supported
        enums::Capability::CapabilityAtomicStorage => panic!(), // not supported
        enums::Capability::CapabilityInt16 => Some("shader_int16"),
        enums::Capability::CapabilityTessellationPointSize =>
            Some("shader_tessellation_and_geometry_point_size"),
        enums::Capability::CapabilityGeometryPointSize =>
            Some("shader_tessellation_and_geometry_point_size"),
        enums::Capability::CapabilityImageGatherExtended => Some("shader_image_gather_extended"),
        enums::Capability::CapabilityStorageImageMultisample =>
            Some("shader_storage_image_multisample"),
        enums::Capability::CapabilityUniformBufferArrayDynamicIndexing =>
            Some("shader_uniform_buffer_array_dynamic_indexing"),
        enums::Capability::CapabilitySampledImageArrayDynamicIndexing =>
            Some("shader_sampled_image_array_dynamic_indexing"),
        enums::Capability::CapabilityStorageBufferArrayDynamicIndexing =>
            Some("shader_storage_buffer_array_dynamic_indexing"),
        enums::Capability::CapabilityStorageImageArrayDynamicIndexing =>
            Some("shader_storage_image_array_dynamic_indexing"),
        enums::Capability::CapabilityClipDistance => Some("shader_clip_distance"),
        enums::Capability::CapabilityCullDistance => Some("shader_cull_distance"),
        enums::Capability::CapabilityImageCubeArray => Some("image_cube_array"),
        enums::Capability::CapabilitySampleRateShading => Some("sample_rate_shading"),
        enums::Capability::CapabilityImageRect => panic!(), // not supported
        enums::Capability::CapabilitySampledRect => panic!(),   // not supported
        enums::Capability::CapabilityGenericPointer => panic!(),    // not supported
        enums::Capability::CapabilityInt8 => panic!(),  // not supported
        enums::Capability::CapabilityInputAttachment => None,       // always supported
        enums::Capability::CapabilitySparseResidency => Some("shader_resource_residency"),
        enums::Capability::CapabilityMinLod => Some("shader_resource_min_lod"),
        enums::Capability::CapabilitySampled1D => None,        // always supported
        enums::Capability::CapabilityImage1D => None,        // always supported
        enums::Capability::CapabilitySampledCubeArray => Some("image_cube_array"),
        enums::Capability::CapabilitySampledBuffer => None,         // always supported
        enums::Capability::CapabilityImageBuffer => None,        // always supported
        enums::Capability::CapabilityImageMSArray => Some("shader_storage_image_multisample"),
        enums::Capability::CapabilityStorageImageExtendedFormats =>
            Some("shader_storage_image_extended_formats"),
        enums::Capability::CapabilityImageQuery => None,        // always supported
        enums::Capability::CapabilityDerivativeControl => None,        // always supported
        enums::Capability::CapabilityInterpolationFunction => Some("sample_rate_shading"),
        enums::Capability::CapabilityTransformFeedback => panic!(), // not supported
        enums::Capability::CapabilityGeometryStreams => panic!(),   // not supported
        enums::Capability::CapabilityStorageImageReadWithoutFormat =>
            Some("shader_storage_image_read_without_format"),
        enums::Capability::CapabilityStorageImageWriteWithoutFormat =>
            Some("shader_storage_image_write_without_format"),
        enums::Capability::CapabilityMultiViewport => Some("multi_viewport"),
    }
}
/// Returns the name of the Vulkan something that corresponds to an `OpCapability`.
///
/// Returns `None` if irrelevant.
// TODO: this function is a draft, as the actual names may not be the same
Returns the name of the Vulkan something that corresponds to an `OpCapability`.
Returns `None` if irrelevant.
TODO: this function is a draft, as the actual names may not be the same
Returns the name of the Vulkan something that corresponds to an ` OpCapability ` . Returns ` None ` if irrelevant . TODO : this function is a draft as the actual names may not be the same
fn capability_name(cap: &enums::Capability) -> Option<&'static str> {
    match *cap {
        enums::Capability::CapabilityMatrix => None,        // always supported
        enums::Capability::CapabilityShader => None,        // always supported
        enums::Capability::CapabilityGeometry => Some("geometry_shader"),
        enums::Capability::CapabilityTessellation => Some("tessellation_shader"),
        enums::Capability::CapabilityAddresses => panic!(), // not supported
        enums::Capability::CapabilityLinkage => panic!(),   // not supported
        enums::Capability::CapabilityKernel => panic!(),    // not supported
        enums::Capability::CapabilityVector16 => panic!(),  // not supported
        enums::Capability::CapabilityFloat16Buffer => panic!(), // not supported
        enums::Capability::CapabilityFloat16 => panic!(),   // not supported
        enums::Capability::CapabilityFloat64 => Some("shader_f3264"),
        enums::Capability::CapabilityInt64 => Some("shader_int64"),
        enums::Capability::CapabilityInt64Atomics => panic!(),  // not supported
        enums::Capability::CapabilityImageBasic => panic!(),    // not supported
        enums::Capability::CapabilityImageReadWrite => panic!(),    // not supported
        enums::Capability::CapabilityImageMipmap => panic!(),   // not supported
        enums::Capability::CapabilityPipes => panic!(), // not supported
        enums::Capability::CapabilityGroups => panic!(),    // not supported
        enums::Capability::CapabilityDeviceEnqueue => panic!(), // not supported
        enums::Capability::CapabilityLiteralSampler => panic!(),    // not supported
        enums::Capability::CapabilityAtomicStorage => panic!(), // not supported
        enums::Capability::CapabilityInt16 => Some("shader_int16"),
        enums::Capability::CapabilityTessellationPointSize =>
            Some("shader_tessellation_and_geometry_point_size"),
        enums::Capability::CapabilityGeometryPointSize =>
            Some("shader_tessellation_and_geometry_point_size"),
        enums::Capability::CapabilityImageGatherExtended => Some("shader_image_gather_extended"),
        enums::Capability::CapabilityStorageImageMultisample =>
            Some("shader_storage_image_multisample"),
        enums::Capability::CapabilityUniformBufferArrayDynamicIndexing =>
            Some("shader_uniform_buffer_array_dynamic_indexing"),
        enums::Capability::CapabilitySampledImageArrayDynamicIndexing =>
            Some("shader_sampled_image_array_dynamic_indexing"),
        enums::Capability::CapabilityStorageBufferArrayDynamicIndexing =>
            Some("shader_storage_buffer_array_dynamic_indexing"),
        enums::Capability::CapabilityStorageImageArrayDynamicIndexing =>
            Some("shader_storage_image_array_dynamic_indexing"),
        enums::Capability::CapabilityClipDistance => Some("shader_clip_distance"),
        enums::Capability::CapabilityCullDistance => Some("shader_cull_distance"),
        enums::Capability::CapabilityImageCubeArray => Some("image_cube_array"),
        enums::Capability::CapabilitySampleRateShading => Some("sample_rate_shading"),
        enums::Capability::CapabilityImageRect => panic!(), // not supported
        enums::Capability::CapabilitySampledRect => panic!(),   // not supported
        enums::Capability::CapabilityGenericPointer => panic!(),    // not supported
        enums::Capability::CapabilityInt8 => panic!(),  // not supported
        enums::Capability::CapabilityInputAttachment => None,       // always supported
        enums::Capability::CapabilitySparseResidency => Some("shader_resource_residency"),
        enums::Capability::CapabilityMinLod => Some("shader_resource_min_lod"),
        enums::Capability::CapabilitySampled1D => None,        // always supported
        enums::Capability::CapabilityImage1D => None,        // always supported
        enums::Capability::CapabilitySampledCubeArray => Some("image_cube_array"),
        enums::Capability::CapabilitySampledBuffer => None,         // always supported
        enums::Capability::CapabilityImageBuffer => None,        // always supported
        enums::Capability::CapabilityImageMSArray => Some("shader_storage_image_multisample"),
        enums::Capability::CapabilityStorageImageExtendedFormats =>
            Some("shader_storage_image_extended_formats"),
        enums::Capability::CapabilityImageQuery => None,        // always supported
        enums::Capability::CapabilityDerivativeControl => None,        // always supported
        enums::Capability::CapabilityInterpolationFunction => Some("sample_rate_shading"),
        enums::Capability::CapabilityTransformFeedback => panic!(), // not supported
        enums::Capability::CapabilityGeometryStreams => panic!(),   // not supported
        enums::Capability::CapabilityStorageImageReadWithoutFormat =>
            Some("shader_storage_image_read_without_format"),
        enums::Capability::CapabilityStorageImageWriteWithoutFormat =>
            Some("shader_storage_image_write_without_format"),
        enums::Capability::CapabilityMultiViewport => Some("multi_viewport"),
    }
}
fn capability_name ( cap : & enums :: Capability ) -> Option < & ' static str > { match * cap { enums :: Capability :: CapabilityMatrix => None , // always supported enums :: Capability :: CapabilityShader => None , // always supported enums :: Capability :: CapabilityGeometry => Some ( " " ) , enums :: Capability :: CapabilityTessellation => Some ( " " ) , enums :: Capability :: CapabilityAddresses => panic ! ( ) , // not supported enums :: Capability :: CapabilityLinkage => panic ! ( ) , // not supported enums :: Capability :: CapabilityKernel => panic ! ( ) , // not supported enums :: Capability :: CapabilityVector16 => panic ! ( ) , // not supported enums :: Capability :: CapabilityFloat16Buffer => panic ! ( ) , // not supported enums :: Capability :: CapabilityFloat16 => panic ! ( ) , // not supported enums :: Capability :: CapabilityFloat64 => Some ( " " ) , enums :: Capability :: CapabilityInt64 => Some ( " " ) , enums :: Capability :: CapabilityInt64Atomics => panic ! ( ) , // not supported enums :: Capability :: CapabilityImageBasic => panic ! ( ) , // not supported enums :: Capability :: CapabilityImageReadWrite => panic ! ( ) , // not supported enums :: Capability :: CapabilityImageMipmap => panic ! ( ) , // not supported enums :: Capability :: CapabilityPipes => panic ! ( ) , // not supported enums :: Capability :: CapabilityGroups => panic ! ( ) , // not supported enums :: Capability :: CapabilityDeviceEnqueue => panic ! ( ) , // not supported enums :: Capability :: CapabilityLiteralSampler => panic ! ( ) , // not supported enums :: Capability :: CapabilityAtomicStorage => panic ! ( ) , // not supported enums :: Capability :: CapabilityInt16 => Some ( " " ) , enums :: Capability :: CapabilityTessellationPointSize => Some ( " " ) , enums :: Capability :: CapabilityGeometryPointSize => Some ( " " ) , enums :: Capability :: CapabilityImageGatherExtended => Some ( " " ) , enums :: Capability :: CapabilityStorageImageMultisample => Some ( " " ) , enums :: Capability :: CapabilityUniformBufferArrayDynamicIndexing => Some ( " " ) , enums :: Capability :: CapabilitySampledImageArrayDynamicIndexing => Some ( " " ) , enums :: Capability :: CapabilityStorageBufferArrayDynamicIndexing => Some ( " " ) , enums :: Capability :: CapabilityStorageImageArrayDynamicIndexing => Some ( " " ) , enums :: Capability :: CapabilityClipDistance => Some ( " " ) , enums :: Capability :: CapabilityCullDistance => Some ( " " ) , enums :: Capability :: CapabilityImageCubeArray => Some ( " " ) , enums :: Capability :: CapabilitySampleRateShading => Some ( " " ) , enums :: Capability :: CapabilityImageRect => panic ! ( ) , // not supported enums :: Capability :: CapabilitySampledRect => panic ! ( ) , // not supported enums :: Capability :: CapabilityGenericPointer => panic ! ( ) , // not supported enums :: Capability :: CapabilityInt8 => panic ! ( ) , // not supported enums :: Capability :: CapabilityInputAttachment => None , // always supported enums :: Capability :: CapabilitySparseResidency => Some ( " " ) , enums :: Capability :: CapabilityMinLod => Some ( " " ) , enums :: Capability :: CapabilitySampled1D => None , // always supported enums :: Capability :: CapabilityImage1D => None , // always supported enums :: Capability :: CapabilitySampledCubeArray => Some ( " " ) , enums :: Capability :: CapabilitySampledBuffer => None , // always supported enums :: Capability :: CapabilityImageBuffer => None , // always supported enums :: Capability :: CapabilityImageMSArray => Some ( " " ) , enums :: Capability :: CapabilityStorageImageExtendedFormats => Some ( " " ) , enums :: Capability :: CapabilityImageQuery => None , // always supported enums :: Capability :: CapabilityDerivativeControl => None , // always supported enums :: Capability :: CapabilityInterpolationFunction => Some ( " " ) , enums :: Capability :: CapabilityTransformFeedback => panic ! ( ) , // not supported enums :: Capability :: CapabilityGeometryStreams => panic ! ( ) , // not supported enums :: Capability :: CapabilityStorageImageReadWithoutFormat => Some ( " " ) , enums :: Capability :: CapabilityStorageImageWriteWithoutFormat => Some ( " " ) , enums :: Capability :: CapabilityMultiViewport => Some ( " " ) , } }
Returns the name of the Vulkan something that corresponds to an `OpCapability`.
Returns the name of the Vulkan something that corresponds to an ` OpCapability ` .
cap
&enums::Capability
cap
&enums::Capability