37#define ASSERT_SINGLE_OWNER SKGPU_ASSERT_SINGLE_OWNER(this->singleOwner())
38#define RETURN_FALSE_IF_ABANDONED if (this->fContext->abandoned()) { return false; }
39#define RETURN_NULLPTR_IF_ABANDONED if (this->fContext->abandoned()) { return nullptr; }
72 SkDEBUGCODE(this->validate();)
83 if (
dst.rowBytes() %
dst.info().bpp()) {
88 if (!
dst.hasPixels()) {
112 bool unpremul =
flags.unpremul,
113 needColorConversion =
flags.linearize ||
flags.gamut_transform ||
flags.encode,
126 bool canvas2DFastPath = unpremul && !needColorConversion &&
146 std::unique_ptr<SurfaceContext> tempCtx;
149 if (canvas2DFastPath || srcIsCompressed) {
154 if (!backendFormat.
isValid()) {
171 std::unique_ptr<GrFragmentProcessor>
fp;
172 if (canvas2DFastPath) {
191 tempCtx = std::move(sfc);
199 if (restrictions.fMustCopyWholeSrc) {
206 "SurfaceContext_ReadPixelsWithCopyWholeSrc");
216 "SurfaceContext_ReadPixels",
217 restrictions.fRectsMustMatch);
227 return tempCtx->readPixels(dContext,
dst, pt);
238 bool convert = unpremul ||
premul || needColorConversion || flip || makeTight ||
239 (
dst.colorType() != supportedRead.fColorType);
241 std::unique_ptr<char[]> tmpPixels;
243 void* readDst =
dst.addr();
244 size_t readRB =
dst.rowBytes();
247 this->colorInfo().alphaType(),
248 this->colorInfo().refColorSpace(),
253 tmpPixels = std::make_unique<char[]>(
size);
254 tmp = {tmpInfo, tmpPixels.get(), tmpRB};
256 readDst = tmpPixels.get();
265 this->colorInfo().colorType(),
266 supportedRead.fColorType,
283 SkDEBUGCODE(this->validate();)
285 src =
src.clip(this->dimensions(), &dstPt);
286 if (!
src.hasPixels()) {
289 if (!
src.info().bpp() ||
src.rowBytes() %
src.info().bpp()) {
292 return this->internalWritePixels(dContext, &
src, 1, dstPt);
300 SkDEBUGCODE(this->validate();)
306 if (numLevels == 1) {
307 if (
src->dimensions() != this->dimensions()) {
321 for (
int i = 0;
i < numLevels; ++
i) {
333 return this->internalWritePixels(dContext,
src, numLevels, {0, 0});
383 bool unpremul =
flags.unpremul,
384 needColorConversion =
flags.linearize ||
flags.gamut_transform ||
flags.encode,
401 rgbaDefaultFormat.isValid() &&
415 if (canvas2DFastPath) {
419 format = rgbaDefaultFormat;
445 "SurfaceContext_InternalWritePixels");
458 if (canvas2DFastPath) {
463 if (!tempCtx.writePixels(dContext, srcBase, {0, 0})) {
468 std::unique_ptr<GrFragmentProcessor>
fp;
469 if (canvas2DFastPath) {
489 if (!this->
copy(std::move(tempProxy), srcRect, dstPoint)) {
497 auto [allowedColorType, _] =
503 bool convertAll =
premul ||
505 needColorConversion ||
507 (srcColorType != allowedColorType);
510 if (mustBeTight || convertAll) {
511 for (
int i = 0;
i < numLevels; ++
i) {
512 if (convertAll || (mustBeTight &&
src[
i].rowBytes() !=
src[
i].
info().minRowBytes())) {
513 tmpSize +=
src[
i].info().makeColorType(allowedColorType).minRowBytes()*
520 void* tmp = tmpSize ? tmpData->writable_data() :
nullptr;
522 bool ownAllStorage =
true;
523 for (
int i = 0;
i < numLevels; ++
i) {
524 if (convertAll || (mustBeTight &&
src[
i].rowBytes() !=
src[
i].
info().minRowBytes())) {
529 auto tmpRB = tmpInfo.minRowBytes();
530 GrPixmap tmpPM(tmpInfo, tmp, tmpRB);
532 srcLevels[
i] = {tmpPM.addr(), tmpPM.rowBytes(), tmpData};
533 tmp = SkTAddOffset<void>(tmp, tmpRB*tmpPM.height());
535 srcLevels[
i] = {
src[
i].addr(),
src[
i].rowBytes(),
src[
i].pixelStorage()};
536 ownAllStorage &=
src[
i].ownsPixels();
553 if (!ownAllStorage) {
573 if (rt && rt->wrapsVkSecondaryCB()) {
577 if (rt && rt->framebufferOnly()) {
586 bool needsRescale = srcRect.
size() !=
info.dimensions() ||
592 surfaceBackendFormat,
604 if ((~legalReadChannels & dstChannels) & srcChannels) {
609 std::unique_ptr<SurfaceFillContext> tempFC;
611 int y = srcRect.
fTop;
615 rescaleGamma, rescaleMode);
624 auto srcCtx = tempFC ? tempFC.get() :
this;
625 return srcCtx->asyncReadPixels(dContext,
652 if (!transferResult.fTransferBuffer) {
654 this->colorInfo().refColorSpace());
669 struct FinishContext {
679 auto* finishContext =
new FinishContext{
callback,
683 std::move(transferResult)};
685 const auto* context =
reinterpret_cast<const FinishContext*
>(c);
686 auto manager = context->fMappedBufferManager;
687 auto result = std::make_unique<AsyncReadResult>(
manager->ownerID());
688 if (!
result->addTransferResult(context->fTransferResult,
690 context->fTransferResult.fRowBytes,
694 (*context->fClientCallback)(context->fClientContext, std::move(
result));
728 if (rt && rt->wrapsVkSecondaryCB()) {
732 if (rt && rt->framebufferOnly()) {
741 int y = srcRect.
fTop;
742 bool needsRescale = srcRect.
size() != dstSize ||
763 srcView = tempFC->readSurfaceView();
772 "SurfaceContext_AsyncRescaleAndReadPixelsYUV420");
786 std::unique_ptr<SurfaceFillContext> aFC;
793 auto uvInfo = yaInfo.makeWH(yaInfo.width()/2, yaInfo.height()/2);
801 if (!yFC || !uFC || !vFC || (readAlpha && !aFC)) {
813 auto [readCT, offsetAlignment] =
815 yFC->asSurfaceProxy()->backendFormat(),
827 std::fill_n(yM, 15, 0.f);
828 std::copy_n(baseM + 0, 5, yM + 15);
836 yFC->fillWithFP(std::move(yFP));
837 if (!doSynchronousRead) {
853 aFC->fillWithFP(std::move(aFP));
854 if (!doSynchronousRead) {
864 texMatrix.preScale(2.f, 2.f);
867 std::fill_n(uM, 15, 0.f);
868 std::copy_n(baseM + 5, 5, uM + 15);
879 uFC->fillWithFP(std::move(uFP));
880 if (!doSynchronousRead) {
891 std::fill_n(vM, 15, 0.f);
892 std::copy_n(baseM + 10, 5, vM + 15);
902 vFC->fillWithFP(std::move(vFP));
904 if (!doSynchronousRead) {
913 if (doSynchronousRead) {
921 if (!yFC->readPixels(dContext, yPmp, {0, 0}) ||
922 !uFC->readPixels(dContext, uPmp, {0, 0}) ||
923 !vFC->readPixels(dContext, vPmp, {0, 0}) ||
924 (readAlpha && !aFC->readPixels(dContext, aPmp, {0, 0}))) {
939 struct FinishContext {
952 auto* finishContext =
new FinishContext{
callback,
956 std::move(yTransfer),
957 std::move(uTransfer),
958 std::move(vTransfer),
959 std::move(aTransfer)};
961 const auto* context =
reinterpret_cast<const FinishContext*
>(c);
962 auto manager = context->fMappedBufferManager;
963 auto result = std::make_unique<AsyncReadResult>(
manager->ownerID());
964 if (!
result->addTransferResult(context->fYTransfer,
966 context->fYTransfer.fRowBytes,
968 (*context->fClientCallback)(context->fClientContext,
nullptr);
972 SkISize uvSize = {context->fSize.
width() / 2, context->fSize.height() / 2};
973 if (!
result->addTransferResult(context->fUTransfer,
975 context->fUTransfer.fRowBytes,
977 (*context->fClientCallback)(context->fClientContext,
nullptr);
981 if (!
result->addTransferResult(context->fVTransfer,
983 context->fVTransfer.fRowBytes,
985 (*context->fClientCallback)(context->fClientContext,
nullptr);
989 if (context->fATransfer.fTransferBuffer &&
990 !
result->addTransferResult(context->fATransfer,
992 context->fATransfer.fRowBytes,
994 (*context->fClientCallback)(context->fClientContext,
nullptr);
998 (*context->fClientCallback)(context->fClientContext, std::move(
result));
1012 src->dimensions(), &srcRect)) {
1026 SkDEBUGCODE(this->validate();)
1050#if defined(SK_USE_SAFE_INSET_FOR_TEXTURE_SAMPLING)
1051 const bool upscalingXAtApproxEdge =
1054 srcRect.
fRight <
src->backingStoreDimensions().width();
1055 const bool upscalingYAtApproxEdge =
1058 srcRect.
fBottom <
src->backingStoreDimensions().height();
1062 const bool upscalingXAtApproxEdge =
1065 srcRect.
fRight <
src->backingStoreDimensions().width();
1066 const bool upscalingYAtApproxEdge =
1069 srcRect.
fBottom <
src->backingStoreDimensions().height();
1071 if (upscalingXAtApproxEdge || upscalingYAtApproxEdge) {
1080 SkASSERT(
src->backendFormat() == this->asSurfaceProxy()->backendFormat());
1121 if (rtProxy && rtProxy->wrapsVkSecondaryCB()) {
1142 "SurfaceContext_RescaleInto");
1148 return std::make_pair(std::move(texView), srcRect);
1152 if (finalSize == srcRect.
size()) {
1159 std::unique_ptr<SurfaceFillContext> tempA;
1160 std::unique_ptr<SurfaceFillContext> tempB;
1165 !this->
colorInfo().colorSpace()->gammaIsLinear()) {
1167 std::tie(texView, srcRect) = ensureTexturable(texView, srcRect);
1174 dst->colorInfo().alphaType(),
1193 linearRTC->colorInfo());
1194 linearRTC->fillWithFP(std::move(
fp));
1195 texView = linearRTC->readSurfaceView();
1197 tempA = std::move(linearRTC);
1206 }
else if (srcRect.
width() < finalSize.
width()) {
1215 auto input = tempA ? tempA.get() :
this;
1219 if (nextDims == finalSize) {
1221 stepDstRect = dstRect;
1224 GrImageInfo nextInfo(input->colorInfo(), nextDims);
1233 stepDst = tempB.get();
1236 std::unique_ptr<GrFragmentProcessor>
fp;
1239 std::tie(texView, srcRect) = ensureTexturable(texView, srcRect);
1252 input->colorInfo().alphaType(),
1265 !stepDst->copyScaled(texView.
refProxy(), srcRect, stepDstRect, filter)) {
1268 std::tie(texView, srcRect) = ensureTexturable(texView, srcRect);
1292 tempA = std::move(tempB);
1294 }
while (srcRect.
size() != finalSize);
1307 if (rtProxy && rtProxy->wrapsVkSecondaryCB()) {
1313 proxy->backendFormat(), dstCT);
1319 if ((~legalReadChannels & dstChannels) & srcChannels) {
1323 if (!this->
caps()->transferFromSurfaceToBufferSupport() ||
1324 !supportedRead.fOffsetAlignmentForTransferBuffer) {
1329 rowBytes =
SkAlignTo(rowBytes, this->
caps()->transferBufferRowBytesAlignment());
1330 size_t size = rowBytes *
rect.height();
1334 auto buffer = direct->priv().resourceProvider()->createBuffer(
1342 auto srcRect =
rect;
1346 this->height() -
rect.fTop);
1350 supportedRead.fColorType,
buffer, 0);
1354 if (supportedRead.fColorType != dstCT || flip) {
1356 GrImageInfo srcInfo(supportedRead.fColorType, at,
nullptr,
w,
h);
1359 result.fPixelConverter = [dstInfo, srcInfo, rowBytes](
1360 void*
dst,
const void*
src) {
1365 result.fRowBytes = rowBytes;
1371void SurfaceContext::validate()
const {
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
SkAssertResult(font.textToGlyphs("Hello", 5, SkTextEncoding::kUTF8, glyphs, std::size(glyphs))==count)
bool GrConvertPixels(const GrPixmap &dst, const GrCPixmap &src, bool flipY)
static bool GrClipSrcRectAndDstPoint(const SkISize &dstSize, SkIPoint *dstPoint, const SkISize &srcSize, SkIRect *srcRect)
#define GR_CREATE_TRACE_MARKER_CONTEXT(classname, op, context)
static constexpr uint32_t GrColorTypeChannelFlags(GrColorType ct)
static constexpr size_t GrColorTypeBytesPerPixel(GrColorType ct)
@ kStream_GrAccessPattern
static constexpr GrColorType SkColorTypeToGrColorType(SkColorType ct)
@ kBottomLeft_GrSurfaceOrigin
@ kTopLeft_GrSurfaceOrigin
void * GrGpuFinishedContext
static constexpr size_t SkAlignTo(size_t x, size_t alignment)
@ kUnknown_SkAlphaType
uninitialized
@ kRGBA_8888_SkColorType
pixel with 8 bits for red, green, blue, alpha; in 32-bit word
static SkColorType colorType(AImageDecoder *decoder, const AImageDecoderHeaderInfo *headerInfo)
sk_sp< T > sk_ref_sp(T *obj)
static void copy(void *dst, const uint8_t *src, int width, int bpp, int deltaSrc, int offset, const SkPMColor ctable[])
static constexpr bool SkToBool(const T &x)
void SkColorMatrix_RGB2YUV(SkYUVColorSpace cs, float m[20])
#define RETURN_FALSE_IF_ABANDONED
#define RETURN_NULLPTR_IF_ABANDONED
#define ASSERT_SINGLE_OWNER
static uint32_t premul(uint32_t color)
bool matches(GrContext_Base *candidate) const
const GrCaps * caps() const
static constexpr SkCubicResampler gCatmullRom
static std::unique_ptr< GrFragmentProcessor > MakeSubset(GrSurfaceProxyView view, SkAlphaType, const SkMatrix &, const GrSamplerState::WrapMode wrapX, const GrSamplerState::WrapMode wrapY, const SkRect &subset, SkCubicResampler, Direction, const GrCaps &)
bool avoidWritePixelsFastPath() const
virtual SupportedWrite supportedWritePixelsColorType(GrColorType surfaceColorType, const GrBackendFormat &surfaceFormat, GrColorType srcColorType) const =0
bool surfaceSupportsWritePixels(const GrSurface *) const
virtual SurfaceReadPixelsSupport surfaceSupportsReadPixels(const GrSurface *) const =0
virtual DstCopyRestrictions getDstCopyRestrictions(const GrRenderTargetProxy *src, GrColorType ct) const
bool areColorTypeAndFormatCompatible(GrColorType grCT, const GrBackendFormat &format) const
GrBackendFormat getDefaultBackendFormat(GrColorType, GrRenderable) const
bool isFormatCompressed(const GrBackendFormat &format) const
SupportedRead supportedReadPixelsColorType(GrColorType srcColorType, const GrBackendFormat &srcFormat, GrColorType dstColorType) const
bool canCopySurface(const GrSurfaceProxy *dst, const SkIRect &dstRect, const GrSurfaceProxy *src, const SkIRect &srcRect) const
bool readPixelsRowBytesSupport() const
bool writePixelsRowBytesSupport() const
bool transferFromSurfaceToBufferSupport() const
sk_sp< SkColorSpace > refColorSpace() const
SkColorSpace * colorSpace() const
GrColorType colorType() const
SkAlphaType alphaType() const
virtual GrDirectContext * asDirectContext()
GrSemaphoresSubmitted flushSurface(GrSurfaceProxy *proxy, SkSurfaces::BackendSurfaceAccess access=SkSurfaces::BackendSurfaceAccess::kNoAccess, const GrFlushInfo &info={}, const skgpu::MutableTextureState *newState=nullptr)
GrResourceProvider * resourceProvider()
std::unique_ptr< GrFragmentProcessor > createPMToUPMEffect(std::unique_ptr< GrFragmentProcessor >)
std::unique_ptr< GrFragmentProcessor > createUPMToPMEffect(std::unique_ptr< GrFragmentProcessor >)
GrClientMappedBufferManager * clientMappedBufferManager()
bool validPMUPMConversionExists()
bool submit(GrSyncCpu sync=GrSyncCpu::kNo)
DirectContextID directContextID() const
GrDirectContextPriv priv()
void newTransferFromRenderTask(const sk_sp< GrSurfaceProxy > &srcProxy, const SkIRect &srcRect, GrColorType surfaceColorType, GrColorType dstColorType, sk_sp< GrGpuBuffer > dstBuffer, size_t dstOffset)
sk_sp< GrRenderTask > newCopyRenderTask(sk_sp< GrSurfaceProxy > dst, SkIRect dstRect, const sk_sp< GrSurfaceProxy > &src, SkIRect srcRect, GrSamplerState::Filter filter, GrSurfaceOrigin)
bool newWritePixelsTask(sk_sp< GrSurfaceProxy > dst, SkIRect rect, GrColorType srcColorType, GrColorType dstColorType, const GrMipLevel[], int levelCount)
static std::unique_ptr< GrFragmentProcessor > SwizzleOutput(std::unique_ptr< GrFragmentProcessor >, const skgpu::Swizzle &)
static std::unique_ptr< GrFragmentProcessor > ColorMatrix(std::unique_ptr< GrFragmentProcessor > child, const float matrix[20], bool unpremulInput, bool clampRGBOutput, bool premulOutput)
bool readPixels(GrSurface *surface, SkIRect rect, GrColorType surfaceColorType, GrColorType dstColorType, void *buffer, size_t rowBytes)
GrImageInfo makeColorType(GrColorType ct) const
size_t minRowBytes() const
sk_sp< SkData > pixelStorage() const
const GrImageInfo & info() const
SkISize dimensions() const
GrColorType colorType() const
static GrPixmap Allocate(const GrImageInfo &info)
sk_sp< GrTextureProxy > createProxy(const GrBackendFormat &, SkISize dimensions, GrRenderable, int renderTargetSampleCnt, skgpu::Mipmapped, SkBackingFit, skgpu::Budgeted, GrProtected, std::string_view label, GrInternalSurfaceFlags=GrInternalSurfaceFlags::kNone, UseAllocator useAllocator=UseAllocator::kYes)
GrDrawingManager * drawingManager()
GrProxyProvider * proxyProvider()
std::unique_ptr< skgpu::ganesh::SurfaceFillContext > makeSFCWithFallback(GrImageInfo, SkBackingFit, int sampleCount, skgpu::Mipmapped, skgpu::Protected, GrSurfaceOrigin=kTopLeft_GrSurfaceOrigin, skgpu::Budgeted=skgpu::Budgeted::kYes)
std::unique_ptr< skgpu::ganesh::SurfaceContext > makeSC(GrSurfaceProxyView readView, const GrColorInfo &)
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()
bool abandoned() override
GrTextureProxy * asTextureProxy() const
GrSurfaceOrigin origin() const
GrSurfaceProxy * proxy() const
sk_sp< GrSurfaceProxy > refProxy() const
static GrSurfaceProxyView Copy(GrRecordingContext *context, GrSurfaceProxyView src, skgpu::Mipmapped mipmapped, SkIRect srcRect, SkBackingFit fit, skgpu::Budgeted budgeted, std::string_view label)
GrProtected isProtected() const
const GrBackendFormat & backendFormat() const
virtual bool instantiate(GrResourceProvider *)=0
bool framebufferOnly() const
static sk_sp< GrSurfaceProxy > Copy(GrRecordingContext *, sk_sp< GrSurfaceProxy > src, GrSurfaceOrigin, skgpu::Mipmapped, SkIRect srcRect, SkBackingFit, skgpu::Budgeted, std::string_view label, RectsMustMatch=RectsMustMatch::kNo, sk_sp< GrRenderTask > *outTask=nullptr)
virtual GrTextureProxy * asTextureProxy()
GrSurface * peekSurface() const
virtual GrBackendFormat backendFormat() const =0
static std::unique_ptr< GrFragmentProcessor > MakeSubset(GrSurfaceProxyView, SkAlphaType, const SkMatrix &, GrSamplerState, const SkRect &subset, const GrCaps &caps, const float border[4]=kDefaultBorder, bool alwaysUseShaderTileMode=false)
static std::unique_ptr< GrFragmentProcessor > Make(GrSurfaceProxyView, SkAlphaType, const SkMatrix &=SkMatrix::I(), GrSamplerState::Filter=GrSamplerState::Filter::kNearest, GrSamplerState::MipmapMode mipmapMode=GrSamplerState::MipmapMode::kNone)
static bool Equals(const SkColorSpace *, const SkColorSpace *)
sk_sp< SkColorSpace > makeLinearGamma() const
static sk_sp< SkData > MakeUninitialized(size_t length)
static SkMatrix Translate(SkScalar dx, SkScalar dy)
static const SkMatrix & I()
static int ComputeLevelCount(int baseWidth, int baseHeight)
static constexpr Swizzle BGRA()
PixelTransferResult transferPixels(GrColorType colorType, const SkIRect &rect)
GrSurfaceProxy * asSurfaceProxy()
GrDrawingManager * drawingManager()
bool readPixels(GrDirectContext *dContext, GrPixmap dst, SkIPoint srcPt)
SkDEBUGCODE(void validate() const ;) SkDEBUGCODE(skgpu GrRecordingContext * fContext
SkISize dimensions() const
bool writePixels(GrDirectContext *dContext, GrCPixmap src, SkIPoint dstPt)
GrRenderTargetProxy * asRenderTargetProxy()
bool rescaleInto(SurfaceFillContext *dst, SkIRect dstRect, SkIRect srcRect, SkImage::RescaleGamma, SkImage::RescaleMode)
const GrCaps * caps() const
SkImage::ReadPixelsCallback ReadPixelsCallback
const GrColorInfo & colorInfo() const
GrSurfaceProxyView fReadView
GrTextureProxy * asTextureProxy()
void asyncRescaleAndReadPixels(GrDirectContext *, const SkImageInfo &info, const SkIRect &srcRect, RescaleGamma rescaleGamma, RescaleMode, ReadPixelsCallback callback, ReadPixelsContext callbackContext)
skgpu::Mipmapped mipmapped() const
GrSurfaceProxyView readSurfaceView()
SurfaceContext(GrRecordingContext *, GrSurfaceProxyView readView, const GrColorInfo &)
void asyncRescaleAndReadPixelsYUV420(GrDirectContext *, SkYUVColorSpace yuvColorSpace, bool readAlpha, sk_sp< SkColorSpace > dstColorSpace, const SkIRect &srcRect, SkISize dstSize, RescaleGamma rescaleGamma, RescaleMode, ReadPixelsCallback callback, ReadPixelsContext context)
void asyncReadPixels(GrDirectContext *, const SkIRect &srcRect, SkColorType, ReadPixelsCallback, ReadPixelsContext)
skgpu::Swizzle readSwizzle() const
SkImage::ReadPixelsContext ReadPixelsContext
std::unique_ptr< SurfaceFillContext > rescale(const GrImageInfo &info, GrSurfaceOrigin, SkIRect srcRect, SkImage::RescaleGamma, SkImage::RescaleMode)
virtual SurfaceFillContext * asFillContext()
sk_sp< GrSurfaceProxy > asSurfaceProxyRef()
GrSurfaceOrigin origin() const
void fillRectToRectWithFP(const SkRect &srcRect, const SkIRect &dstRect, std::unique_ptr< GrFragmentProcessor > fp)
static Editor::Movement convert(skui::Key key)
FlutterSemanticsFlag flags
FlKeyEvent uint64_t FlKeyResponderAsyncCallback callback
uint32_t uint32_t * format
static float max(float r, float g, float b)
static float min(float r, float g, float b)
sk_sp< SkBlender > blender SkRect rect
@ kNoAccess
back-end surface will not be used by client
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 manager
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace Enable an endless trace buffer The default is a ring buffer This is useful when very old events need to viewed For during application launch Memory usage will continue to grow indefinitely however Start app with an specific route defined on the framework flutter assets dir
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace buffer
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
static bool alpha_types_compatible(SkAlphaType srcAlphaType, SkAlphaType dstAlphaType)
constexpr bool contains(std::string_view str, std::string_view needle)
GrGpuFinishedContext fFinishedContext
GrGpuFinishedProc fFinishedProc
static constexpr SkIPoint Make(int32_t x, int32_t y)
int32_t fBottom
larger y-axis bounds
static constexpr SkIRect MakeLTRB(int32_t l, int32_t t, int32_t r, int32_t b)
constexpr SkISize size() const
constexpr int32_t height() const
int32_t fTop
smaller y-axis bounds
static constexpr SkIRect MakeSize(const SkISize &size)
constexpr int32_t width() const
constexpr SkIPoint topLeft() const
int32_t fLeft
smaller x-axis bounds
static constexpr SkIRect MakePtSize(SkIPoint pt, SkISize size)
bool contains(int32_t x, int32_t y) const
int32_t fRight
larger x-axis bounds
constexpr int32_t width() const
constexpr int32_t height() const
static SkImageInfo Make(int width, int height, SkColorType ct, SkAlphaType at)
SkAlphaType alphaType() const
static SkImageInfo MakeA8(int width, int height)
static SkRect Make(const SkISize &size)
sk_sp< GrGpuBuffer > fTransferBuffer