Ejemplo n.º 1
0
    def __init__(
        self, err_file=sys.stderr, warn_file=sys.stderr, diag_file=sys.stdout
    ):
        BaseGenerator.__init__(
            self,
            process_cmds=True,
            process_structs=False,
            feature_break=False,
            err_file=err_file,
            warn_file=warn_file,
            diag_file=diag_file
        )
        # Map of return types to default return values for no-op functions
        self.RETURN_DEFAULTS = {
            'VkResult': 'VK_SUCCESS',
            'VkBool32': 'VK_TRUE',
            'PFN_vkVoidFunction': 'nullptr',
            'VkDeviceAddress': '0',
            'VkDeviceSize': '0',
            'uint32_t': '0',
            'uint64_t': '0'
        }

        self.instance_cmd_names = dict(
        )  # Map of API call names to no-op function declarations
        self.device_cmd_names = dict(
        )  # Map of API call names to no-op function declarations
 def __init__(self,
              err_file=sys.stderr,
              warn_file=sys.stderr,
              diag_file=sys.stdout):
     BaseGenerator.__init__(self,
                            process_cmds=False,
                            process_structs=True,
                            feature_break=True,
                            err_file=err_file,
                            warn_file=warn_file,
                            diag_file=diag_file)
    def __init__(self,
                 err_file=sys.stderr,
                 warn_file=sys.stderr,
                 diag_file=sys.stdout):
        BaseGenerator.__init__(self,
                               process_cmds=False,
                               process_structs=False,
                               feature_break=False,
                               err_file=err_file,
                               warn_file=warn_file,
                               diag_file=diag_file)

        # Map to store VkStructureType enum values.
        self.stype_values = dict()
Ejemplo n.º 4
0
    def __init__(self,
                 err_file=sys.stderr,
                 warn_file=sys.stderr,
                 diag_file=sys.stdout):
        BaseGenerator.__init__(self,
                               process_cmds=False,
                               process_structs=True,
                               feature_break=True,
                               err_file=err_file,
                               warn_file=warn_file,
                               diag_file=diag_file)

        self.physical_device_features2_stypes = dict()
        # List of 1.0 features
        self.physical_device_features = []
Ejemplo n.º 5
0
    def __init__(
        self, err_file=sys.stderr, warn_file=sys.stderr, diag_file=sys.stdout
    ):
        BaseGenerator.__init__(
            self,
            process_cmds=True,
            process_structs=False,
            feature_break=True,
            err_file=err_file,
            warn_file=warn_file,
            diag_file=diag_file
        )

        # Names of all Vulkan commands processed by the generator.
        self.cmd_names = []
    def __init__(self,
                 err_file=sys.stderr,
                 warn_file=sys.stderr,
                 diag_file=sys.stdout):
        BaseGenerator.__init__(self,
                               process_cmds=True,
                               process_structs=True,
                               feature_break=True,
                               err_file=err_file,
                               warn_file=warn_file,
                               diag_file=diag_file)

        # Map of Vulkan structs containing handles to a list values for handle members or struct members
        # that contain handles (eg. VkGraphicsPipelineCreateInfo contains a VkPipelineShaderStageCreateInfo
        # member that contains handles).
        self.structs_with_handles = dict()
Ejemplo n.º 7
0
 def __init__(self,
              err_file=sys.stderr,
              warn_file=sys.stderr,
              diag_file=sys.stdout):
     BaseGenerator.__init__(self,
                            process_cmds=True,
                            process_structs=True,
                            feature_break=False,
                            err_file=err_file,
                            warn_file=warn_file,
                            diag_file=diag_file)
     # Map of Vulkan structs containing handles to a list values for handle members or struct members
     # that contain handles (eg. VkGraphicsPipelineCreateInfo contains a VkPipelineShaderStageCreateInfo
     # member that contains handles).
     self.structs_with_handles = dict()
     self.command_info = dict()  # Map of Vulkan commands to parameter info
     self.restrict_handles = True  # Determines if the 'is_handle' override limits the handle test to only the values conained by RESOURCE_HANDLE_TYPES.
Ejemplo n.º 8
0
    def __init__(self,
                 err_file=sys.stderr,
                 warn_file=sys.stderr,
                 diag_file=sys.stdout):
        BaseGenerator.__init__(self,
                               process_cmds=True,
                               process_structs=True,
                               feature_break=False,
                               err_file=err_file,
                               warn_file=warn_file,
                               diag_file=diag_file)

        # Map of Vulkan structs containing handles to a list values for handle members or struct members
        # that contain handles (eg. VkGraphicsPipelineCreateInfo contains a VkPipelineShaderStageCreateInfo
        # member that contains handles).
        self.structs_with_handles = dict()
        self.pnext_structs = dict(
        )  # Map of Vulkan structure types to sType value for structs that can be part of a pNext chain.
        self.command_info = dict()  # Map of Vulkan commands to parameter info
    def __init__(self,
                 err_file=sys.stderr,
                 warn_file=sys.stderr,
                 diag_file=sys.stdout):
        BaseGenerator.__init__(self,
                               process_cmds=True,
                               process_structs=True,
                               feature_break=False,
                               err_file=err_file,
                               warn_file=warn_file,
                               diag_file=diag_file)

        # Map of Vulkan structs containing handles to a list values for handle members or struct members
        # that contain handles (eg. VkGraphicsPipelineCreateInfo contains a VkPipelineShaderStageCreateInfo
        # member that contains handles).
        self.structs_with_handles = dict()
        self.structs_with_handle_ptrs = []
        # List of structs containing handles that are also used as output parameters for a command
        self.output_structs_with_handles = []
        self.structs_with_map_data = dict()
Ejemplo n.º 10
0
    def __init__(self,
                 err_file=sys.stderr,
                 warn_file=sys.stderr,
                 diag_file=sys.stdout):
        BaseGenerator.__init__(self,
                               process_cmds=True,
                               process_structs=False,
                               feature_break=True,
                               err_file=err_file,
                               warn_file=warn_file,
                               diag_file=diag_file)

        # The following functions require custom implementations for to ASCII
        self.customImplementationRequired = {
            'vkAllocateCommandBuffers',
            'vkAllocateDescriptorSets',
            'vkCmdBuildAccelerationStructuresIndirectKHR',
            'vkCmdBuildAccelerationStructuresKHR',
            'vkGetAccelerationStructureBuildSizesKHR',
        }
    def __init__(self,
                 err_file=sys.stderr,
                 warn_file=sys.stderr,
                 diag_file=sys.stdout):
        BaseGenerator.__init__(self,
                               process_cmds=True,
                               process_structs=False,
                               feature_break=False,
                               err_file=err_file,
                               warn_file=warn_file,
                               diag_file=diag_file)

        # The trace layer does not currently implement or export the instance version query
        self.APICALL_BLACKLIST = ['vkEnumerateInstanceVersion']

        # These functions are provided directly by the layer, and are not encoded
        self.LAYER_FUNCTIONS = [
            'vkGetInstanceProcAddr', 'vkGetDeviceProcAddr',
            'vkEnumerateInstanceLayerProperties',
            'vkEnumerateDeviceLayerProperties',
            'vkEnumerateInstanceExtensionProperties',
            'vkEnumerateDeviceExtensionProperties'
        ]