MCPcopy Create free account
hub / github.com/LunarG/VulkanTools / isFrameInRange

Method isFrameInRange

layersvt/api_dump.h:289–313  ·  view source on GitHub ↗

Return true if either use_conditional_output is false or if frame_count is within the provided frame ranges

Source from the content-addressed store, hash-verified

287 // Return true if either use_conditional_output is false or if frame_count is within
288 // the provided frame ranges
289 bool isFrameInRange(uint64_t frame_number) const {
290 if (!use_conditional_output) return true;
291 for (auto &range : ranges) {
292 if (range.start_frame <= frame_number) {
293 if (range.frame_count == OUTPUT_RANGE_UNLIMITED) {
294 if (range.interval == OUTPUT_RANGE_INTERVAL_DEFAULT) {
295 return true;
296 } else {
297 return (frame_number - range.start_frame) % range.interval == 0;
298 }
299
300 } else if (range.start_frame + range.frame_count > frame_number) {
301 if (range.interval == OUTPUT_RANGE_INTERVAL_DEFAULT) {
302 return true;
303 } else {
304 return (frame_number - range.start_frame) % range.interval == 0;
305 }
306 }
307 }
308 }
309 if (frames.count(frame_number) > 0) {
310 return true;
311 }
312 return false;
313 }
314};
315
316#ifdef __ANDROID__

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected