{
  "$schema": "../../schema.json",
  "id": "water",
  "type": "background",
  "title": "Water",
  "summary": "Water-like surface distortion with natural caustic realism.",
  "tags": [
    "background",
    "water",
    "lively",
    "dark",
    "image"
  ],
  "version": "1.0.0",
  "license": "MIT",
  "params": [
    {
      "name": "fit",
      "type": "string",
      "default": "cover",
      "description": "How to fit the rendered shader into the canvas dimensions (0 = none, 1 = contain, 2 = cover)",
      "group": "advanced"
    },
    {
      "name": "scale",
      "type": "number",
      "default": 1,
      "description": "zoom of the pattern",
      "min": 0.1,
      "max": 4,
      "step": 0.01,
      "group": "main"
    },
    {
      "name": "colorBack",
      "type": "color",
      "default": "#000000",
      "description": "background color behind the effect",
      "group": "main"
    },
    {
      "name": "colorHighlight",
      "type": "color",
      "default": "#ffffff",
      "description": "Highlight color in RGBA, needs highlights > 0",
      "group": "advanced"
    },
    {
      "name": "highlights",
      "type": "number",
      "default": 0.07,
      "description": "Coloring added over image/background following caustic shape, needs colorHighlight alpha > 0",
      "min": 0,
      "max": 1,
      "step": 0.005,
      "group": "main"
    },
    {
      "name": "layering",
      "type": "number",
      "default": 0.5,
      "description": "Power of 2nd layer of caustic distortion, needs caustic or highlights > 0",
      "min": 0,
      "max": 1,
      "step": 0.005,
      "group": "main"
    },
    {
      "name": "edges",
      "type": "number",
      "default": 0.8,
      "description": "Caustic distortion power on the image edges, needs image and caustic > 0",
      "min": 0,
      "max": 1,
      "step": 0.005,
      "group": "main"
    },
    {
      "name": "waves",
      "type": "number",
      "default": 0.3,
      "description": "Additional distortion based on simplex noise, independent from caustic",
      "min": 0,
      "max": 1,
      "step": 0.005,
      "group": "advanced"
    },
    {
      "name": "caustic",
      "type": "number",
      "default": 0.12,
      "description": "Power of caustic distortion, needs image",
      "min": 0,
      "max": 1,
      "step": 0.005,
      "group": "advanced"
    },
    {
      "name": "size",
      "type": "number",
      "default": 1,
      "description": "dot or pattern size",
      "min": 0.01,
      "max": 7,
      "step": 0.03495,
      "group": "advanced"
    },
    {
      "name": "speed",
      "type": "number",
      "default": 0.6,
      "description": "animation speed (0 = still)",
      "min": 0,
      "max": 3,
      "step": 0.01,
      "group": "main"
    }
  ],
  "install": {
    "kind": "shader-set",
    "entry": {
      "shader": "Water",
      "props": {
        "fit": "cover",
        "scale": 1,
        "colorBack": "#000000",
        "colorHighlight": "#ffffff",
        "highlights": 0.07,
        "layering": 0.5,
        "edges": 0.8,
        "waves": 0.3,
        "caustic": 0.12,
        "size": 1,
        "speed": 0.6
      },
      "image": "assets/materials/material-a.jpg"
    }
  },
  "files": [
    {
      "path": "brand/assets/materials/material-a.jpg",
      "url": "https://paper-motion.vercel.app/files/material-a.jpg",
      "from": "registry/_assets/materials/material-a.jpg"
    }
  ],
  "requires": {
    "engine": ">=0.2.0"
  },
  "usage": "import { loadBrand } from 'paper-motion/brand';\n\nconst B = await loadBrand();\n// a full-frame element <div id=\"bg\"></div> behind everything:\nB.shader(s, '#bg', 'water');",
  "notes": [
    "Paper shader `Water` (animated).",
    "Uses an image (installed to brand/assets/materials/); swap `image` for your own picture or texture."
  ],
  "preview": {
    "poster": "previews/water.jpg"
  },
  "colors": [
    "#000000"
  ],
  "mode": "dark",
  "motion": "lively",
  "mood": [
    "calm",
    "luxury"
  ],
  "when": [
    "a hero moment where the material is the message",
    "a dark calm piece",
    "you have a photo or a logo to run through it"
  ]
}