Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Member Functions | List of all members
SkImage_GaneshYUVA Class Referencefinal

#include <SkImage_GaneshYUVA.h>

Inheritance diagram for SkImage_GaneshYUVA:
SkImage_GaneshBase SkImage_Base SkImage SkRefCnt SkRefCntBase

Public Member Functions

 SkImage_GaneshYUVA (sk_sp< GrImageContext >, uint32_t uniqueID, GrYUVATextureProxies proxies, sk_sp< SkColorSpace >)
 
size_t textureSize () const override
 
SkImage_Base::Type type () const override
 
bool onHasMipmaps () const override
 
bool onIsProtected () const override
 
sk_sp< SkImageonMakeColorTypeAndColorSpace (SkColorType, sk_sp< SkColorSpace >, GrDirectContext *) const final
 
sk_sp< SkImageonReinterpretColorSpace (sk_sp< SkColorSpace >) const final
 
GrSemaphoresSubmitted flush (GrDirectContext *, const GrFlushInfo &) const override
 
std::tuple< GrSurfaceProxyView, GrColorTypeasView (GrRecordingContext *, skgpu::Mipmapped, GrImageTexGenPolicy) const override
 
std::unique_ptr< GrFragmentProcessorasFragmentProcessor (GrRecordingContext *, SkSamplingOptions, const SkTileMode[2], const SkMatrix &, const SkRect *, const SkRect *) const override
 
bool setupMipmapsForPlanes (GrRecordingContext *) const
 
GrSurfaceOrigin origin () const override
 
virtual sk_sp< SkImageonMakeColorTypeAndColorSpace (SkColorType, sk_sp< SkColorSpace >, GrDirectContext *) const =0
 
- Public Member Functions inherited from SkImage_GaneshBase
bool isValid (GrRecordingContext *) const final
 
sk_sp< SkImagemakeColorTypeAndColorSpace (GrDirectContext *dContext, SkColorType targetColorType, sk_sp< SkColorSpace > targetCS) const final
 
sk_sp< SkImagemakeSubset (GrDirectContext *direct, const SkIRect &subset) const final
 
GrImageContextcontext () const final
 
GrDirectContextdirectContext () const final
 
bool getROPixels (GrDirectContext *, SkBitmap *, CachingHint) const final
 
sk_sp< SkImageonMakeSubset (GrDirectContext *, const SkIRect &subset) const final
 
bool onReadPixels (GrDirectContext *dContext, const SkImageInfo &dstInfo, void *dstPixels, size_t dstRB, int srcX, int srcY, CachingHint) const override
 
- Public Member Functions inherited from SkImage_Base
 ~SkImage_Base () override
 
sk_sp< SkImagemakeColorSpace (GrDirectContext *, sk_sp< SkColorSpace >) const override
 
sk_sp< SkImagemakeColorSpace (skgpu::graphite::Recorder *, sk_sp< SkColorSpace >, RequiredProperties) const override
 
sk_sp< SkImagemakeSubset (skgpu::graphite::Recorder *, const SkIRect &, RequiredProperties) const override
 
virtual bool onPeekPixels (SkPixmap *) const
 
virtual const SkBitmaponPeekBitmap () const
 
virtual SkMipmaponPeekMips () const
 
sk_sp< SkMipmaprefMips () const
 
virtual void onAsyncRescaleAndReadPixels (const SkImageInfo &, SkIRect srcRect, RescaleGamma, RescaleMode, ReadPixelsCallback, ReadPixelsContext) const
 
virtual void onAsyncRescaleAndReadPixelsYUV420 (SkYUVColorSpace, bool readAlpha, sk_sp< SkColorSpace > dstColorSpace, SkIRect srcRect, SkISize dstSize, RescaleGamma, RescaleMode, ReadPixelsCallback, ReadPixelsContext) const
 
virtual void generatingSurfaceIsDeleted ()
 
virtual sk_sp< SkDataonRefEncoded () const
 
virtual bool onAsLegacyBitmap (GrDirectContext *, SkBitmap *) const
 
bool isLazyGenerated () const override
 
bool isRasterBacked () const
 
bool isGaneshBacked () const
 
bool isGraphiteBacked () const
 
bool isYUVA () const
 
bool isTextureBacked () const override
 
virtual void notifyAddedToRasterCache () const
 
virtual sk_sp< SkImageonMakeWithMipmaps (sk_sp< SkMipmap >) const
 
- Public Member Functions inherited from SkImage
const SkImageInfoimageInfo () const
 
int width () const
 
int height () const
 
SkISize dimensions () const
 
SkIRect bounds () const
 
uint32_t uniqueID () const
 
SkAlphaType alphaType () const
 
SkColorType colorType () const
 
SkColorSpacecolorSpace () const
 
sk_sp< SkColorSpacerefColorSpace () const
 
bool isAlphaOnly () const
 
bool isOpaque () const
 
sk_sp< SkShadermakeShader (SkTileMode tmx, SkTileMode tmy, const SkSamplingOptions &, const SkMatrix *localMatrix=nullptr) const
 
sk_sp< SkShadermakeShader (SkTileMode tmx, SkTileMode tmy, const SkSamplingOptions &sampling, const SkMatrix &lm) const
 
sk_sp< SkShadermakeShader (const SkSamplingOptions &sampling, const SkMatrix &lm) const
 
sk_sp< SkShadermakeShader (const SkSamplingOptions &sampling, const SkMatrix *lm=nullptr) const
 
sk_sp< SkShadermakeRawShader (SkTileMode tmx, SkTileMode tmy, const SkSamplingOptions &, const SkMatrix *localMatrix=nullptr) const
 
sk_sp< SkShadermakeRawShader (SkTileMode tmx, SkTileMode tmy, const SkSamplingOptions &sampling, const SkMatrix &lm) const
 
sk_sp< SkShadermakeRawShader (const SkSamplingOptions &sampling, const SkMatrix &lm) const
 
sk_sp< SkShadermakeRawShader (const SkSamplingOptions &sampling, const SkMatrix *lm=nullptr) const
 
bool peekPixels (SkPixmap *pixmap) const
 
bool readPixels (GrDirectContext *context, const SkImageInfo &dstInfo, void *dstPixels, size_t dstRowBytes, int srcX, int srcY, CachingHint cachingHint=kAllow_CachingHint) const
 
bool readPixels (GrDirectContext *context, const SkPixmap &dst, int srcX, int srcY, CachingHint cachingHint=kAllow_CachingHint) const
 
bool readPixels (const SkImageInfo &dstInfo, void *dstPixels, size_t dstRowBytes, int srcX, int srcY, CachingHint cachingHint=kAllow_CachingHint) const
 
bool readPixels (const SkPixmap &dst, int srcX, int srcY, CachingHint cachingHint=kAllow_CachingHint) const
 
void asyncRescaleAndReadPixels (const SkImageInfo &info, const SkIRect &srcRect, RescaleGamma rescaleGamma, RescaleMode rescaleMode, ReadPixelsCallback callback, ReadPixelsContext context) const
 
void asyncRescaleAndReadPixelsYUV420 (SkYUVColorSpace yuvColorSpace, sk_sp< SkColorSpace > dstColorSpace, const SkIRect &srcRect, const SkISize &dstSize, RescaleGamma rescaleGamma, RescaleMode rescaleMode, ReadPixelsCallback callback, ReadPixelsContext context) const
 
void asyncRescaleAndReadPixelsYUVA420 (SkYUVColorSpace yuvColorSpace, sk_sp< SkColorSpace > dstColorSpace, const SkIRect &srcRect, const SkISize &dstSize, RescaleGamma rescaleGamma, RescaleMode rescaleMode, ReadPixelsCallback callback, ReadPixelsContext context) const
 
bool scalePixels (const SkPixmap &dst, const SkSamplingOptions &, CachingHint cachingHint=kAllow_CachingHint) const
 
sk_sp< SkDatarefEncodedData () const
 
bool hasMipmaps () const
 
bool isProtected () const
 
sk_sp< SkImagewithDefaultMipmaps () const
 
sk_sp< SkImagemakeNonTextureImage (GrDirectContext *=nullptr) const
 
sk_sp< SkImagemakeRasterImage (GrDirectContext *, CachingHint cachingHint=kDisallow_CachingHint) const
 
sk_sp< SkImagemakeRasterImage (CachingHint cachingHint=kDisallow_CachingHint) const
 
bool asLegacyBitmap (SkBitmap *bitmap, LegacyBitmapMode legacyBitmapMode=kRO_LegacyBitmapMode) const
 
sk_sp< SkImagereinterpretColorSpace (sk_sp< SkColorSpace > newColorSpace) const
 
- Public Member Functions inherited from SkRefCntBase
 SkRefCntBase ()
 
virtual ~SkRefCntBase ()
 
bool unique () const
 
void ref () const
 
void unref () const
 

Additional Inherited Members

- Public Types inherited from SkImage_Base
enum class  Type {
  kRaster , kRasterPinnable , kLazy , kLazyPicture ,
  kGanesh , kGaneshYUVA , kGraphite , kGraphiteYUVA
}
 
- Public Types inherited from SkImage
enum  CachingHint { kAllow_CachingHint , kDisallow_CachingHint }
 
enum class  RescaleGamma : bool { kSrc , kLinear }
 
enum class  RescaleMode { kNearest , kLinear , kRepeatedLinear , kRepeatedCubic }
 
enum  LegacyBitmapMode { kRO_LegacyBitmapMode }
 
using ReadPixelsContext = void *
 
using ReadPixelsCallback = void(ReadPixelsContext, std::unique_ptr< const AsyncReadResult >)
 
- Static Public Member Functions inherited from SkImage_GaneshBase
static bool ValidateBackendTexture (const GrCaps *, const GrBackendTexture &tex, GrColorType grCT, SkColorType ct, SkAlphaType at, sk_sp< SkColorSpace > cs)
 
static bool ValidateCompressedBackendTexture (const GrCaps *, const GrBackendTexture &tex, SkAlphaType)
 
static sk_sp< GrTextureProxyMakePromiseImageLazyProxy (GrContextThreadSafeProxy *, SkISize dimensions, const GrBackendFormat &, skgpu::Mipmapped, SkImages::PromiseImageTextureFulfillProc, sk_sp< skgpu::RefCntedCallback > releaseHelper)
 
- Protected Member Functions inherited from SkImage_GaneshBase
 SkImage_GaneshBase (sk_sp< GrImageContext >, SkImageInfo, uint32_t uniqueID)
 
sk_sp< SkImageonMakeSubset (skgpu::graphite::Recorder *, const SkIRect &subset, RequiredProperties) const final
 
sk_sp< SkImagemakeColorTypeAndColorSpace (skgpu::graphite::Recorder *, SkColorType, sk_sp< SkColorSpace >, RequiredProperties) const final
 
- Protected Member Functions inherited from SkImage_Base
 SkImage_Base (const SkImageInfo &info, uint32_t uniqueID)
 
- Protected Attributes inherited from SkImage_GaneshBase
sk_sp< GrImageContextfContext
 

Detailed Description

Definition at line 47 of file SkImage_GaneshYUVA.h.

Constructor & Destructor Documentation

◆ SkImage_GaneshYUVA()

SkImage_GaneshYUVA::SkImage_GaneshYUVA ( sk_sp< GrImageContext context,
uint32_t  uniqueID,
GrYUVATextureProxies  proxies,
sk_sp< SkColorSpace imageColorSpace 
)

Definition at line 64 of file SkImage_GaneshYUVA.cpp.

68 : INHERITED(std::move(context),
71 // If an alpha channel is present we always use kPremul. This
72 // is because, although the planar data is always un-premul,
73 // the final interleaved RGBA sample produced in the shader
74 // is premul (and similar if flattened via asView).
77 std::move(imageColorSpace)),
79 , fYUVAProxies(std::move(proxies)) {
80 // The caller should have checked this, just verifying.
81 SkASSERT(fYUVAProxies.isValid());
82}
@ kOpaque_SkAlphaType
pixel is opaque
Definition SkAlphaType.h:28
@ kPremul_SkAlphaType
pixel components are premultiplied by alpha
Definition SkAlphaType.h:29
#define SkASSERT(cond)
Definition SkAssert.h:116
static constexpr auto kAssumedColorType
const SkYUVAInfo & yuvaInfo() const
GrImageContext * context() const final
uint32_t uniqueID() const
Definition SkImage.h:311
bool hasAlpha() const
Definition SkYUVAInfo.h:185
SkISize dimensions() const
Definition SkYUVAInfo.h:171
Definition ref_ptr.h:256
static SkImageInfo Make(int width, int height, SkColorType ct, SkAlphaType at)

Member Function Documentation

◆ asFragmentProcessor()

std::unique_ptr< GrFragmentProcessor > SkImage_GaneshYUVA::asFragmentProcessor ( GrRecordingContext context,
SkSamplingOptions  sampling,
const SkTileMode  tileModes[2],
const SkMatrix m,
const SkRect subset,
const SkRect domain 
) const
overridevirtual

Implements SkImage_GaneshBase.

Definition at line 233 of file SkImage_GaneshYUVA.cpp.

239 {
240 if (!fContext->priv().matches(context)) {
241 return {};
242 }
243 // At least for now we do not attempt aniso filtering on YUVA images.
244 if (sampling.isAniso()) {
245 sampling =
246 SkSamplingPriv::AnisoFallback(fYUVAProxies.mipmapped() == skgpu::Mipmapped::kYes);
247 }
248
249 auto wmx = SkTileModeToWrapMode(tileModes[0]);
250 auto wmy = SkTileModeToWrapMode(tileModes[1]);
251 GrSamplerState sampler(wmx, wmy, sampling.filter, sampling.mipmap);
252 if (sampler.mipmapped() == skgpu::Mipmapped::kYes && !this->setupMipmapsForPlanes(context)) {
253 sampler = GrSamplerState(sampler.wrapModeX(),
254 sampler.wrapModeY(),
255 sampler.filter(),
256 GrSamplerState::MipmapMode::kNone);
257 }
258
259 const auto& yuvM = sampling.useCubic ? SkMatrix::I() : m;
261 fYUVAProxies, sampler, *context->priv().caps(), yuvM, subset, domain);
262 if (sampling.useCubic) {
263 fp = GrBicubicEffect::Make(std::move(fp),
264 this->alphaType(),
265 m,
268 }
269 if (fFromColorSpace) {
270 fp = GrColorSpaceXformEffect::Make(std::move(fp),
271 fFromColorSpace.get(),
272 this->alphaType(),
273 this->colorSpace(),
274 this->alphaType());
275 }
276 return fp;
277}
static constexpr GrSamplerState::WrapMode SkTileModeToWrapMode(SkTileMode tileMode)
Definition SkGr.h:77
bool matches(GrContext_Base *candidate) const
const GrCaps * caps() const
static std::unique_ptr< GrFragmentProcessor > Make(GrSurfaceProxyView view, SkAlphaType, const SkMatrix &, SkCubicResampler, Direction)
static std::unique_ptr< GrFragmentProcessor > Make(std::unique_ptr< GrFragmentProcessor > child, SkColorSpace *src, SkAlphaType srcAT, SkColorSpace *dst, SkAlphaType dstAT)
GrImageContextPriv priv()
skgpu::Mipmapped mipmapped() const
static std::unique_ptr< GrFragmentProcessor > Make(const GrYUVATextureProxies &yuvaProxies, GrSamplerState samplerState, const GrCaps &, const SkMatrix &localMatrix=SkMatrix::I(), const SkRect *subset=nullptr, const SkRect *domain=nullptr)
sk_sp< GrImageContext > fContext
SkAlphaType alphaType() const
Definition SkImage.cpp:154
static const SkMatrix & I()
static SkSamplingOptions AnisoFallback(bool imageIsMipped)
T * get() const
Definition SkRefCnt.h:303
SkSamplingOptions sampling
Definition SkRecords.h:337
const uint32_t fp
const SkCubicResampler cubic
const SkFilterMode filter
const SkMipmapMode mipmap

◆ asView()

std::tuple< GrSurfaceProxyView, GrColorType > SkImage_GaneshYUVA::asView ( GrRecordingContext rContext,
skgpu::Mipmapped  mipmapped,
GrImageTexGenPolicy   
) const
overridevirtual

Implements SkImage_GaneshBase.

Definition at line 201 of file SkImage_GaneshYUVA.cpp.

203 {
204 if (!fContext->priv().matches(rContext)) {
205 return {};
206 }
207 auto sfc = rContext->priv().makeSFC(this->imageInfo(),
208 "Image_GpuYUVA_ReinterpretColorSpace",
210 /*sample count*/ 1,
211 mipmapped,
212 GrProtected::kNo,
213 fYUVAProxies.textureOrigin(),
215 if (!sfc) {
216 return {};
217 }
218
219 const GrCaps& caps = *rContext->priv().caps();
220 auto fp = GrYUVtoRGBEffect::Make(fYUVAProxies, GrSamplerState::Filter::kNearest, caps);
221 if (fFromColorSpace) {
222 fp = GrColorSpaceXformEffect::Make(std::move(fp),
223 fFromColorSpace.get(),
224 this->alphaType(),
225 this->colorSpace(),
226 this->alphaType());
227 }
228 sfc->fillWithFP(std::move(fp));
229
230 return {sfc->readSurfaceView(), sfc->colorInfo().colorType()};
231}
std::unique_ptr< skgpu::ganesh::SurfaceFillContext > makeSFC(GrImageInfo, std::string_view label, SkBackingFit=SkBackingFit::kExact, int sampleCount=1, skgpu::Mipmapped=skgpu::Mipmapped::kNo, skgpu::Protected=skgpu::Protected::kNo, GrSurfaceOrigin=kTopLeft_GrSurfaceOrigin, skgpu::Budgeted=skgpu::Budgeted::kYes)
GrRecordingContextPriv priv()
GrSurfaceOrigin textureOrigin() const
const SkImageInfo & imageInfo() const
Definition SkImage.h:279

◆ flush()

GrSemaphoresSubmitted SkImage_GaneshYUVA::flush ( GrDirectContext dContext,
const GrFlushInfo info 
) const
overridevirtual

Implements SkImage_GaneshBase.

Definition at line 131 of file SkImage_GaneshYUVA.cpp.

132 {
133 if (!fContext->priv().matches(dContext) || dContext->abandoned()) {
134 if (info.fSubmittedProc) {
135 info.fSubmittedProc(info.fSubmittedContext, false);
136 }
137 if (info.fFinishedProc) {
138 info.fFinishedProc(info.fFinishedContext);
139 }
141 }
142
144 size_t numProxies = fYUVAProxies.numPlanes();
145 for (size_t i = 0; i < numProxies; ++i) {
146 proxies[i] = fYUVAProxies.proxy(i);
147 }
148 return dContext->priv().flushSurfaces(
149 {proxies, numProxies}, SkSurfaces::BackendSurfaceAccess::kNoAccess, info);
150}
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
Definition DM.cpp:213
GrSemaphoresSubmitted flushSurfaces(SkSpan< GrSurfaceProxy * >, SkSurfaces::BackendSurfaceAccess=SkSurfaces::BackendSurfaceAccess::kNoAccess, const GrFlushInfo &={}, const skgpu::MutableTextureState *newState=nullptr)
bool abandoned() override
GrDirectContextPriv priv()
GrSurfaceProxy * proxy(int i) const
static constexpr int kMaxPlanes
Definition SkYUVAInfo.h:98
@ kNoAccess
back-end surface will not be used by client

◆ onHasMipmaps()

bool SkImage_GaneshYUVA::onHasMipmaps ( ) const
overridevirtual

Implements SkImage_Base.

Definition at line 152 of file SkImage_GaneshYUVA.cpp.

152 {
153 return fYUVAProxies.mipmapped() == skgpu::Mipmapped::kYes;
154}

◆ onIsProtected()

bool SkImage_GaneshYUVA::onIsProtected ( ) const
overridevirtual

Implements SkImage_Base.

Definition at line 156 of file SkImage_GaneshYUVA.cpp.

156 {
157 skgpu::Protected isProtected = fYUVAProxies.proxy(0)->isProtected();
158
159#if defined(SK_DEBUG)
160 for (int i = 1; i < fYUVAProxies.numPlanes(); ++i) {
161 SkASSERT(isProtected == fYUVAProxies.proxy(i)->isProtected());
162 }
163#endif
164
165 return isProtected == skgpu::Protected::kYes;
166}
GrProtected isProtected() const
bool isProtected() const
Definition SkImage.cpp:294
Protected
Definition GpuTypes.h:61

◆ onMakeColorTypeAndColorSpace() [1/2]

virtual sk_sp< SkImage > SkImage_Base::onMakeColorTypeAndColorSpace ( SkColorType  ,
sk_sp< SkColorSpace ,
GrDirectContext  
) const
virtual

Reimplemented from SkImage_GaneshBase.

◆ onMakeColorTypeAndColorSpace() [2/2]

sk_sp< SkImage > SkImage_GaneshYUVA::onMakeColorTypeAndColorSpace ( SkColorType  ,
sk_sp< SkColorSpace targetCS,
GrDirectContext direct 
) const
finalvirtual

Reimplemented from SkImage_GaneshBase.

Definition at line 177 of file SkImage_GaneshYUVA.cpp.

179 {
180 // We explicitly ignore color type changes, for now.
181
182 // we may need a mutex here but for now we expect usage to be in a single thread
183 if (fOnMakeColorSpaceTarget &&
184 SkColorSpace::Equals(targetCS.get(), fOnMakeColorSpaceTarget.get())) {
185 return fOnMakeColorSpaceResult;
186 }
188 new SkImage_GaneshYUVA(sk_ref_sp(direct), this, targetCS, ColorSpaceMode::kConvert));
189 if (result) {
190 fOnMakeColorSpaceTarget = targetCS;
191 fOnMakeColorSpaceResult = result;
192 }
193 return result;
194}
sk_sp< T > sk_ref_sp(T *obj)
Definition SkRefCnt.h:381
static bool Equals(const SkColorSpace *, const SkColorSpace *)
GAsyncResult * result

◆ onReinterpretColorSpace()

sk_sp< SkImage > SkImage_GaneshYUVA::onReinterpretColorSpace ( sk_sp< SkColorSpace newCS) const
finalvirtual

Implements SkImage_Base.

Definition at line 196 of file SkImage_GaneshYUVA.cpp.

196 {
197 return sk_sp<SkImage>(
198 new SkImage_GaneshYUVA(fContext, this, std::move(newCS), ColorSpaceMode::kReinterpret));
199}

◆ origin()

GrSurfaceOrigin SkImage_GaneshYUVA::origin ( ) const
inlineoverridevirtual

Implements SkImage_GaneshBase.

Definition at line 85 of file SkImage_GaneshYUVA.h.

85{ return fYUVAProxies.textureOrigin(); }

◆ setupMipmapsForPlanes()

bool SkImage_GaneshYUVA::setupMipmapsForPlanes ( GrRecordingContext context) const

Definition at line 100 of file SkImage_GaneshYUVA.cpp.

100 {
101 if (!context || !fContext->priv().matches(context)) {
102 return false;
103 }
104 if (!context->priv().caps()->mipmapSupport()) {
105 // We succeed in this case by doing nothing.
106 return true;
107 }
108 int n = fYUVAProxies.yuvaInfo().numPlanes();
109 sk_sp<GrSurfaceProxy> newProxies[4];
110 for (int i = 0; i < n; ++i) {
111 auto* t = fYUVAProxies.proxy(i)->asTextureProxy();
112 if (t->mipmapped() == skgpu::Mipmapped::kNo && (t->width() > 1 || t->height() > 1)) {
113 auto newView = GrCopyBaseMipMapToView(context, fYUVAProxies.makeView(i));
114 if (!newView) {
115 return false;
116 }
117 SkASSERT(newView.swizzle() == fYUVAProxies.makeView(i).swizzle());
118 newProxies[i] = newView.detachProxy();
119 } else {
120 newProxies[i] = fYUVAProxies.refProxy(i);
121 }
122 }
123 fYUVAProxies =
124 GrYUVATextureProxies(fYUVAProxies.yuvaInfo(), newProxies, fYUVAProxies.textureOrigin());
125 SkASSERT(fYUVAProxies.isValid());
126 return true;
127}
GrSurfaceProxyView GrCopyBaseMipMapToView(GrRecordingContext *context, GrSurfaceProxyView src, skgpu::Budgeted budgeted)
Definition SkGr.cpp:136
bool mipmapSupport() const
Definition GrCaps.h:72
skgpu::Swizzle swizzle() const
virtual GrTextureProxy * asTextureProxy()
GrSurfaceProxyView makeView(int i) const
sk_sp< GrSurfaceProxy > refProxy(int i) const
int numPlanes() const
Definition SkYUVAInfo.h:204

◆ textureSize()

size_t SkImage_GaneshYUVA::textureSize ( ) const
overridevirtual

Returns an approximation of the amount of texture memory used by the image. Returns zero if the image is not texture backed or if the texture has an external format.

Reimplemented from SkImage_Base.

Definition at line 169 of file SkImage_GaneshYUVA.cpp.

169 {
170 size_t size = 0;
171 for (int i = 0; i < fYUVAProxies.numPlanes(); ++i) {
172 size += fYUVAProxies.proxy(i)->gpuMemorySize();
173 }
174 return size;
175}
size_t gpuMemorySize() const
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
Definition switches.h:259

◆ type()

SkImage_Base::Type SkImage_GaneshYUVA::type ( ) const
inlineoverridevirtual

Implements SkImage_Base.

Definition at line 58 of file SkImage_GaneshYUVA.h.


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