mirror of
https://github.com/vulkano-rs/vulkano.git
synced 2025-02-20 11:03:10 +00:00
Add comments about attachment image problem
This commit is contained in:
parent
d8149a33d1
commit
b5be7a7d86
@ -787,6 +787,8 @@ unsafe impl<I> CommandBuffer for SubmitSyncLayer<I> where I: CommandBuffer {
|
||||
Err(err) => err
|
||||
};
|
||||
|
||||
// FIXME: this is bad because dropping the submit sync layer doesn't drop the
|
||||
// attachments of the framebuffer, meaning that they will stay locked
|
||||
match (img.try_gpu_lock(entry.exclusive, queue), prev_err) {
|
||||
(Ok(_), _) => (),
|
||||
(Err(err), AccessCheckError::Unknown) => return Err(err.into()),
|
||||
|
@ -238,6 +238,8 @@ unsafe impl<F, A> ImageAccess for AttachmentImageAccess<F, A>
|
||||
#[inline]
|
||||
fn try_gpu_lock(&self, _: bool, _: &Queue) -> Result<(), AccessError> {
|
||||
// FIXME: uncomment when it's working
|
||||
// the problem is in the submit sync layer which locks framebuffer attachments and
|
||||
// keeps them locked even after destruction
|
||||
Ok(())
|
||||
/*if self.already_locked.swap(true, Ordering::SeqCst) == true {
|
||||
return false;
|
||||
@ -249,6 +251,8 @@ unsafe impl<F, A> ImageAccess for AttachmentImageAccess<F, A>
|
||||
#[inline]
|
||||
unsafe fn increase_gpu_lock(&self) {
|
||||
// FIXME: uncomment when it's working
|
||||
// the problem is in the submit sync layer which locks framebuffer attachments and
|
||||
// keeps them locked even after destruction
|
||||
/*debug_assert!(self.already_locked.load(Ordering::SeqCst));
|
||||
let val = self.img.gpu_lock.fetch_add(1, Ordering::SeqCst);
|
||||
debug_assert!(val >= 1);*/
|
||||
|
Loading…
Reference in New Issue
Block a user