vulkan
vulkan copied to clipboard
VkPipeline array type incorrect (compute example fails)
(First - thanks for the cool package!).
Running the compute example fails with the trace below. I tried various fixes like ffi.new("VkPipeline*") etc but didn't find a way to fix it. I get the same behavior on linux and mac installations using either the pip package or installation from source.
It looks like this is related to #56.
$python example_mandelbrot_compute.py
Traceback (most recent call last):
File "example_mandelbrot_compute.py", line 562, in <module>
app.run()
File "example_mandelbrot_compute.py", line 134, in run
self.createCommandBuffer()
File "example_mandelbrot_compute.py", line 517, in createCommandBuffer
vkCmdBindPipeline(self.__commandBuffer, VK_PIPELINE_BIND_POINT_COMPUTE, self.__pipeline)
File "/usr/local/lib/python2.7/dist-packages/vulkan-1.1.99.1-py2.7.egg/vulkan/_vulkan.py", line 6340, in vkCmdBindPipeline
result = _callApi(lib.vkCmdBindPipeline, commandBuffer,pipelineBindPoint,pipeline)
File "/usr/local/lib/python2.7/dist-packages/vulkan-1.1.99.1-py2.7.egg/vulkan/_vulkan.py", line 4962, in _callApi
return fn(*fn_args)
TypeError: initializer for ctype 'struct VkPipeline_T *' must be a pointer to same type, not cdata 'struct VkPipeline_T *[1]'
Exception TypeError: "'NoneType' object is not callable" in <bound method ComputeApplication.__del__ of <__main__.ComputeApplication object at 0x7fa3387d3810>> ignored
Hello, Thanks for the report. Index I didn't updater the contrib tests. I will take a look.
Is there a version of the code in github or pypy that should work for the compute example?
You can try at this commit: https://github.com/realitix/vulkan/commit/6033845aa77d7d272e6d1be03f30b00fa1ac9c37
Yes, that one works - thanks!