Lines Matching refs:scratchKey
690 GrScratchKey scratchKey; in test_duplicate_scratch_key() local
691 TestResource::ComputeScratchKey(TestResource::kB_SimulatedProperty, &scratchKey); in test_duplicate_scratch_key()
695 SkDEBUGCODE(REPORTER_ASSERT(reporter, 2 == cache->countScratchEntriesForKey(scratchKey));) in test_duplicate_scratch_key()
709 SkDEBUGCODE(REPORTER_ASSERT(reporter, 2 == cache->countScratchEntriesForKey(scratchKey));) in test_duplicate_scratch_key()
715 SkDEBUGCODE(REPORTER_ASSERT(reporter, 0 == cache->countScratchEntriesForKey(scratchKey));) in test_duplicate_scratch_key()
731 GrScratchKey scratchKey; in test_remove_scratch_key() local
733 TestResource::ComputeScratchKey(TestResource::kA_SimulatedProperty, &scratchKey); in test_remove_scratch_key()
735 …REPORTER_ASSERT(reporter, cache->findAndRefScratchResource(scratchKey, TestResource::kDefaultSize,… in test_remove_scratch_key()
738 TestResource::ComputeScratchKey(TestResource::kB_SimulatedProperty, &scratchKey); in test_remove_scratch_key()
740 SkDEBUGCODE(REPORTER_ASSERT(reporter, 2 == cache->countScratchEntriesForKey(scratchKey));) in test_remove_scratch_key()
745 find = cache->findAndRefScratchResource(scratchKey, TestResource::kDefaultSize, 0); in test_remove_scratch_key()
749 SkDEBUGCODE(REPORTER_ASSERT(reporter, 1 == cache->countScratchEntriesForKey(scratchKey));) in test_remove_scratch_key()
755 SkDEBUGCODE(REPORTER_ASSERT(reporter, 1 == cache->countScratchEntriesForKey(scratchKey));) in test_remove_scratch_key()
759 find = cache->findAndRefScratchResource(scratchKey, TestResource::kDefaultSize, 0); in test_remove_scratch_key()
762 SkDEBUGCODE(REPORTER_ASSERT(reporter, 0 == cache->countScratchEntriesForKey(scratchKey));) in test_remove_scratch_key()
768 SkDEBUGCODE(REPORTER_ASSERT(reporter, 0 == cache->countScratchEntriesForKey(scratchKey));) in test_remove_scratch_key()
773 SkDEBUGCODE(REPORTER_ASSERT(reporter, 0 == cache->countScratchEntriesForKey(scratchKey));) in test_remove_scratch_key()
790 GrScratchKey scratchKey; in test_scratch_key_consistency() local
799 scratchKey = scratchKey1; in test_scratch_key_consistency()
800 REPORTER_ASSERT(reporter, scratchKey.size() == TestResource::ExpectedScratchKeySize()); in test_scratch_key_consistency()
801 REPORTER_ASSERT(reporter, scratchKey1 == scratchKey); in test_scratch_key_consistency()
802 REPORTER_ASSERT(reporter, scratchKey == scratchKey1); in test_scratch_key_consistency()
803 REPORTER_ASSERT(reporter, scratchKey2 != scratchKey); in test_scratch_key_consistency()
804 REPORTER_ASSERT(reporter, scratchKey != scratchKey2); in test_scratch_key_consistency()
805 scratchKey = scratchKey2; in test_scratch_key_consistency()
806 REPORTER_ASSERT(reporter, scratchKey.size() == TestResource::ExpectedScratchKeySize()); in test_scratch_key_consistency()
807 REPORTER_ASSERT(reporter, scratchKey1 != scratchKey); in test_scratch_key_consistency()
808 REPORTER_ASSERT(reporter, scratchKey != scratchKey1); in test_scratch_key_consistency()
809 REPORTER_ASSERT(reporter, scratchKey2 == scratchKey); in test_scratch_key_consistency()
810 REPORTER_ASSERT(reporter, scratchKey == scratchKey2); in test_scratch_key_consistency()
813 TestResource::ComputeScratchKey(TestResource::kA_SimulatedProperty, &scratchKey); in test_scratch_key_consistency()
815 …REPORTER_ASSERT(reporter, cache->findAndRefScratchResource(scratchKey, TestResource::kDefaultSize,… in test_scratch_key_consistency()
818 TestResource::ComputeScratchKey(TestResource::kB_SimulatedProperty, &scratchKey); in test_scratch_key_consistency()
819 … GrGpuResource* find = cache->findAndRefScratchResource(scratchKey, TestResource::kDefaultSize, 0); in test_scratch_key_consistency()
823 scratchKey2 = scratchKey; in test_scratch_key_consistency()
983 GrScratchKey scratchKey; in test_purge_invalidated() local
984 TestResource::ComputeScratchKey(TestResource::kA_SimulatedProperty, &scratchKey); in test_purge_invalidated()
985 …GrGpuResource* scratch = cache->findAndRefScratchResource(scratchKey, TestResource::kDefaultSize, … in test_purge_invalidated()
991 scratch = cache->findAndRefScratchResource(scratchKey, TestResource::kDefaultSize, 0); in test_purge_invalidated()