MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / VmaVectorRemoveSorted

Function VmaVectorRemoveSorted

3rdparty/vulkan/include/vk_mem_alloc.h:4469–4484  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4467
4468template<typename CmpLess, typename VectorT>
4469bool VmaVectorRemoveSorted(VectorT& vector, const typename VectorT::value_type& value)
4470{
4471 CmpLess comparator;
4472 typename VectorT::iterator it = VmaBinaryFindFirstNotLess(
4473 vector.begin(),
4474 vector.end(),
4475 value,
4476 comparator);
4477 if ((it != vector.end()) && !comparator(*it, value) && !comparator(value, *it))
4478 {
4479 size_t indexToRemove = it - vector.begin();
4480 VmaVectorRemove(vector, indexToRemove);
4481 return true;
4482 }
4483 return false;
4484}
4485
4486} // namespace
4487

Callers

nothing calls this directly

Calls 4

VmaVectorRemoveFunction · 0.70
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected