MCPcopy Create free account
hub / github.com/DragonJoker/RenderGraph / destroyImage

Method destroyImage

source/RenderGraph/ResourceHandler.cpp:542–562  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

540 }
541
542 void ResourceHandler::destroyImage( GraphContext & context
543 , ImageId imageId )
544 {
545 lock_type lock( m_imagesMutex );
546 auto it = m_images.find( imageId );
547
548 if ( it != m_images.end() )
549 {
550 if ( context.vkDestroyImage && it->second.first )
551 {
552 context.vkDestroyImage( context.device, it->second.first, context.allocator );
553 }
554
555 if ( context.vkFreeMemory && it->second.second )
556 {
557 context.vkFreeMemory( context.device, it->second.second, context.allocator );
558 }
559
560 m_images.erase( it );
561 }
562 }
563
564 void ResourceHandler::destroyImageView( GraphContext & context
565 , ImageViewId viewId )

Callers 2

TESTFunction · 0.80

Calls 4

findMethod · 0.80
eraseMethod · 0.80
beginMethod · 0.80
endMethod · 0.45

Tested by 1

TESTFunction · 0.64