Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Static Public Member Functions | List of all members
GrDrawOpAtlasTools Class Reference

#include <GrAtlasTools.h>

Static Public Member Functions

static int NumAllocated (const GrDrawOpAtlas *)
 
static void SetMaxPages (GrDrawOpAtlas *, uint32_t maxPages)
 

Detailed Description

Definition at line 25 of file GrAtlasTools.h.

Member Function Documentation

◆ NumAllocated()

int GrDrawOpAtlasTools::NumAllocated ( const GrDrawOpAtlas doa)
static

Definition at line 123 of file GrAtlasTools.cpp.

123 {
124 SkASSERT(doa);
125 int count = 0;
126 for (uint32_t i = 0; i < doa->maxPages(); ++i) {
127 if (doa->fViews[i].proxy()->isInstantiated()) {
128 ++count;
129 }
130 }
131
132 return count;
133}
int count
#define SkASSERT(cond)
Definition SkAssert.h:116
uint32_t maxPages() const
GrSurfaceProxy * proxy() const
bool isInstantiated() const

◆ SetMaxPages()

void GrDrawOpAtlasTools::SetMaxPages ( GrDrawOpAtlas doa,
uint32_t  maxPages 
)
static

Definition at line 135 of file GrAtlasTools.cpp.

135 {
136 SkASSERT(!doa->fNumActivePages);
137
138 doa->fMaxPages = maxPages;
139}

The documentation for this class was generated from the following files: