Flutter Engine
The Flutter Engine
Public Member Functions | Static Public Member Functions | List of all members
skgpu::AtlasToken Class Reference

#include <AtlasTypes.h>

Public Member Functions

 AtlasToken (const AtlasToken &)=default
 
AtlasTokenoperator= (const AtlasToken &)=default
 
bool operator== (const AtlasToken &that) const
 
bool operator!= (const AtlasToken &that) const
 
bool operator< (const AtlasToken that) const
 
bool operator<= (const AtlasToken that) const
 
bool operator> (const AtlasToken that) const
 
bool operator>= (const AtlasToken that) const
 
AtlasTokenoperator++ ()
 
AtlasToken operator++ (int)
 
AtlasToken next () const
 
bool inInterval (const AtlasToken &start, const AtlasToken &end)
 

Static Public Member Functions

static AtlasToken InvalidToken ()
 

Detailed Description

AtlasToken is used to sequence uploads relative to each other and to batches of draws.

Definition at line 151 of file AtlasTypes.h.

Constructor & Destructor Documentation

◆ AtlasToken()

skgpu::AtlasToken::AtlasToken ( const AtlasToken )
default

Member Function Documentation

◆ inInterval()

bool skgpu::AtlasToken::inInterval ( const AtlasToken start,
const AtlasToken end 
)
inline

Is this token in the [start, end] inclusive interval?

Definition at line 188 of file AtlasTypes.h.

188 {
189 return *this >= start && *this <= end;
190 }
glong glong end

◆ InvalidToken()

static AtlasToken skgpu::AtlasToken::InvalidToken ( )
inlinestatic

Definition at line 153 of file AtlasTypes.h.

153{ return AtlasToken(0); }

◆ next()

AtlasToken skgpu::AtlasToken::next ( ) const
inline

Definition at line 185 of file AtlasTypes.h.

185{ return AtlasToken(fSequenceNumber + 1); }

◆ operator!=()

bool skgpu::AtlasToken::operator!= ( const AtlasToken that) const
inline

Definition at line 161 of file AtlasTypes.h.

161{ return !(*this == that); }

◆ operator++() [1/2]

AtlasToken & skgpu::AtlasToken::operator++ ( )
inline

Definition at line 175 of file AtlasTypes.h.

175 {
176 ++fSequenceNumber;
177 return *this;
178 }

◆ operator++() [2/2]

AtlasToken skgpu::AtlasToken::operator++ ( int  )
inline

Definition at line 179 of file AtlasTypes.h.

179 {
180 auto old = fSequenceNumber;
181 ++fSequenceNumber;
182 return AtlasToken(old);
183 }

◆ operator<()

bool skgpu::AtlasToken::operator< ( const AtlasToken  that) const
inline

Definition at line 162 of file AtlasTypes.h.

162 {
163 return fSequenceNumber < that.fSequenceNumber;
164 }

◆ operator<=()

bool skgpu::AtlasToken::operator<= ( const AtlasToken  that) const
inline

Definition at line 165 of file AtlasTypes.h.

165 {
166 return fSequenceNumber <= that.fSequenceNumber;
167 }

◆ operator=()

AtlasToken & skgpu::AtlasToken::operator= ( const AtlasToken )
default

◆ operator==()

bool skgpu::AtlasToken::operator== ( const AtlasToken that) const
inline

Definition at line 158 of file AtlasTypes.h.

158 {
159 return fSequenceNumber == that.fSequenceNumber;
160 }

◆ operator>()

bool skgpu::AtlasToken::operator> ( const AtlasToken  that) const
inline

Definition at line 168 of file AtlasTypes.h.

168 {
169 return fSequenceNumber > that.fSequenceNumber;
170 }

◆ operator>=()

bool skgpu::AtlasToken::operator>= ( const AtlasToken  that) const
inline

Definition at line 171 of file AtlasTypes.h.

171 {
172 return fSequenceNumber >= that.fSequenceNumber;
173 }

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