-
Notifications
You must be signed in to change notification settings - Fork 437
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
macOS: BufferUsage::all() breaks examples #1383
Comments
Also, just running the simplest example from the guide: let source_content = 0..64;
let source =
CpuAccessibleBuffer::from_iter(device.clone(), BufferUsage::all(), false, source_content)
.expect("failed to create buffer");
let dest_content = (0..64).map(|_| 0_i32);
let dest =
CpuAccessibleBuffer::from_iter(device.clone(), BufferUsage::all(), false, dest_content)
.expect("failed to create buffer");
let mut builder = AutoCommandBufferBuilder::new(device.clone(), queue.family()).unwrap();
builder.copy_buffer(source.clone(), dest.clone()).unwrap();
let command_buffer = builder.build().unwrap();
command_buffer
.execute(queue.clone())
.unwrap()
.then_signal_fence_and_flush()
.unwrap()
.wait(None)
.unwrap();
let src_content = source.read().unwrap();
let dest_content = dest.read().unwrap();
assert_eq!(&*src_content, &*dest_content); It doesn't seem to actually do the thing.
|
Related: #1368 (comment) Cause is still unknown at this time. I don't have access to macOS hardware either. You could try using previous versions of the macOS deps here: vulkano/vulkano-win/Cargo.toml Line 24 in c5dd6ed
Maybe using another queue from the returned queue families? Maybe try broadening the vulkano/examples/src/bin/triangle.rs Line 182 in c5dd6ed
Not sure anything seems to be possible. If there a debugging tools available you could try to find one and see if it gives any errors or warnings. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Sorry for spamming! Hopefully my debugging process is useful to someone. I got It looks like the issue is something with let source = CpuAccessibleBuffer::from_iter(device.clone(), BufferUsage::all(), false, source_content)?;
let dest = CpuAccessibleBuffer::from_iter(device.clone(), BufferUsage::all(), false, dest_content)?; to let source = CpuAccessibleBuffer::from_iter(device.clone(), BufferUsage::transfer_source(), false, source_content)?;
let dest = CpuAccessibleBuffer::from_iter(device.clone(), BufferUsage::transfer_dest(), false, dest_content)?; Then it suddenly works. Similarly, changing the code in the My question: should I make a PR to change the examples or is this a bug in |
BufferUsage::all()
breaks examples
BufferUsage::all()
breaks examples
Certainly wondering if there was a change in spec or something that changed how usages work. In practice having a broad usage shouldn't cause issues, it may just be nonoptimal. Changing the guide to further explain usages instead of using BufferUsage::all() everywhere would probably be a good idea and all the examples also. As to why this is causing poor behaviour I note quite sure. |
I have same behaviour on mid 2015 mac pro, tweaking
Which seems related to the commmit @colinmarc pointed to. |
For me,it worked after I changed the From:
To:
|
Running the triangle example on a fresh install of macOS with the vulkan SDK, I get a blue screen but no triangles:
My laptop is a 2020 macbook air, still with the new computer smell, and an integrated GPU.
I'm more than happy to debug myself, given some direction! I'm not really sure where to start.
The text was updated successfully, but these errors were encountered: