Searched refs:dstInfo (Results 1 - 25 of 67) sorted by relevance

123

/external/skia/src/core/
H A DSkConvertPixels.cpp21 static inline bool can_memcpy(const SkImageInfo& dstInfo, const SkImageInfo& srcInfo) { argument
22 if (dstInfo.colorType() != srcInfo.colorType()) {
26 if (kAlpha_8_SkColorType == dstInfo.colorType()) {
30 if (dstInfo.alphaType() != srcInfo.alphaType() &&
31 kOpaque_SkAlphaType != dstInfo.alphaType() &&
38 return !dstInfo.colorSpace() ||
39 SkColorSpace::Equals(dstInfo.colorSpace(), srcInfo.colorSpace());
54 void swizzle_and_multiply(const SkImageInfo& dstInfo, void* dstPixels, size_t dstRB, argument
57 const bool swapRB = dstInfo.colorType() != srcInfo.colorType();
59 if (kPremul_SkAlphaType == dstInfo
90 optimized_color_xform(const SkImageInfo& dstInfo, const SkImageInfo& srcInfo, SkTransferFunctionBehavior behavior) argument
120 apply_color_xform(const SkImageInfo& dstInfo, void* dstPixels, size_t dstRB, const SkImageInfo& srcInfo, const void* srcPixels, size_t srcRB, SkTransferFunctionBehavior behavior) argument
163 do_index8(const SkImageInfo& dstInfo, T* dstPixels, size_t dstRB, const SkImageInfo& srcInfo, const uint8_t* srcPixels, size_t srcRB, SkColorTable* ctable, SkTransferFunctionBehavior behavior) argument
183 convert_from_index8(const SkImageInfo& dstInfo, void* dstPixels, size_t dstRB, const SkImageInfo& srcInfo, const uint8_t* srcPixels, size_t srcRB, SkColorTable* ctable, SkTransferFunctionBehavior behavior) argument
276 convert_with_pipeline(const SkImageInfo& dstInfo, void* dstRow, size_t dstRB, const SkImageInfo& srcInfo, const void* srcRow, size_t srcRB, bool isColorAware, SkTransferFunctionBehavior behavior) argument
378 SkConvertPixels(const SkImageInfo& dstInfo, void* dstPixels, size_t dstRB, const SkImageInfo& srcInfo, const void* srcPixels, size_t srcRB, SkColorTable* ctable, SkTransferFunctionBehavior behavior) argument
[all...]
/external/skia/src/codec/
H A DSkBmpMaskCodec.cpp27 SkCodec::Result SkBmpMaskCodec::onGetPixels(const SkImageInfo& dstInfo, argument
37 if (dstInfo.dimensions() != this->getInfo().dimensions()) {
42 Result result = this->prepareToDecode(dstInfo, opts, inputColorPtr, inputColorCount);
47 int rows = this->decodeRows(dstInfo, dst, dstRowBytes, opts);
48 if (rows != dstInfo.height()) {
55 SkCodec::Result SkBmpMaskCodec::onPrepareToDecode(const SkImageInfo& dstInfo, argument
58 this->resetXformBuffer(dstInfo.width());
61 SkImageInfo swizzlerInfo = dstInfo;
64 if (kPremul_SkAlphaType == dstInfo.alphaType()) {
80 int SkBmpMaskCodec::decodeRows(const SkImageInfo& dstInfo, argument
[all...]
H A DSkBmpStandardCodec.cpp38 SkCodec::Result SkBmpStandardCodec::onGetPixels(const SkImageInfo& dstInfo, argument
48 if (dstInfo.dimensions() != this->getInfo().dimensions()) {
53 Result result = this->prepareToDecode(dstInfo, opts, inputColorPtr, inputColorCount);
57 int rows = this->decodeRows(dstInfo, dst, dstRowBytes, opts);
58 if (rows != dstInfo.height()) {
165 void SkBmpStandardCodec::initializeSwizzler(const SkImageInfo& dstInfo, const Options& opts) { argument
183 SkImageInfo swizzlerInfo = dstInfo;
187 if (kPremul_SkAlphaType == dstInfo.alphaType()) {
200 SkCodec::Result SkBmpStandardCodec::onPrepareToDecode(const SkImageInfo& dstInfo, argument
204 fXformOnDecode = apply_xform_on_decode(dstInfo
228 decodeRows(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes, const Options& opts) argument
304 decodeIcoMask(SkStream* stream, const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes) argument
[all...]
H A DSkGifCodec.cpp155 void SkGifCodec::initializeColorTable(const SkImageInfo& dstInfo, size_t frameIndex) { argument
156 SkColorType colorTableColorType = dstInfo.colorType();
170 select_xform_format_ct(dstInfo.colorType());
172 const SkAlphaType xformAlphaType = select_xform_alpha(dstInfo.alphaType(),
184 SkCodec::Result SkGifCodec::prepareToDecode(const SkImageInfo& dstInfo, SkPMColor* inputColorPtr, argument
187 if (!conversion_possible(dstInfo, this->getInfo()) ||
188 !this->initializeColorXform(dstInfo, opts.fPremulBehavior))
195 fXformOnDecode = apply_xform_on_decode(dstInfo.colorType(), this->getEncodedInfo().color());
197 fXformBuffer.reset(new uint32_t[dstInfo.width()]);
198 sk_bzero(fXformBuffer.get(), dstInfo
267 initializeSwizzler(const SkImageInfo& dstInfo, size_t frameIndex) argument
303 onGetPixels(const SkImageInfo& dstInfo, void* pixels, size_t dstRowBytes, const Options& opts, SkPMColor* inputColorPtr, int* inputColorCount, int* rowsDecoded) argument
335 onStartIncrementalDecode(const SkImageInfo& dstInfo, void* pixels, size_t dstRowBytes, const SkCodec::Options& opts, SkPMColor* inputColorPtr, int* inputColorCount) argument
365 const SkImageInfo& dstInfo = this->dstInfo(); local
507 applyXformRow(const SkImageInfo& dstInfo, void* dst, const uint8_t* src) const argument
607 const auto dstInfo = this->dstInfo(); local
[all...]
H A DSkBmpStandardCodec.h49 Result onGetPixels(const SkImageInfo& dstInfo, void* dst,
57 SkCodec::Result onPrepareToDecode(const SkImageInfo& dstInfo,
77 void initializeSwizzler(const SkImageInfo& dstInfo, const Options& opts);
79 int decodeRows(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes,
87 void decodeIcoMask(SkStream* stream, const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes);
H A DSkBmpRLECodec.cpp34 SkCodec::Result SkBmpRLECodec::onGetPixels(const SkImageInfo& dstInfo, argument
45 Result result = this->prepareToDecode(dstInfo, opts, inputColorPtr, inputColorCount);
51 int rows = this->decodeRows(dstInfo, dst, dstRowBytes, opts);
52 if (rows != dstInfo.height()) {
56 *rowsDecoded = dstInfo.height();
176 const SkImageInfo& dstInfo, uint32_t x, uint32_t y,
178 if (dst && is_coord_necessary(x, fSampleX, dstInfo.width())) {
180 uint32_t row = this->getDstRow(y, dstInfo.height());
184 switch (dstInfo.colorType()) {
209 const SkImageInfo& dstInfo, uint32_
175 setPixel(void* dst, size_t dstRowBytes, const SkImageInfo& dstInfo, uint32_t x, uint32_t y, uint8_t index) argument
208 setRGBPixel(void* dst, size_t dstRowBytes, const SkImageInfo& dstInfo, uint32_t x, uint32_t y, uint8_t red, uint8_t green, uint8_t blue) argument
243 onPrepareToDecode(const SkImageInfo& dstInfo, const SkCodec::Options& options, SkPMColor inputColorPtr[], int* inputColorCount) argument
292 SkImageInfo dstInfo = info.makeWH(get_scaled_dimension(width, fSampleX), height); local
343 decodeRLE(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes) argument
[all...]
H A DSkBmpMaskCodec.h40 Result onGetPixels(const SkImageInfo& dstInfo, void* dst,
44 SkCodec::Result onPrepareToDecode(const SkImageInfo& dstInfo,
55 int decodeRows(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes,
H A DSkBmpRLECodec.h46 Result onGetPixels(const SkImageInfo& dstInfo, void* dst,
50 SkCodec::Result onPrepareToDecode(const SkImageInfo& dstInfo,
77 const SkImageInfo& dstInfo, uint32_t x, uint32_t y,
83 const SkImageInfo& dstInfo, uint32_t x, uint32_t y,
89 int decodeRows(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes,
91 int decodeRLE(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes);
H A DSkBmpCodec.h91 * @param dstInfo Contains output information. Height specifies
102 virtual SkCodec::Result onPrepareToDecode(const SkImageInfo& dstInfo,
105 SkCodec::Result prepareToDecode(const SkImageInfo& dstInfo,
109 void applyColorXform(const SkImageInfo& dstInfo, void* dst, void* src) const;
128 * Decodes the next dstInfo.height() lines.
132 * dstInfo.height() = 1, in order to implement sampling.
136 * @param dstInfo Contains output information. Height specifies the
142 virtual int decodeRows(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes,
147 Result onStartScanlineDecode(const SkImageInfo& dstInfo, const SkCodec::Options&,
H A DSkJpegCodec.h47 Result onGetPixels(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes, const Options&,
114 void initializeSwizzler(const SkImageInfo& dstInfo, const Options& options,
116 void allocateStorage(const SkImageInfo& dstInfo);
117 int readRows(const SkImageInfo& dstInfo, void* dst, size_t rowBytes, int count, const Options&);
123 Result onStartScanlineDecode(const SkImageInfo& dstInfo, const Options& options,
H A DSkGifCodec.h56 Result onStartIncrementalDecode(const SkImageInfo& /*dstInfo*/, void*, size_t,
66 * @param dstInfo Contains the requested dst color type.
69 void initializeColorTable(const SkImageInfo& dstInfo, size_t frameIndex);
75 Result prepareToDecode(const SkImageInfo& dstInfo, SkPMColor* inputColorPtr,
81 * @param dstInfo Output image information. Dimensions may have been
87 void initializeSwizzler(const SkImageInfo& dstInfo, size_t frameIndex);
122 void applyXformRow(const SkImageInfo& dstInfo, void* dst, const uint8_t* src) const;
H A DSkIcoCodec.h42 Result onGetPixels(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes, const Options&,
53 Result onStartScanlineDecode(const SkImageInfo& dstInfo, const SkCodec::Options& options,
60 Result onStartIncrementalDecode(const SkImageInfo& dstInfo, void* pixels, size_t rowBytes,
H A DSkWebpCodec.cpp194 SkCodec::Result SkWebpCodec::onGetPixels(const SkImageInfo& dstInfo, void* dst, size_t rowBytes, argument
197 if (!conversion_possible(dstInfo, this->getInfo()) ||
198 !this->initializeColorXform(dstInfo, options.fPremulBehavior))
224 SkSampler::Fill(dstInfo, dst, rowBytes, 0, options.fZeroInitialized);
269 if (srcSize != dstInfo.dimensions()) {
273 float scaleX = ((float) dstInfo.width()) / srcSize.width();
274 float scaleY = ((float) dstInfo.height()) / srcSize.height();
286 scaledWidth = dstInfo.width();
287 scaledHeight = dstInfo.height();
300 webp_decode_mode(dstInfo
[all...]
H A DSkPngCodec.h75 Result onStartIncrementalDecode(const SkImageInfo& dstInfo, void* pixels, size_t rowBytes,
104 bool createColorTable(const SkImageInfo& dstInfo, int* ctableCount);
106 bool initializeXforms(const SkImageInfo& dstInfo, const Options&, SkPMColor* colorPtr,
108 void initializeSwizzler(const SkImageInfo& dstInfo, const Options&, bool skipFormatConversion);
109 void allocateStorage(const SkImageInfo& dstInfo);
H A DSkWbmpCodec.cpp33 static inline bool valid_color_type(const SkImageInfo& dstInfo) { argument
34 switch (dstInfo.colorType()) {
42 return dstInfo.colorSpace() && dstInfo.colorSpace()->gammaIsLinear();
191 SkCodec::Result SkWbmpCodec::onStartScanlineDecode(const SkImageInfo& dstInfo, argument
198 if (!valid_color_type(dstInfo) ||
199 !valid_alpha(dstInfo.alphaType(), this->getInfo().alphaType()))
205 setup_color_table(dstInfo.colorType(), inputColorTable, inputColorCount);
208 if (kIndex_8_SkColorType == dstInfo.colorType()) {
213 fSwizzler.reset(this->initializeSwizzler(dstInfo, get_color_pt
[all...]
H A DSkRawCodec.h37 Result onGetPixels(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes, const Options&,
H A DSkPngCodec.cpp248 bool SkPngCodec::createColorTable(const SkImageInfo& dstInfo, int* ctableCount) { argument
259 SkColorType tableColorType = this->colorXform() ? kXformSrcColorType : dstInfo.colorType();
266 bool premultiply = !this->colorXform() && needs_premul(dstInfo, this->getEncodedInfo());
300 !apply_xform_on_decode(dstInfo.colorType(), this->getEncodedInfo().color())) {
302 select_xform_format_ct(dstInfo.colorType());
304 const SkAlphaType xformAlphaType = select_xform_alpha(dstInfo.alphaType(),
443 void SkPngCodec::allocateStorage(const SkImageInfo& dstInfo) { argument
457 const size_t colorXformBytes = dstInfo.width() * bytesPerPixel;
989 bool SkPngCodec::initializeXforms(const SkImageInfo& dstInfo, const Options& options, argument
1001 if (!this->initializeColorXform(dstInfo, option
1058 initializeSwizzler(const SkImageInfo& dstInfo, const Options& options, bool skipFormatConversion) argument
1114 onGetPixels(const SkImageInfo& dstInfo, void* dst, size_t rowBytes, const Options& options, SkPMColor ctable[], int* ctableCount, int* rowsDecoded) argument
1133 onStartIncrementalDecode(const SkImageInfo& dstInfo, void* dst, size_t rowBytes, const SkCodec::Options& options, SkPMColor* ctable, int* ctableCount) argument
[all...]
H A DSkIcoCodec.cpp248 SkCodec::Result SkIcoCodec::onGetPixels(const SkImageInfo& dstInfo, argument
260 index = this->chooseCodec(dstInfo.dimensions(), index);
266 result = embeddedCodec->getPixels(dstInfo, dst, dstRowBytes, &opts, colorTable, colorCount);
272 *rowsDecoded = dstInfo.height();
286 SkCodec::Result SkIcoCodec::onStartScanlineDecode(const SkImageInfo& dstInfo, argument
291 index = this->chooseCodec(dstInfo.dimensions(), index);
297 result = embeddedCodec->startScanlineDecode(dstInfo, &options, colorTable, colorCount);
321 SkCodec::Result SkIcoCodec::onStartIncrementalDecode(const SkImageInfo& dstInfo, argument
326 index = this->chooseCodec(dstInfo.dimensions(), index);
332 switch (embeddedCodec->startIncrementalDecode(dstInfo,
[all...]
H A DSkCodecPriv.h154 static inline void copy_color_table(const SkImageInfo& dstInfo, SkColorTable* colorTable, argument
156 if (kIndex_8_SkColorType == dstInfo.colorType()) {
301 static inline bool needs_premul(const SkImageInfo& dstInfo, const SkEncodedInfo& encodedInfo) { argument
302 return kPremul_SkAlphaType == dstInfo.alphaType() &&
306 static inline bool needs_color_xform(const SkImageInfo& dstInfo, const SkImageInfo& srcInfo, argument
309 if (!dstInfo.colorSpace()) {
314 bool isF16 = kRGBA_F16_SkColorType == dstInfo.colorType();
317 bool srcDstNotEqual = !SkColorSpace::Equals(srcInfo.colorSpace(), dstInfo.colorSpace());
H A DSkJpegCodec.cpp375 bool SkJpegCodec::setOutputColorSpace(const SkImageInfo& dstInfo) { argument
376 if (kUnknown_SkAlphaType == dstInfo.alphaType()) {
380 if (kOpaque_SkAlphaType != dstInfo.alphaType()) {
391 switch (dstInfo.colorType()) {
430 if (!dstInfo.colorSpace()->gammaIsLinear()) {
486 int SkJpegCodec::readRows(const SkImageInfo& dstInfo, void* dst, size_t rowBytes, int count, argument
504 int dstWidth = opts.fSubset ? opts.fSubset->width() : dstInfo.width();
535 SkAssertResult(this->colorXform()->apply(select_xform_format(dstInfo.colorType()), dst,
567 SkCodec::Result SkJpegCodec::onGetPixels(const SkImageInfo& dstInfo, argument
584 if (!this->initializeColorXform(dstInfo, option
617 allocateStorage(const SkImageInfo& dstInfo) argument
642 initializeSwizzler(const SkImageInfo& dstInfo, const Options& options, bool needsCMYKToRGB) argument
685 onStartScanlineDecode(const SkImageInfo& dstInfo, const Options& options, SkPMColor ctable[], int* ctableCount) argument
[all...]
H A DSkBmpCodec.cpp616 SkCodec::Result SkBmpCodec::prepareToDecode(const SkImageInfo& dstInfo, argument
618 if (!conversion_possible(dstInfo, this->getInfo()) ||
619 !this->initializeColorXform(dstInfo, options.fPremulBehavior))
624 return this->onPrepareToDecode(dstInfo, options, inputColorPtr, inputColorCount);
627 SkCodec::Result SkBmpCodec::onStartScanlineDecode(const SkImageInfo& dstInfo, argument
629 return prepareToDecode(dstInfo, options, inputColorPtr, inputColorCount);
634 SkImageInfo rowInfo = this->dstInfo().makeWH(this->dstInfo().width(), count);
649 void SkBmpCodec::applyColorXform(const SkImageInfo& dstInfo, void* dst, void* src) const { argument
652 const SkColorSpaceXform::ColorFormat dstFormat = select_xform_format(dstInfo
[all...]
/external/skia/src/image/
H A DSkImage_Generator.cpp51 bool SkImage_Generator::onReadPixels(const SkImageInfo& dstInfo, void* dstPixels, size_t dstRB, argument
53 SkColorSpace* dstColorSpace = dstInfo.colorSpace();
58 return bm.readPixels(dstInfo, dstPixels, dstRB, srcX, srcY);
63 if (fCache.directGeneratePixels(dstInfo, dstPixels, dstRB, srcX, srcY)) {
71 return bm.readPixels(dstInfo, dstPixels, dstRB, srcX, srcY);
107 SkImageInfo dstInfo = fCache.info().makeColorSpace(target); local
108 if (kIndex_8_SkColorType == dstInfo.colorType() ||
109 kGray_8_SkColorType == dstInfo.colorType()) {
110 dstInfo = dstInfo
[all...]
/external/skia/include/codec/
H A DSkCodec.h402 * @param dstInfo Info of the destination. If the dimensions do not match
405 * if present, or the full image as described in dstInfo.
408 * @param ctable A pointer to a color table. When dstInfo.colorType() is
412 * dstInfo.colorType() is kIndex8, this should be non-NULL. It will
417 Result startIncrementalDecode(const SkImageInfo& dstInfo, void* dst, size_t rowBytes,
420 Result startIncrementalDecode(const SkImageInfo& dstInfo, void* dst, size_t rowBytes, argument
422 return this->startIncrementalDecode(dstInfo, dst, rowBytes, options, nullptr, nullptr);
425 Result startIncrementalDecode(const SkImageInfo& dstInfo, void* dst, size_t rowBytes) { argument
426 return this->startIncrementalDecode(dstInfo, dst, rowBytes, nullptr, nullptr, nullptr);
473 * @param dstInfo Inf
779 const SkImageInfo& dstInfo() const { return fDstInfo; } function in class:SkCodec
[all...]
/external/skia/src/gpu/
H A DGrTextureContext.cpp111 bool GrTextureContext::onReadPixels(const SkImageInfo& dstInfo, void* dstBuffer, argument
114 GrPixelConfig config = SkImageInfo2GrPixelConfig(dstInfo, *fContext->caps());
120 if (kUnpremul_SkAlphaType == dstInfo.alphaType()) {
130 return tex->readPixels(this->getColorSpace(), x, y, dstInfo.width(), dstInfo.height(),
131 config, dstInfo.colorSpace(), dstBuffer, dstRowBytes, flags);
H A DGrSurfaceContext.h67 * @param dstInfo image info for the destination
76 bool readPixels(const SkImageInfo& dstInfo, void* dstBuffer, size_t dstRowBytes, argument
78 return this->onReadPixels(dstInfo, dstBuffer, dstRowBytes, x, y, flags);
139 virtual bool onReadPixels(const SkImageInfo& dstInfo, void* dstBuffer,

Completed in 3302 milliseconds

123