本文整理汇总了C++中SkFlattenableWriteBuffer::writeScalar方法的典型用法代码示例。如果您正苦于以下问题:C++ SkFlattenableWriteBuffer::writeScalar方法的具体用法?C++ SkFlattenableWriteBuffer::writeScalar怎么用?C++ SkFlattenableWriteBuffer::writeScalar使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SkFlattenableWriteBuffer
的用法示例。
在下文中一共展示了SkFlattenableWriteBuffer::writeScalar方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: flatten
void SkRectShape::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.writeRect(fBounds);
buffer.writeScalar(fRadii.fWidth);
buffer.writeScalar(fRadii.fHeight);
}
示例2:
void SkPath1DPathEffect::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.writeScalar(fAdvance);
if (fAdvance > 0) {
fPath.flatten(buffer);
buffer.writeScalar(fInitialOffset);
buffer.write8(fStyle);
}
}
示例3: flatten
void SkDashPathEffect::flatten(SkFlattenableWriteBuffer& buffer) const {
SkASSERT(fInitialDashLength >= 0);
this->INHERITED::flatten(buffer);
buffer.writeInt(fInitialDashIndex);
buffer.writeScalar(fInitialDashLength);
buffer.writeScalar(fIntervalLength);
buffer.writeBool(fScaleToFit);
buffer.writeScalarArray(fIntervals, fCount);
}
示例4: flatten
void SkLayerDrawLooper::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
#ifdef SK_DEBUG
{
Rec* rec = fRecs;
int count = 0;
while (rec) {
rec = rec->fNext;
count += 1;
}
SkASSERT(count == fCount);
}
#endif
buffer.writeInt(fCount);
Rec* rec = fRecs;
for (int i = 0; i < fCount; i++) {
buffer.writeInt(rec->fInfo.fPaintBits);
buffer.writeInt(rec->fInfo.fColorMode);
buffer.writeScalar(rec->fInfo.fOffset.fX);
buffer.writeScalar(rec->fInfo.fOffset.fY);
buffer.writeBool(rec->fInfo.fPostTranslate);
rec->fPaint.flatten(buffer);
rec = rec->fNext;
}
}
示例5: flatten
void SkBlurMaskFilterImpl::flatten(SkFlattenableWriteBuffer& buffer)
{
this->INHERITED::flatten(buffer);
buffer.writeScalar(fRadius);
buffer.write32(fBlurStyle);
buffer.write32(fBlurFlags);
}
示例6: flatten
void SkEmbossMaskFilter::flatten(SkFlattenableWriteBuffer& buffer) {
this->INHERITED::flatten(buffer);
fLight.fPad = 0; // for the font-cache lookup to be clean
buffer.writeMul4(&fLight, sizeof(fLight));
buffer.writeScalar(fBlurRadius);
}
示例7: flatten
void SkEmbossMaskFilter::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
Light tmpLight = fLight;
tmpLight.fPad = 0; // for the font-cache lookup to be clean
buffer.writeByteArray(&tmpLight, sizeof(tmpLight));
buffer.writeScalar(-fBlurSigma);
}
示例8: flatten
void SkBlurDrawLooper::flatten(SkFlattenableWriteBuffer& buffer) {
buffer.writeScalar(fDx);
buffer.writeScalar(fDy);
buffer.write32(fBlurColor);
buffer.writeFlattenable(fBlur);
buffer.writeFlattenable(fColorFilter);
buffer.write32(fBlurFlags);
}
示例9: flatten
void SkBlurDrawLooper::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.writeScalar(fDx);
buffer.writeScalar(fDy);
buffer.writeColor(fBlurColor);
buffer.writeFlattenable(fBlur);
buffer.writeFlattenable(fColorFilter);
buffer.writeUInt(fBlurFlags);
}
示例10: paint_write
static void paint_write(const SkPaint& paint, SkFlattenableWriteBuffer& buffer)
{
buffer.writeBool(paint.isAntiAlias());
buffer.write8(paint.getStyle());
buffer.write8(paint.getAlpha());
if (paint.getStyle() != SkPaint::kFill_Style)
{
buffer.writeScalar(paint.getStrokeWidth());
buffer.writeScalar(paint.getStrokeMiter());
buffer.write8(paint.getStrokeCap());
buffer.write8(paint.getStrokeJoin());
}
buffer.writeFlattenable(paint.getMaskFilter());
buffer.writeFlattenable(paint.getPathEffect());
buffer.writeFlattenable(paint.getRasterizer());
buffer.writeFlattenable(paint.getXfermode());
}
示例11: flatten
void SkLayerRasterizer::flatten(SkFlattenableWriteBuffer& buffer)
{
this->INHERITED::flatten(buffer);
buffer.write32(fLayers.count());
SkDeque::Iter iter(fLayers);
const SkLayerRasterizer_Rec* rec;
while ((rec = (const SkLayerRasterizer_Rec*)iter.next()) != NULL)
{
#if 0
rec->fPaint.flatten(buffer);
#else
paint_write(rec->fPaint, buffer);
#endif
buffer.writeScalar(rec->fOffset.fX);
buffer.writeScalar(rec->fOffset.fY);
}
}
示例12: flatten
void SkCornerPathEffect::flatten(SkFlattenableWriteBuffer& buffer)
{
buffer.writeScalar(fRadius);
}
示例13: flatten
void SkDownSampleImageFilter::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.writeScalar(fScale);
}
示例14: flatten
void SkBlurImageFilter::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.writeScalar(fSigma.fWidth);
buffer.writeScalar(fSigma.fHeight);
}
示例15: flatten
void SkCornerPathEffect::flatten(SkFlattenableWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.writeScalar(fRadius);
}