LordXido commited on
Commit
0532e1f
·
verified ·
1 Parent(s): 487c0eb

Update CodexQuantum3D_Engine.py

Browse files
Files changed (1) hide show
  1. CodexQuantum3D_Engine.py +13 -15
CodexQuantum3D_Engine.py CHANGED
@@ -1,26 +1,24 @@
1
- # CodexQuantum3D_Engine.py
2
-
3
- import numpy as np
4
  from PIL import Image, ImageDraw
5
 
6
- def simulate_quantum_visual(width=512, height=512, t=0.0):
7
- """
8
- Minimal safe quantum-visual stub.
9
- Generates a symbolic field image so the Space boots cleanly.
10
- """
11
 
12
  img = Image.new("RGB", (width, height), "black")
13
  draw = ImageDraw.Draw(img)
14
 
15
  cx, cy = width // 2, height // 2
16
 
17
- for r in range(10, min(cx, cy), 20):
18
- phase = int((r + t * 50) % 255)
19
- color = (phase, 255 - phase, (phase * 2) % 255)
20
- draw.ellipse(
21
- (cx - r, cy - r, cx + r, cy + r),
22
- outline=color,
23
- width=2
 
24
  )
 
25
 
26
  return img
 
1
+ import math
 
 
2
  from PIL import Image, ImageDraw
3
 
4
+ def simulate_quantum_visual(seed, width=512, height=512):
5
+ # Convert any input into a deterministic numeric phase
6
+ phase = sum(ord(c) for c in str(seed)) % 360
 
 
7
 
8
  img = Image.new("RGB", (width, height), "black")
9
  draw = ImageDraw.Draw(img)
10
 
11
  cx, cy = width // 2, height // 2
12
 
13
+ for r in range(10, min(cx, cy), 8):
14
+ theta = math.radians((r + phase) % 360)
15
+ x = int(cx + r * math.cos(theta))
16
+ y = int(cy + r * math.sin(theta))
17
+ color = (
18
+ (r * 3 + phase) % 255,
19
+ (r * 7) % 255,
20
+ (r * 11) % 255
21
  )
22
+ draw.ellipse((x-2, y-2, x+2, y+2), fill=color)
23
 
24
  return img