베네치안 블라인드 와이프

Venetian Blinds

평행한 띠가 블라인드처럼 닫히며 입력 화면을 지웁니다.

다른 이름: VenetianBlindsblinds transition

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

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

React
// WebGPU 를 지원하는 브라우저에서만 그립니다.
// /samples/… 는 이 사이트의 샘플 파일입니다. 내 프로젝트의 이미지·영상 경로로 바꾸세요.
import { Shader, ImageTexture, VenetianBlinds } from 'shaders/react'

export default function ShaderEffect() {
  return (
    <Shader style={{ width: '100%', height: 320 }} disableTelemetry>
      <ImageTexture
        objectFit="cover"
        url="/samples/still.jpg" />
      <VenetianBlinds
        progress={{
          type: "auto-animate",
          mode: "ping-pong",
          outputMin: 0,
          outputMax: 1,
          speed: 0.5
        }}>
        <ImageTexture
          objectFit="cover"
          url="/samples/photo.jpg" />
      </VenetianBlinds>
    </Shader>
  )
}
Vue
<!-- WebGPU 를 지원하는 브라우저에서만 그립니다. -->
<!-- /samples/… 는 이 사이트의 샘플 파일입니다. 내 프로젝트의 이미지·영상 경로로 바꾸세요. -->
<script setup lang="ts">
import { Shader, ImageTexture, VenetianBlinds } from 'shaders/vue'
</script>

<template>
  <Shader style="width: 100%; height: 320px" :disable-telemetry="true">
    <ImageTexture
      object-fit="cover"
      url="/samples/still.jpg"/>
    <VenetianBlinds
      :progress="{
        type: 'auto-animate',
        mode: 'ping-pong',
        outputMin: 0,
        outputMax: 1,
        speed: 0.5
      }">
      <ImageTexture
        object-fit="cover"
        url="/samples/photo.jpg"/>
    </VenetianBlinds>
  </Shader>
</template>
Svelte
<!-- WebGPU 를 지원하는 브라우저에서만 그립니다. -->
<!-- /samples/… 는 이 사이트의 샘플 파일입니다. 내 프로젝트의 이미지·영상 경로로 바꾸세요. -->
<script>
  import { Shader, ImageTexture, VenetianBlinds } from 'shaders/svelte'
</script>

<Shader style="width: 100%; height: 320px" disableTelemetry>
  <ImageTexture
    objectFit="cover"
    url="/samples/still.jpg" />
  <VenetianBlinds
    progress={{
      type: "auto-animate",
      mode: "ping-pong",
      outputMin: 0,
      outputMax: 1,
      speed: 0.5
    }}>
    <ImageTexture
      objectFit="cover"
      url="/samples/photo.jpg" />
  </VenetianBlinds>
</Shader>
Solid
// WebGPU 를 지원하는 브라우저에서만 그립니다.
// /samples/… 는 이 사이트의 샘플 파일입니다. 내 프로젝트의 이미지·영상 경로로 바꾸세요.
import { Shader, ImageTexture, VenetianBlinds } from 'shaders/solid'

export default function ShaderEffect() {
  return (
    <Shader style={{ width: '100%', height: '320px' }} disableTelemetry>
      <ImageTexture
        objectFit="cover"
        url="/samples/still.jpg" />
      <VenetianBlinds
        progress={{
          type: "auto-animate",
          mode: "ping-pong",
          outputMin: 0,
          outputMax: 1,
          speed: 0.5
        }}>
        <ImageTexture
          objectFit="cover"
          url="/samples/photo.jpg" />
      </VenetianBlinds>
    </Shader>
  )
}
JavaScript
// WebGPU 를 지원하는 브라우저에서만 그립니다.
// /samples/… 는 이 사이트의 샘플 파일입니다. 내 프로젝트의 이미지·영상 경로로 바꾸세요.
// <canvas id="canvas" style="width:100%;height:320px"></canvas> 가 페이지에 있어야 한다
import { createShader } from 'shaders/js'

const shader = await createShader(document.getElementById("canvas"), {
  components: [
    {
      type: 'ImageTexture',
      props: {
        objectFit: 'cover',
        url: '/samples/still.jpg',
      },
    },
    {
      type: 'VenetianBlinds',
      props: {
        progress: {
          type: 'auto-animate',
          mode: 'ping-pong',
          outputMin: 0,
          outputMax: 1,
          speed: 0.5
        },
      },
      children: [
        {
          type: 'ImageTexture',
          props: {
            objectFit: 'cover',
            url: '/samples/photo.jpg',
          },
        },
      ],
    }
  ]
}, { disableTelemetry: true })

속성(props) · VenetianBlinds

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

이름값기본값범위·선택지설명(원문)
progressProgress데모에서 자동으로 오가는 값 — 움직이면 그 값에 고정됩니다0.50 – 1 (step 0.01)How far the blinds have closed (0 = fully visible, 1 = fully wiped away)
angleAngle00 – 360 (step 1)Orientation of the strips in degrees
stripCountStrips52 – 60 (step 1)Number of strips across the frame
featherFeather0.150 – 1 (step 0.01)Softness of each closing strip edge
invertInvertfalse—Close each strip from the opposite edge

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

창문 블라인드가 내려오듯 평행한 띠가 차례로 화면을 가립니다. 반복 간격이 균일해 정돈된 느낌을 줍니다.

`progress`는 기본 0.5, 범위 0–1입니다. `angle`은 기본 0도, 범위 0–360도로 띠 방향을 돌립니다. `stripCount`는 기본 5, 범위 2–60으로 띠 수를 정하고, `feather`는 기본 0.15, 범위 0–1로 각 경계의 부드러움을 조절합니다. `invert`는 기본 false로 각 띠가 반대쪽에서 닫히게 합니다.

효과 아래에 이미지나 영상을 두세요. 새 장면을 아래 레이어에 추가해 progress를 애니메이션할 수 있습니다. 띠 수가 늘면 반복이 촘촘해져 글자와 얼굴이 줄무늬로 끊겨 보일 수 있으니 배경이나 짧은 컷에 쓰세요.

언제 쓰나

규칙적인 줄무늬로 장면을 교체하거나, 블라인드가 열리고 닫히는 인트로, 그래픽 배경 전환에 좋습니다. 얼굴과 작은 글자를 띠 사이에 온전히 남겨야 한다면 피하세요.

페이지로 열기 ↗