Lines Matching refs:buffer
133 SkGradientShaderBase::SkGradientShaderBase(SkFlattenableReadBuffer& buffer) :
134 INHERITED(buffer) {
137 fMapper = buffer.readFlattenableT<SkUnitMapper>();
143 int colorCount = fColorCount = buffer.getArrayCount();
150 buffer.readColorArray(fOrigColors);
152 fTileMode = (TileMode)buffer.readUInt();
159 recs[i].fPos = buffer.readInt();
160 recs[i].fScale = buffer.readUInt();
163 buffer.readMatrix(&fPtsToUnit);
187 void SkGradientShaderBase::flatten(SkFlattenableWriteBuffer& buffer) const {
188 this->INHERITED::flatten(buffer);
189 buffer.writeFlattenable(fMapper);
190 buffer.writeColorArray(fOrigColors, fColorCount);
191 buffer.writeUInt(fTileMode);
195 buffer.writeInt(recs[i].fPos);
196 buffer.writeUInt(recs[i].fScale);
199 buffer.writeMatrix(fPtsToUnit);
487 int32_t* buffer = storage.get();
489 *buffer++ = fColorCount;
490 memcpy(buffer, fOrigColors, fColorCount * sizeof(SkColor));
491 buffer += fColorCount;
494 *buffer++ = fRecs[i].fPos;
497 SkASSERT(buffer - storage.get() == count);