本文整理汇总了C++中SkWriteBuffer::writeScalarArray方法的典型用法代码示例。如果您正苦于以下问题:C++ SkWriteBuffer::writeScalarArray方法的具体用法?C++ SkWriteBuffer::writeScalarArray怎么用?C++ SkWriteBuffer::writeScalarArray使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SkWriteBuffer
的用法示例。
在下文中一共展示了SkWriteBuffer::writeScalarArray方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: flatten
void flatten(SkWriteBuffer& buf) const override {
buf.writeBitmap(fDiffuseMap);
buf.writeBitmap(fNormalMap);
buf.writeScalarArray(&fLight.fDirection.fX, 3);
buf.writeColor(fLight.fColor);
buf.writeColor(fAmbientColor);
}
示例2: flatten
void SkLights::flatten(SkWriteBuffer& buf) const {
buf.writeScalarArray(&this->ambientLightColor().fX, 3);
buf.writeInt(this->numLights());
for (int l = 0; l < this->numLights(); ++l) {
const Light& light = this->light(l);
bool isPoint = Light::kPoint_LightType == light.type();
buf.writeBool(isPoint);
buf.writeScalarArray(&light.color().fX, 3);
buf.writeScalarArray(&light.dir().fX, 3);
if (isPoint) {
buf.writeScalar(light.intensity());
}
}
}
示例3: flatten
void SkDashPathEffect::flatten(SkWriteBuffer& 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 SkMatrixConvolutionImageFilter::flatten(SkWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.writeInt(fKernelSize.fWidth);
buffer.writeInt(fKernelSize.fHeight);
buffer.writeScalarArray(fKernel, fKernelSize.fWidth * fKernelSize.fHeight);
buffer.writeScalar(fGain);
buffer.writeScalar(fBias);
buffer.writeInt(fKernelOffset.fX);
buffer.writeInt(fKernelOffset.fY);
buffer.writeInt((int) fTileMode);
buffer.writeBool(fConvolveAlpha);
}
示例5: flatten
void SkDashPathEffect::flatten(SkWriteBuffer& buffer) const {
buffer.writeScalar(fPhase);
buffer.writeScalarArray(fIntervals, fCount);
}
示例6: Write
static void Write(SkWriteBuffer& writer, SkScalar* data, uint32_t arraySize) {
writer.writeScalarArray(data, arraySize);
}
示例7: SkASSERT
void SkColorMatrixFilterRowMajor255::flatten(SkWriteBuffer& buffer) const {
SkASSERT(sizeof(fMatrix)/sizeof(SkScalar) == 20);
buffer.writeScalarArray(fMatrix, 20);
}