{
  "name": "Blue Diamond Hologram",
  "dimension": "3d",
  "slot": "action_bar",
  "width": 256,
  "height": 128,
  "textBaseline": 128,
  "placement": {
    "x": 0,
    "y": 0
  },
  "shapes": [],
  "texts": [],
  "heads": [],
  "images": [],
  "bars": [],
  "triggers": [],
  "world": {
    "glsl": "float diamondField(vec3 p) {\n    float angle = atan(p.z,p.x);\n    float sector = 0.785398163;\n    float a = floor(angle / sector + 0.5) * sector;\n    float oct = dot(p.xz,vec2(cos(a),sin(a)));\n    float lower = (oct - 0.73 * (p.y + 0.74)) / 1.238;\n    float upper = (oct + 0.70 * p.y - 0.64) / 1.221;\n    return max(max(lower,upper),p.y-0.57);\n}\nvec3 diamondNormal(vec3 p) {\n    vec2 e=vec2(0.001,0.0);\n    return normalize(vec3(diamondField(p+e.xyy)-diamondField(p-e.xyy),diamondField(p+e.yxy)-diamondField(p-e.yxy),diamondField(p+e.yyx)-diamondField(p-e.yyx)));\n}\nvec4 object(vec3 ro, vec3 rd, float t0, float t1, float time, vec3 light, inout float depth) {\n    mat2 rotation=rpw_rot(time*0.24);\n    ro.xz=rotation*ro.xz; rd.xz=rotation*rd.xz;\n    float bob=0.025*sin(time*1.5);\n    ro.y-=bob;\n    vec3 col=vec3(0.0); float alpha=0.0;\n    float t=t0; bool hit=false;\n    for(int i=0;i<72;i++) {\n        vec3 p=ro+rd*t;\n        float d=diamondField(p);\n        if(d<0.0015) {hit=true;break;}\n        t+=max(d*0.85,0.001);\n        if(t>t1) break;\n    }\n    if(!hit) return vec4(0.0);\n    depth=t;\n    for(int wall=0;wall<2;wall++) {\n        vec3 p=ro+rd*t;\n        vec3 n=diamondNormal(p);\n        float facing=abs(dot(n,rd));\n        float rim=pow(1.0-facing,3.0);\n        float ang=atan(p.z,p.x);\n        float faceAng=floor(ang/0.785398163+0.5)*0.785398163;\n        float edgeAng=abs(ang-faceAng);\n        float radial=length(p.xz);\n        float edgeDist=(0.392699082-edgeAng)*radial;\n        float edge=1.0-smoothstep(0.003,0.016,edgeDist);\n        float belt=1.0-smoothstep(0.003,0.014,abs(p.y-0.0685));\n        float oct=dot(p.xz,vec2(cos(faceAng),sin(faceAng)));\n        float table=(1.0-smoothstep(0.003,0.012,abs(p.y-0.57)))*(1.0-smoothstep(0.003,0.016,abs(oct-0.241)));\n        if(p.y>0.568) edge*=smoothstep(0.225,0.245,oct);\n        edge=max(edge,max(belt,table));\n        float scan=pow(0.5+0.5*sin(p.y*260.0-time*10.0),6.0);\n        float dropout=0.70+0.30*smoothstep(-0.5,0.3,sin(p.y*59.0+time*19.0)*sin(time*13.0+p.y*17.0));\n        float sweep=exp(-pow((p.y-(mod(time*0.28,1.6)-0.8))/0.065,2.0));\n        float flicker=0.86+0.10*sin(time*31.0)+0.04*sin(time*73.0);\n        float facet=0.45+0.55*max(0.0,dot(n,normalize(vec3(0.4,0.8,0.3))));\n        vec3 c=vec3(0.015,0.20,0.95)*facet+vec3(0.025,0.42,1.25)*(scan*0.85+rim*0.5)+vec3(0.16,0.68,1.5)*(edge*1.5+sweep*0.7);\n        float a=clamp((0.17+0.22*scan+0.57*edge+0.20*rim+0.17*sweep)*flicker*dropout,0.0,0.92);\n        col+=(1.0-alpha)*c*a; alpha+=(1.0-alpha)*a;\n        if(wall==0) {\n            t+=0.009;\n            for(int j=0;j<64;j++) {\n                float d=diamondField(ro+rd*t);\n                if(d>0.0) break;\n                t+=max(-d*0.85,0.002);\n                if(t>t1) break;\n            }\n            if(t>t1) break;\n        }\n    }\n    return vec4(col/max(alpha,0.0001),alpha);\n}",
    "prompt": "a blue sci-fi hologram of a diamond, flickering scanlines",
    "size": 3,
    "summary": "A translucent electric-blue diamond slowly rotates and hovers, with luminous facet edges, scrolling scanlines, and flickering signal bands."
  }
}