/third_party/skia/samplecode/ |
D | SampleShadowReference.cpp | 79 const SkPoint3& lightPos, SkScalar lightWidth, SkScalar spotAlpha) { in drawShadowedPath() argument 94 lightPos, lightWidth, in drawShadowedPath() 122 SkPoint3 lightPos = { 175, -800, kDP * 600 }; in onDrawContent() local 133 lightPos, kLightWidth, kSpotAlpha); in onDrawContent() 136 lightPos.fX += 320; in onDrawContent() 144 lightPos, kLightWidth, kSpotAlpha); in onDrawContent() 147 lightPos.fX += 320; in onDrawContent() 155 lightPos, kLightWidth, kSpotAlpha); in onDrawContent() 158 lightPos.fX += 320; in onDrawContent() 166 lightPos, kLightWidth, kSpotAlpha); in onDrawContent() [all …]
|
D | SampleAndroidShadows.cpp | 146 const SkPoint3& lightPos, SkScalar lightWidth, SkScalar spotAlpha) { in drawShadowedPath() argument 164 SkShadowUtils::DrawShadow(canvas, path, zPlaneParams, lightPos, lightWidth, in drawShadowedPath() 189 SkPoint3 lightPos = fLightPos; in onDrawContent() local 196 lightPos, kLightWidth, fAnimAlpha*kSpotAlpha); in onDrawContent() 202 lightPos, kLightWidth, fAnimAlpha*kSpotAlpha); in onDrawContent() 208 lightPos, kLightWidth, fAnimAlpha*0.5f); in onDrawContent() 214 lightPos, kLightWidth, fAnimAlpha*kSpotAlpha); in onDrawContent() 220 lightPos, kLightWidth, fAnimAlpha*kSpotAlpha); in onDrawContent() 226 lightPos, kLightWidth, fAnimAlpha*kSpotAlpha); in onDrawContent() 232 kAmbientAlpha, lightPos, kLightWidth, kSpotAlpha); in onDrawContent() [all …]
|
D | SampleShadowColor.cpp | 97 const SkPoint3& lightPos, SkScalar lightWidth, SkScalar spotAlpha) { in drawShadowedPath() argument 112 lightPos, lightWidth, in drawShadowedPath() 129 lightPos, lightWidth, in drawShadowedPath() 135 lightPos, lightWidth, in drawShadowedPath() 148 lightPos, lightWidth, in drawShadowedPath() 198 SkPoint3 lightPos = { 75, -400, 600 }; in onDrawContent() local 203 lightPos.fX = 75; in onDrawContent() 211 lightPos, kLightWidth, kSpotAlpha); in onDrawContent() 214 lightPos.fX += 120; in onDrawContent() 218 lightPos.fY += 200; in onDrawContent()
|
D | SampleMaterialShadows.cpp | 45 const SkPoint3& lightPos, SkScalar lightRadius, SkScalar spotAlpha) { in drawShadowedPath() argument 51 SkShadowUtils::DrawShadow(canvas, path, zPlaneParams, lightPos, lightRadius, in drawShadowedPath() 69 SkPoint3 lightPos = fLightPos; in onDrawContent() local 78 lightPos, kLightRadius, kSpotAlpha); in onDrawContent() 88 lightPos, kLightRadius, kSpotAlpha); in onDrawContent() 98 lightPos, kLightRadius, kSpotAlpha); in onDrawContent() 108 lightPos, kLightRadius, kSpotAlpha); in onDrawContent() 120 lightPos, kLightRadius, kSpotAlpha); in onDrawContent() 133 lightPos, kLightRadius, kSpotAlpha); in onDrawContent()
|
D | SampleShadowUtils.cpp | 123 const SkPoint3& lightPos, SkScalar lightWidth, SkScalar spotAlpha, in drawShadowedPath() argument 142 lightPos, lightWidth, in drawShadowedPath() 166 static constexpr SkPoint3 lightPos = { 250, 400, 500 }; in onDrawContent() local 199 lightPos, kLightR, kSpotAlpha, flags); in onDrawContent() 225 lightPos, kLightR, kSpotAlpha, kNone_ShadowFlag); in onDrawContent() 242 canvas->drawCircle(lightPos.fX, lightPos.fY, kLightR / 10.f, blackPaint); in onDrawContent()
|
/third_party/skia/gm/ |
D | shadowutils.cpp | 28 SkPoint3 lightPos, SkScalar lightR, bool isAmbient, uint32_t flags) { in draw_shadow() argument 35 SkShadowUtils::DrawShadow(canvas, path, SkPoint3{ 0, 0, height}, lightPos, lightR, in draw_shadow() 86 SkPoint3 lightPos = { lightXY.fX, lightXY.fY, 500 }; in draw_paths() local 120 draw_shadow(canvas, path, kHeight, SK_ColorRED, lightPos, kLightR, in draw_paths() 122 draw_shadow(canvas, path, kHeight, SK_ColorBLUE, lightPos, kLightR, in draw_paths() 127 SkShadowUtils::DrawShadow(canvas, path, SkPoint3{0, 0, kHeight}, lightPos, in draw_paths() 181 draw_shadow(canvas, path, kHeight, SK_ColorRED, lightPos, kLightR, in draw_paths() 183 draw_shadow(canvas, path, kHeight, SK_ColorBLUE, lightPos, kLightR, in draw_paths() 188 SkShadowUtils::DrawShadow(canvas, path, SkPoint3{ 0, 0, kHeight }, lightPos, in draw_paths() 220 canvas->drawCircle(lightPos.fX, lightPos.fY, kLightR / 10.f, paint); in draw_paths() [all …]
|
/third_party/skia/src/core/ |
D | SkDrawShadowInfo.cpp | 33 bool GetSpotShadowTransform(const SkPoint3& lightPos, SkScalar lightRadius, in GetSpotShadowTransform() argument 47 SkDrawShadowMetrics::GetDirectionalParams(occluderHeight, lightPos.fX, lightPos.fY, in GetSpotShadowTransform() 48 lightPos.fZ, lightRadius, radius, in GetSpotShadowTransform() 51 SkDrawShadowMetrics::GetSpotParams(occluderHeight, lightPos.fX, lightPos.fY, in GetSpotShadowTransform() 52 lightPos.fZ, lightRadius, radius, in GetSpotShadowTransform() 81 SkScalar dz = lightPos.fZ - pts3D[i].fZ; in GetSpotShadowTransform() 87 pts3D[i].fX -= (lightPos.fX - pts3D[i].fX)*zRatio; in GetSpotShadowTransform() 88 pts3D[i].fY -= (lightPos.fY - pts3D[i].fY)*zRatio; in GetSpotShadowTransform() 132 *radius = SkDrawShadowMetrics::SpotBlurRadius(occluderHeight, lightPos.fZ, lightRadius); in GetSpotShadowTransform()
|
D | SkDrawShadowInfo.h | 87 bool GetSpotShadowTransform(const SkPoint3& lightPos, SkScalar lightRadius,
|
/third_party/skia/third_party/externals/tint/test/bug/tint/ |
D | 1121.wgsl.expected.wgsl | 62 var lightPos = lightsBuffer.lights[index].position; 63 lightPos = (uniforms.viewMatrix * lightPos); 64 lightPos = (lightPos / lightPos.w); 66 var boxMin : vec4<f32> = (lightPos - vec4<f32>(vec3<f32>(lightRadius), 0.0)); 67 var boxMax : vec4<f32> = (lightPos + vec4<f32>(vec3<f32>(lightRadius), 0.0));
|
D | 1121.wgsl.expected.glsl | 56 vec4 lightPos = lightsBuffer.lights[index].position; 57 lightPos = (uniforms.viewMatrix * lightPos); 58 lightPos = (lightPos / lightPos.w); 60 vec4 boxMin = (lightPos - vec4(vec3(lightRadius), 0.0f)); 61 vec4 boxMax = (lightPos + vec4(vec3(lightRadius), 0.0f));
|
D | 1121.wgsl.expected.hlsl | 43 float4 lightPos = asfloat(lightsBuffer.Load4((32u * index))); 44 lightPos = mul(lightPos, tint_symbol_6(uniforms, 32u)); 45 lightPos = (lightPos / lightPos.w); 47 float4 boxMin = (lightPos - float4(float3((lightRadius).xxx), 0.0f)); 48 float4 boxMax = (lightPos + float4(float3((lightRadius).xxx), 0.0f));
|
D | 1121.wgsl | 67 var lightPos = lightsBuffer.lights[index].position; 68 lightPos = uniforms.viewMatrix * lightPos; 69 lightPos = lightPos / lightPos.w; 71 var boxMin: vec4<f32> = lightPos - vec4<f32>(vec3<f32>(lightRadius), 0.0); 72 var boxMax: vec4<f32> = lightPos + vec4<f32>(vec3<f32>(lightRadius), 0.0);
|
D | 1121.wgsl.expected.msl | 67 float4 lightPos = (*(tint_symbol_2)).lights[index].position; 68 lightPos = ((*(tint_symbol_3)).viewMatrix * lightPos); 69 lightPos = (lightPos / lightPos[3]); 71 float4 boxMin = (lightPos - float4(float3(lightRadius), 0.0f)); 72 float4 boxMax = (lightPos + float4(float3(lightRadius), 0.0f));
|
D | 1121.wgsl.expected.spvasm | 46 OpName %lightPos "lightPos" 192 %lightPos = OpVariable %_ptr_Function_v4float Function %117 276 OpStore %lightPos %114 279 %121 = OpLoad %v4float %lightPos 281 OpStore %lightPos %122 282 %123 = OpLoad %v4float %lightPos 283 %124 = OpAccessChain %_ptr_Function_float %lightPos %uint_3 287 OpStore %lightPos %126 292 %133 = OpLoad %v4float %lightPos 301 %143 = OpLoad %v4float %lightPos
|
/third_party/skia/include/utils/ |
D | SkShadowUtils.h | 45 const SkPoint3& lightPos, SkScalar lightRadius, 70 const SkPoint3& zPlaneParams, const SkPoint3& lightPos,
|
/third_party/skia/src/utils/ |
D | SkShadowUtils.cpp | 577 const SkPoint3& lightPos, SkScalar lightRadius, in fill_shadow_rec() argument 580 SkPoint pt = { lightPos.fX, lightPos.fY }; in fill_shadow_rec() 592 rec->fLightPos = { pt.fX, pt.fY, lightPos.fZ }; in fill_shadow_rec() 603 const SkPoint3& lightPos, SkScalar lightRadius, in DrawShadow() argument 607 if (!fill_shadow_rec(path, zPlaneParams, lightPos, lightRadius, ambientColor, spotColor, in DrawShadow() 616 const SkPoint3& zPlaneParams, const SkPoint3& lightPos, in GetLocalBounds() argument 619 if (!fill_shadow_rec(path, zPlaneParams, lightPos, lightRadius, SK_ColorBLACK, SK_ColorBLACK, in GetLocalBounds()
|
D | SkShadowTessellator.h | 39 const SkPoint3& lightPos, SkScalar lightRadius, bool transparent,
|
D | SkShadowTessellator.cpp | 989 const SkPoint3& zPlaneParams, const SkPoint3& lightPos, 1002 const SkPoint3& lightPos, SkScalar lightRadius, in SkSpotShadowTessellator() argument 1009 if (!SkDrawShadowMetrics::GetSpotShadowTransform(lightPos, lightRadius, ctm, zPlaneParams, in SkSpotShadowTessellator() 1157 const SkPoint3& zPlane, const SkPoint3& lightPos, in MakeSpot() argument 1161 !lightPos.isFinite() || !(lightPos.fZ >= SK_ScalarNearlyZero) || in MakeSpot() 1165 SkSpotShadowTessellator spotTess(path, ctm, zPlane, lightPos, lightRadius, transparent, in MakeSpot()
|
/third_party/skia/third_party/externals/angle2/src/libANGLE/ |
D | GLES1Shaders.inc | 400 vec4 lightPos = light_positions[i]; 409 if (lightPos.w == 0.0) 411 toLight = lightPos.xyz; 415 toLight = (lightPos.xyz / lightPos.w - pos_varying.xyz); 436 if (lightPos.w != 0.0) 453 if (spotAngle == 180.0 || lightPos.w == 0.0)
|
/third_party/skia/modules/canvaskit/tests/ |
D | core.spec.js | 998 const lightPos = [500,500,20]; variable 1004 canvas.drawShadow(path, zPlaneParams, lightPos, lightRadius, 1009 path, zPlaneParams, lightPos, lightRadius, 0); 1013 path, zPlaneParams, lightPos, lightRadius, 0); 1021 lightTA.set(lightPos);
|
/third_party/skia/modules/canvaskit/ |
D | interface.js | 723 CanvasKit.Canvas.prototype.drawShadow = function(path, zPlaneParams, lightPos, lightRadius, argument 730 var lightPosPtr = copy1dArray(lightPos, 'HEAPF32', _scratchThreeFloatsBPtr); 736 CanvasKit.getShadowLocalBounds = function(ctm, path, zPlaneParams, lightPos, lightRadius, argument 741 var lightPosPtr = copy1dArray(lightPos, 'HEAPF32', _scratchThreeFloatsBPtr);
|
D | canvaskit_bindings.cpp | 845 const SkVector3* lightPos = reinterpret_cast<const SkVector3*>(lightPosPtr); in EMSCRIPTEN_BINDINGS() local 847 return SkShadowUtils::GetLocalBounds(ctm, path, *zPlaneParams, *lightPos, lightRadius, in EMSCRIPTEN_BINDINGS() 1100 const SkVector3* lightPos = reinterpret_cast<const SkVector3*>(lightPosPtr); in EMSCRIPTEN_BINDINGS() local 1102 SkShadowUtils::DrawShadow(&self, path, *zPlaneParams, *lightPos, lightRadius, in EMSCRIPTEN_BINDINGS()
|
/third_party/skia/tools/perf-canvaskit-puppeteer/ |
D | canvas_perf.js | 243 ctx.lightPos = [250,150,300]; 249 ctx.canvas.drawShadow(ctx.path, ctx.zPlaneParams, ctx.lightPos, ctx.lightRadius,
|
/third_party/skia/site/docs/user/modules/ |
D | canvaskit.md | 551 uniform float3 lightPos; 566 float3 light_dir = normalize(lightPos - plane_pos);
|
/third_party/skia/modules/canvaskit/npm_build/types/ |
D | index.d.ts | 144 lightPos: InputVector3, lightRadius: number, flags: number, 1381 drawShadow(path: Path, zPlaneParams: InputVector3, lightPos: InputVector3, lightRadius: number,
|