Home | History | Annotate | Download | only in effects

Lines Matching refs:light

26 sk_sp<SkMaskFilter> SkEmbossMaskFilter::Make(SkScalar blurSigma, const Light& light) {
31 Light newLight = light;
32 normalize3(newLight.fDirection, light.fDirection);
47 SkEmbossMaskFilter::Light light;
49 memcpy(light.fDirection, direction, sizeof(light.fDirection));
51 light.fAmbient = SkUnitScalarClampToByte(ambient);
54 light.fSpecular = static_cast<U8CPU>(SkScalarPin(specular, 0, 16) * kSpecularMultiplier + 0.5);
56 return SkEmbossMaskFilter::Make(blurSigma, light);
62 SkEmbossMaskFilter::SkEmbossMaskFilter(SkScalar blurSigma, const Light& light)
63 : fLight(light), fBlurSigma(blurSigma)
103 // run the light direction through the matrix...
104 Light light = fLight;
105 matrix.mapVectors((SkVector*)(void*)light.fDirection,
110 SkVector* vec = (SkVector*)(void*)light.fDirection;
111 vec->setLength(light.fDirection[0],
112 light.fDirection[1],
115 SkEmbossMask::Emboss(dst, light);
124 Light light;
125 if (buffer.readByteArray(&light, sizeof(Light))) {
126 light.fPad = 0; // for the font-cache lookup to be clean
128 return Make(sigma, light);
134 Light tmpLight = fLight;