Home
last modified time | relevance | path

Searched refs:rowBytes (Results 1 - 25 of 265) sorted by relevance

1234567891011

/third_party/skia/src/gpu/
H A DGrPixmap.h21 size_t rowBytes() const { return fRowBytes; } in rowBytes() function in GrPixmapBase
63 GrPixmapBase(GrImageInfo info, T* addr, size_t rowBytes) in GrPixmapBase() argument
64 : fAddr(addr), fRowBytes(rowBytes), fInfo(std::move(info)) { in GrPixmapBase()
70 GrPixmapBase(GrImageInfo info, sk_sp<SkData> storage, size_t rowBytes) in GrPixmapBase() argument
71 : GrPixmapBase(std::move(info), const_cast<void*>(storage->data()), rowBytes) { in GrPixmapBase()
91 GrPixmap(GrImageInfo info, void* addr, size_t rowBytes) : GrPixmapBase(info, addr, rowBytes) {} in GrPixmap() argument
94 : GrPixmapBase(pixmap.info(), pixmap.writable_addr(), pixmap.rowBytes()) {} in GrPixmap()
110 GrPixmap(GrImageInfo info, sk_sp<SkData> storage, size_t rowBytes) in GrPixmap() argument
111 : GrPixmapBase(std::move(info), std::move(storage), rowBytes) {} in GrPixmap()
137 GrCPixmap(GrImageInfo info, const void* addr, size_t rowBytes) GrCPixmap() argument
141 GrCPixmap(GrImageInfo info, sk_sp<SkData> storage, size_t rowBytes) GrCPixmap() argument
[all...]
H A DSurfaceContext.cpp79 if (dst.rowBytes() % dst.info().bpp()) { in readPixels()
166 dst.rowBytes()); in readPixels()
221 !caps->readPixelsRowBytesSupport() && dst.rowBytes() != dst.info().minRowBytes(); in readPixels()
229 size_t readRB = dst.rowBytes(); in readPixels()
274 if (!src.info().bpp() || src.rowBytes() % src.info().bpp()) { in writePixels()
312 if (!src[i].info().bpp() || src[i].rowBytes() % src[i].info().bpp()) { in writePixels()
443 origSrcBase.rowBytes()); in internalWritePixels()
494 if (convertAll || (mustBeTight && src[i].rowBytes() != src[i].info().minRowBytes())) { in internalWritePixels()
506 if (convertAll || (mustBeTight && src[i].rowBytes() != src[i].info().minRowBytes())) { in internalWritePixels()
514 srcLevels[i] = {tmpPM.addr(), tmpPM.rowBytes(), tmpDat in internalWritePixels()
634 addTransferResult(const PixelTransferResult& result, SkISize dimensions, size_t rowBytes, GrClientMappedBufferManager* manager) addTransferResult() argument
647 this->addCpuPlane(std::move(data), rowBytes); addTransferResult() local
656 addCpuPlane(sk_sp<SkData> data, size_t rowBytes) addCpuPlane() argument
659 fPlanes.emplace_back(std::move(data), rowBytes); addCpuPlane() local
663 addMappedPlane(const void* data, size_t rowBytes, sk_sp<GrGpuBuffer> mappedBuffer) addMappedPlane() argument
668 fPlanes.emplace_back(std::move(mappedBuffer), rowBytes); addMappedPlane() local
673 Plane(sk_sp<GrGpuBuffer> buffer, size_t rowBytes) Plane() argument
675 Plane(sk_sp<SkData> data, size_t rowBytes) Plane() argument
702 size_t rowBytes() const { return fRowBytes; } rowBytes() function in skgpu::SurfaceContext::AsyncReadResult::Plane
1264 size_t rowBytes = GrColorTypeBytesPerPixel(supportedRead.fColorType) * rect.width(); transferPixels() local
[all...]
/third_party/skia/src/core/
H A DSkBitmap.cpp107 bool SkBitmap::setInfo(const SkImageInfo& info, size_t rowBytes) { in setInfo() argument
114 // require that rowBytes fit in 31bits in setInfo()
119 if (!SkTFitsIn<int32_t>(rowBytes)) { in setInfo()
128 rowBytes = 0; in setInfo()
129 } else if (0 == rowBytes) { in setInfo()
130 rowBytes = (size_t)mrb; in setInfo()
131 } else if (!info.validRowBytes(rowBytes)) { in setInfo()
136 fPixmap.reset(info.makeAlphaType(newAT), nullptr, SkToU32(rowBytes)); in setInfo()
149 fPixmap.reset(std::move(newInfo), fPixmap.addr(), fPixmap.rowBytes()); in setAlphaType()
158 size_t rb = this->rowBytes(); in pixelRefOrigin()
180 size_t rowBytes = this->rowBytes(); setPixelRef() local
242 allocPixels(const SkImageInfo& info, size_t rowBytes) allocPixels() argument
252 tryAllocPixels(const SkImageInfo& requestedInfo, size_t rowBytes) tryAllocPixels() argument
[all...]
H A DSkMallocPixelRef.cpp24 sk_sp<SkPixelRef> SkMallocPixelRef::MakeAllocate(const SkImageInfo& info, size_t rowBytes) { in MakeAllocate() argument
25 if (rowBytes == 0) { in MakeAllocate()
26 rowBytes = info.minRowBytes(); in MakeAllocate()
27 // rowBytes can still be zero, if it overflowed (width * bytesPerPixel > size_t) in MakeAllocate()
30 if (!is_valid(info) || !info.validRowBytes(rowBytes)) { in MakeAllocate()
33 size_t size = info.computeByteSize(rowBytes); in MakeAllocate()
51 return sk_sp<SkPixelRef>(new PixelRef(info.width(), info.height(), addr, rowBytes)); in MakeAllocate()
55 size_t rowBytes, in MakeWithData()
64 if ((rowBytes < info.minRowBytes()) || (data->size() < info.computeByteSize(rowBytes))) { in MakeWithData()
54 MakeWithData(const SkImageInfo& info, size_t rowBytes, sk_sp<SkData> data) MakeWithData() argument
[all...]
H A DSkYUVAPixmaps.cpp80 const size_t rowBytes[kMaxPlanes]) in SkYUVAPixmapInfo()
90 if (!rowBytes) { in SkYUVAPixmapInfo()
94 rowBytes = tempRowBytes; in SkYUVAPixmapInfo()
98 fRowBytes[i] = rowBytes[i]; in SkYUVAPixmapInfo()
121 const size_t rowBytes[kMaxPlanes]) { in SkYUVAPixmapInfo()
128 *this = SkYUVAPixmapInfo(yuvaInfo, colorTypes, rowBytes); in SkYUVAPixmapInfo()
160 size_t planeSize = pixmaps[i].rowBytes()*pixmaps[i].height(); in initPixmapsFromSingleAllocation()
221 d.rowBytes(), in MakeCopy()
223 s.rowBytes(), in MakeCopy()
243 size_t rowBytes[kMaxPlane in FromExternalPixmaps() local
78 SkYUVAPixmapInfo(const SkYUVAInfo& yuvaInfo, const SkColorType colorTypes[kMaxPlanes], const size_t rowBytes[kMaxPlanes]) SkYUVAPixmapInfo() argument
119 SkYUVAPixmapInfo(const SkYUVAInfo& yuvaInfo, DataType dataType, const size_t rowBytes[kMaxPlanes]) SkYUVAPixmapInfo() argument
278 size_t rowBytes[kMaxPlanes] = {}; pixmapsInfo() local
[all...]
H A DSkOpts_erms.cpp73 size_t rowBytes, int height) { in rect_memset16()
75 return g_rect_memset16_prev(dst,v,n, rowBytes,height); in rect_memset16()
77 for (int stride = rowBytes/sizeof(v); height --> 0; dst += stride) { in rect_memset16()
82 size_t rowBytes, int height) { in rect_memset32()
84 return g_rect_memset32_prev(dst,v,n, rowBytes,height); in rect_memset32()
86 for (int stride = rowBytes/sizeof(v); height --> 0; dst += stride) { in rect_memset32()
91 size_t rowBytes, int height) { in rect_memset64()
93 return g_rect_memset64_prev(dst,v,n, rowBytes,height); in rect_memset64()
95 for (int stride = rowBytes/sizeof(v); height --> 0; dst += stride) { in rect_memset64()
72 rect_memset16(uint16_t* dst, uint16_t v, int n, size_t rowBytes, int height) rect_memset16() argument
81 rect_memset32(uint32_t* dst, uint32_t v, int n, size_t rowBytes, int height) rect_memset32() argument
90 rect_memset64(uint64_t* dst, uint64_t v, int n, size_t rowBytes, int height) rect_memset64() argument
H A DSkPixelRef.cpp30 SkPixelRef::SkPixelRef(int width, int height, void* pixels, size_t rowBytes) in SkPixelRef() argument
34 , fRowBytes(rowBytes) in SkPixelRef()
46 void SkPixelRef::android_only_reset(int width, int height, size_t rowBytes) { in android_only_reset() argument
49 fRowBytes = rowBytes; in android_only_reset()
135 sk_sp<SkPixelRef> SkMakePixelRefWithProc(int width, int height, size_t rowBytes, void* addr, in SkMakePixelRefWithProc() argument
139 return sk_make_sp<SkPixelRef>(width, height, addr, rowBytes); in SkMakePixelRefWithProc()
148 return sk_sp<SkPixelRef>(new PixelRef(width, height, addr, rowBytes, releaseProc, ctx)); in SkMakePixelRefWithProc()
/third_party/skia/tests/
H A DMallocPixelRefTest.cpp32 size_t rowBytes = info.minRowBytes() - 1; in DEF_TEST() local
33 size_t size = info.computeByteSize(rowBytes); in DEF_TEST()
36 SkMallocPixelRef::MakeWithData(info, rowBytes, data)); in DEF_TEST()
41 size_t rowBytes = info.minRowBytes() + info.bytesPerPixel(); in DEF_TEST() local
42 size_t size = info.computeByteSize(rowBytes) - 1; in DEF_TEST()
45 SkMallocPixelRef::MakeWithData(info, rowBytes, data)); in DEF_TEST()
49 size_t rowBytes = info.minRowBytes() + info.bytesPerPixel(); in DEF_TEST() local
50 size_t size = info.computeByteSize(rowBytes) + 9; in DEF_TEST()
53 auto pr = sk_make_sp<SkPixelRef>(info.width(), info.height(), memory.get(), rowBytes); in DEF_TEST()
59 SkMallocPixelRef::MakeAllocate(info, rowBytes)); in DEF_TEST()
[all...]
/third_party/skia/src/codec/
H A DSkSampledCodec.cpp75 size_t rowBytes, const AndroidOptions& options) { in onGetAndroidPixels()
79 return this->codec()->getPixels(info, pixels, rowBytes, &options); in onGetAndroidPixels()
83 return this->sampledDecode(info, pixels, rowBytes, options); in onGetAndroidPixels()
91 return this->sampledDecode(info, pixels, rowBytes, options); in onGetAndroidPixels()
112 scaledInfo, pixels, rowBytes, &subsetOptions); in onGetAndroidPixels()
122 this->codec()->fillIncompleteImage(scaledInfo, pixels, rowBytes, in onGetAndroidPixels()
150 this->codec()->fillIncompleteImage(info, pixels, rowBytes, options.fZeroInitialized, in onGetAndroidPixels()
155 int decodedLines = this->codec()->getScanlines(pixels, scaledSubsetHeight, rowBytes); in onGetAndroidPixels()
164 size_t rowBytes, const AndroidOptions& options) { in sampledDecode()
223 pixels, rowBytes, in sampledDecode()
74 onGetAndroidPixels(const SkImageInfo& info, void* pixels, size_t rowBytes, const AndroidOptions& options) onGetAndroidPixels() argument
163 sampledDecode(const SkImageInfo& info, void* pixels, size_t rowBytes, const AndroidOptions& options) sampledDecode() argument
[all...]
H A DSkSampler.cpp13 void SkSampler::Fill(const SkImageInfo& info, void* dst, size_t rowBytes, in Fill() argument
31 dstRow = SkTAddOffset<uint32_t>(dstRow, rowBytes); in Fill()
39 dstRow = SkTAddOffset<uint16_t>(dstRow, rowBytes); in Fill()
47 dstRow = SkTAddOffset<uint8_t>(dstRow, rowBytes); in Fill()
55 dstRow = SkTAddOffset<uint64_t>(dstRow, rowBytes); in Fill()
/third_party/skia/src/image/
H A DSkSurface_Raster.cpp39 bool SkSurfaceValidateRasterInfo(const SkImageInfo& info, size_t rowBytes) { in SkSurfaceValidateRasterInfo() argument
44 if (kIgnoreRowBytesValue == rowBytes) { in SkSurfaceValidateRasterInfo()
48 if (!info.validRowBytes(rowBytes)) { in SkSurfaceValidateRasterInfo()
52 uint64_t size = sk_64_mul(info.height(), rowBytes); in SkSurfaceValidateRasterInfo()
74 fBitmap.setInfo(info, pr->rowBytes()); in SkSurface_Raster()
143 SkASSERT(prev.rowBytes() == fBitmap.rowBytes()); in onCopyOnWrite()
174 sk_sp<SkSurface> SkSurface::MakeRasterDirect(const SkImageInfo& info, void* pixels, size_t rowBytes, in MakeRasterDirect() argument
176 return MakeRasterDirectReleaseProc(info, pixels, rowBytes, nullptr, nullptr, props); in MakeRasterDirect()
179 sk_sp<SkSurface> SkSurface::MakeRaster(const SkImageInfo& info, size_t rowBytes, in MakeRaster() argument
[all...]
H A DSkImage_Raster.cpp39 static bool ValidArgs(const SkImageInfo& info, size_t rowBytes, size_t* minSize) { in ValidArgs() argument
44 if (!b.setInfo(info, rowBytes)) { in ValidArgs()
64 if (!info.validRowBytes(rowBytes)) { in ValidArgs()
68 size_t size = info.computeByteSize(rowBytes); in ValidArgs()
170 SkImage_Raster::SkImage_Raster(const SkImageInfo& info, sk_sp<SkData> data, size_t rowBytes, in SkImage_Raster() argument
175 fBitmap.installPixels(info, addr, rowBytes, release_data, data.release()); in SkImage_Raster()
268 SkRectMemcpy(dst, bitmap.rowBytes(), src, fBitmap.rowBytes(), bitmap.rowBytes(), in onMakeSubset()
279 if (!SkImage_Raster::ValidArgs(pmap.info(), pmap.rowBytes(), in MakeRasterCopyPriv()
292 MakeRasterData(const SkImageInfo& info, sk_sp<SkData> data, size_t rowBytes) MakeRasterData() argument
[all...]
/third_party/skia/src/opts/
H A DSkUtils_opts.h44 static void rect_memsetT(T buffer[], T value, int count, size_t rowBytes, int height) { in rect_memsetT() argument
47 buffer = (T*)((char*)buffer + rowBytes); in rect_memsetT()
52 size_t rowBytes, int height) { in rect_memset16()
53 rect_memsetT(buffer, value, count, rowBytes, height); in rect_memset16()
56 size_t rowBytes, int height) { in rect_memset32()
57 rect_memsetT(buffer, value, count, rowBytes, height); in rect_memset32()
60 size_t rowBytes, int height) { in rect_memset64()
61 rect_memsetT(buffer, value, count, rowBytes, height); in rect_memset64()
51 rect_memset16(uint16_t buffer[], uint16_t value, int count, size_t rowBytes, int height) rect_memset16() argument
55 rect_memset32(uint32_t buffer[], uint32_t value, int count, size_t rowBytes, int height) rect_memset32() argument
59 rect_memset64(uint64_t buffer[], uint64_t value, int count, size_t rowBytes, int height) rect_memset64() argument
/third_party/skia/docs/examples/
H A DPixmap_scalePixels.cpp9 int rowBytes = image->width() * 4; in REG_FIDDLE() local
10 srcPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
11 SkPixmap pixmap(info, (const void*) &srcPixels.front(), rowBytes); in REG_FIDDLE()
15 rowBytes = info.width() * 4; in REG_FIDDLE()
17 dstPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
18 SkPixmap dstmap(info, &dstPixels.front(), rowBytes); in REG_FIDDLE()
H A DPixmap_readPixels_2.cpp9 const int rowBytes = image->width() * 4; in REG_FIDDLE() local
10 srcPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
11 SkPixmap pixmap(info, (const void*) &srcPixels.front(), rowBytes); in REG_FIDDLE()
15 dstPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
16 pixmap.readPixels(info, &dstPixels.front(), rowBytes, offset, 0); in REG_FIDDLE()
18 SkPixmap dstmap(info, &dstPixels.front(), rowBytes); in REG_FIDDLE()
H A DImageInfo_validRowBytes.cpp8 for (size_t rowBytes = 60; rowBytes < 72; rowBytes += sizeof(SkPMColor)) { in REG_FIDDLE()
9 SkDebugf("validRowBytes(%zu): %s\n", rowBytes, info.validRowBytes(rowBytes) ? in REG_FIDDLE()
H A DImageInfo_ByteSizeOverflowed.cpp10 for (size_t rowBytes = 100000000; rowBytes < 10000000000000LL; rowBytes *= 10) { in REG_FIDDLE()
11 const size_t size = info.computeByteSize(rowBytes); in REG_FIDDLE()
12 SkDebugf("rowBytes:%llu size:%llu overflowed:%s\n", rowBytes, size, in REG_FIDDLE()
H A DPixmap_readPixels_3.cpp9 const int rowBytes = image->width() * 4; in REG_FIDDLE() local
10 srcPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
11 SkPixmap pixmap(info, (const void*) &srcPixels.front(), rowBytes); in REG_FIDDLE()
15 dstPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
16 SkPixmap dstmap(info, &dstPixels.front(), rowBytes); in REG_FIDDLE()
H A DPixmap_readPixels_4.cpp9 const int rowBytes = image->width() * 4; in REG_FIDDLE() local
10 srcPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
11 SkPixmap pixmap(info, (const void*) &srcPixels.front(), rowBytes); in REG_FIDDLE()
15 dstPixels.resize(image->height() * rowBytes); in REG_FIDDLE()
16 SkPixmap dstmap(info, &dstPixels.front(), rowBytes); in REG_FIDDLE()
H A DBitmap_tryAllocPixels_4.cpp8 LargePixelRef(const SkImageInfo& info, char* storage, size_t rowBytes) in REG_FIDDLE() argument
9 : SkPixelRef(info.width(), info.height(), storage, rowBytes) { in REG_FIDDLE()
19 uint64_t rowBytes = info.minRowBytes64(); in REG_FIDDLE() local
20 uint64_t size = info.height() * rowBytes; in REG_FIDDLE()
25 sk_sp<SkPixelRef> pr = sk_sp<SkPixelRef>(new LargePixelRef(info, addr, rowBytes)); in REG_FIDDLE()
H A DImage_MakeRasterData.cpp7 size_t rowBytes = image->width() * SkColorTypeBytesPerPixel(kRGBA_8888_SkColorType); in REG_FIDDLE() local
8 sk_sp<SkData> data = SkData::MakeUninitialized(rowBytes * image->height()); in REG_FIDDLE()
11 image->readPixels(nullptr, dstInfo, data->writable_data(), rowBytes, 0, 0, SkImage::kAllow_CachingHint); in REG_FIDDLE()
13 data, rowBytes); in REG_FIDDLE()
/third_party/skia/src/ports/
H A DSkImageEncoder_WIC.cpp55 !bitmapOrig.readPixels(bitmap.info(), bitmap.getPixels(), bitmap.rowBytes(), 0, 0)) in SkEncodeImageWithWIC()
65 uint8_t* bytes = pixels + y * bitmap.rowBytes() + x * bitmap.bytesPerPixel(); in SkEncodeImageWithWIC()
75 size_t rowBytes = bitmap.rowBytes(); in SkEncodeImageWithWIC() local
80 rowBytes = SkAlign4(bitmap.width() * 3); in SkEncodeImageWithWIC()
81 pixelStorage.reset(rowBytes * bitmap.height()); in SkEncodeImageWithWIC()
83 uint8_t* dstRow = SkTAddOffset<uint8_t>(pixelStorage.get(), y * rowBytes); in SkEncodeImageWithWIC()
182 (UINT) rowBytes, in SkEncodeImageWithWIC()
183 (UINT) rowBytes * height, in SkEncodeImageWithWIC()
/third_party/skia/include/codec/
H A DSkCodec.h87 * Parameters (besides info) are invalid. e.g. NULL pixels, rowBytes
339 * least (info.fHeight - 1) * rowBytes + (info.fWidth *
372 Result getPixels(const SkImageInfo& info, void* pixels, size_t rowBytes, const Options*);
377 Result getPixels(const SkImageInfo& info, void* pixels, size_t rowBytes) { in getPixels() argument
378 return this->getPixels(info, pixels, rowBytes, nullptr); in getPixels()
382 return this->getPixels(pm.info(), pm.writable_addr(), pm.rowBytes(), opts); in getPixels()
432 Result startIncrementalDecode(const SkImageInfo& dstInfo, void* dst, size_t rowBytes,
435 Result startIncrementalDecode(const SkImageInfo& dstInfo, void* dst, size_t rowBytes) { in startIncrementalDecode() argument
436 return this->startIncrementalDecode(dstInfo, dst, rowBytes, nullptr); in startIncrementalDecode()
505 * scanlines of size rowBytes
[all...]
H A DSkAndroidCodec.h206 * least (info.fHeight - 1) * rowBytes + (info.fWidth *
234 SkCodec::Result getAndroidPixels(const SkImageInfo& info, void* pixels, size_t rowBytes,
241 SkCodec::Result getAndroidPixels(const SkImageInfo& info, void* pixels, size_t rowBytes);
243 SkCodec::Result getPixels(const SkImageInfo& info, void* pixels, size_t rowBytes) { in getPixels() argument
244 return this->getAndroidPixels(info, pixels, rowBytes); in getPixels()
257 size_t rowBytes, const AndroidOptions& options) = 0;
/third_party/skia/src/effects/
H A DSkEmbossMask.cpp64 int rowBytes = mask->fRowBytes; in Emboss() local
70 int next_row = neq_to_mask(y, maxy) & rowBytes; in Emboss()
109 alpha += rowBytes; in Emboss()
110 multiply += rowBytes; in Emboss()
111 additive += rowBytes; in Emboss()
112 prev_row = rowBytes; in Emboss()

Completed in 11 milliseconds

1234567891011