| 245 | } |
| 246 | |
| 247 | uint32_t GraphContext::deduceMemoryType( uint32_t typeBits |
| 248 | , VkMemoryPropertyFlags requirements )const |
| 249 | { |
| 250 | for ( uint32_t i = 0; i < memoryProperties.memoryTypeCount; ++i ) |
| 251 | { |
| 252 | if ( ( typeBits & 1 ) == 1 |
| 253 | && ( memoryProperties.memoryTypes[i].propertyFlags & requirements ) == requirements ) |
| 254 | { |
| 255 | return i; |
| 256 | } |
| 257 | |
| 258 | typeBits >>= 1; |
| 259 | } |
| 260 | |
| 261 | Logger::logError( "Could not deduce memory type" ); |
| 262 | CRG_Exception( "Could not deduce memory type" ); |
| 263 | } |
| 264 | |
| 265 | #if VK_EXT_debug_utils |
| 266 |
no outgoing calls