성에 낀 얼음

Frost

두께감 있는 얼음 표면에 가장자리부터 안쪽으로 번지는 미세한 성에 결정이 생깁니다.

다른 이름: FrostFrosted iceFrozen glass

WebGPU 를 지원하는 브라우저에서 움직입니다

이 기기에서는 데모를 그리지 못해 정지 화면을 보여 줍니다

React
// WebGPU 를 지원하는 브라우저에서만 그립니다.
import { Shader, Frost } from 'shaders/react'

export default function ShaderEffect() {
  return (
    <Shader style={{ width: '100%', height: 320 }} disableTelemetry>
      <Frost />
    </Shader>
  )
}
Vue
<!-- WebGPU 를 지원하는 브라우저에서만 그립니다. -->
<script setup lang="ts">
import { Shader, Frost } from 'shaders/vue'
</script>

<template>
  <Shader style="width: 100%; height: 320px" :disable-telemetry="true">
    <Frost/>
  </Shader>
</template>
Svelte
<!-- WebGPU 를 지원하는 브라우저에서만 그립니다. -->
<script>
  import { Shader, Frost } from 'shaders/svelte'
</script>

<Shader style="width: 100%; height: 320px" disableTelemetry>
  <Frost />
</Shader>
Solid
// WebGPU 를 지원하는 브라우저에서만 그립니다.
import { Shader, Frost } from 'shaders/solid'

export default function ShaderEffect() {
  return (
    <Shader style={{ width: '100%', height: '320px' }} disableTelemetry>
      <Frost />
    </Shader>
  )
}
JavaScript
// WebGPU 를 지원하는 브라우저에서만 그립니다.
// <canvas id="canvas" style="width:100%;height:320px"></canvas> 가 페이지에 있어야 한다
import { createShader } from 'shaders/js'

const shader = await createShader(document.getElementById("canvas"), {
  components: [
    {
      type: 'Frost',
    }
  ]
}, { disableTelemetry: true })

속성(props) · Frost

값을 바꾸면 위 데모와 코드 탭에 바로 반영됩니다. 설명은 라이브러리 레지스트리의 영어 원문(MIT)입니다.

이름값기본값범위·선택지설명(원문)
originOrigin코드에서 지정center—Reference edge the center position is measured from (center default). Lets you pin the shape relative to a corner or the canvas centre.
centerCenter
x0.5y0.5
{"x":0.5,"y":0.5}x, y: 0 – 1Center position of the ice shape
scaleScale10.1 – 3 (step 0.01)Scale of the ice shape (1 = default size)
rotationRotation00 – 360 (step 1)Rotation of the ice shape in degrees
iceColorIce Color#0597fc—Ice tint — the color deep ice saturates toward (thin edges stay near white)
ambientAmbient00 – 1 (step 0.01)Cool ambient fill so shadowed ice never goes black
edgeSoftnessEdge Softness0.050 – 1 (step 0.01)Softness of the shape boundary edge
densityDensity50 – 10 (step 0.01)Optical depth multiplier — how thick and deep the ice reads
absorptionAbsorption10 – 2 (step 0.01)Beer–Lambert absorption strength — higher drives a deeper blue-teal core
scatterScatter0.50 – 1 (step 0.01)Forward back-lit glow transmitted through thin ice
frostAmountFrost0.80 – 1 (step 0.01)Overall density of the rim frost crystals
frostDepthFrost Depth0.40 – 1 (step 0.01)How far the frost creeps inward from the rim
frostScaleFrost Scale10.3 – 4 (step 0.01)Crystal size — higher = finer, busier frost
frostRoughnessFrost Roughness31 – 5 (step 0.01)Feathery roughness of the frost crystal surface
sparkleSparkle0.50 – 1 (step 0.01)Tiny bright crystal glints catching the light at the rim
glossGloss0.60 – 1 (step 0.01)Surface sheen — the broad soft icy specular
fresnelFresnel0.020 – 1 (step 0.01)Cold rim glow on grazing surfaces
lightAngleLight Angle3000 – 360 (step 1)Key light direction in degrees
speedSpeed0.30 – 2 (step 0.01)Sparkle twinkle speed. 0 freezes the sparkle.
shapeShape코드에서 지정{"type":"sphere3D","radius":0.35}—Serialized shape configuration (JSON)
shapeSdfUrlshapeSdfUrl코드에서 지정—URL to a pre-generated SDF .bin file
shapeTypeshapeType코드에서 지정—Active SDF shape type

모든 컴포넌트 공통: blendMode · opacity · visible · maskSource/maskType · boundingBox · id

차가운 얼음 덩어리를 빛에 비춘 모습처럼, 두꺼운 부분은 깊고 푸르게 보이고 가장자리에는 성에가 맺힙니다.

`density`를 올리면 얼음이 더 두껍고 깊어 보이고, `absorption`은 중심부의 청록색을 진하게 만듭니다. `frostAmount`는 가장자리 결정의 양을, `frostDepth`는 성에가 안쪽으로 번지는 거리를 조절합니다.

자체적으로 얼음 재질을 만들므로 배경이나 도형과 겹쳐 카드·배지에 쓸 수 있습니다. 성에가 많은 표면 위에 작은 글자를 놓으면 질감과 서로 경쟁하므로 피하세요.

언제 쓰나

겨울 테마 배경, 얼음 배지, 차가운 느낌의 로고 포인트에 잘 맞습니다. 선명한 글자나 작은 아이콘이 주인공인 표면에는 피하세요.

페이지로 열기 ↗