Mandelbrot mit JSXGraph
Aus Wiki1
(Unterschied zwischen Versionen)
| Zeile 11: | Zeile 11: | ||
const sliderIter = board.create('slider', [[-2.3, 1.3], [0.5, 1.3], [10, 50, 300]], { | const sliderIter = board.create('slider', [[-2.3, 1.3], [0.5, 1.3], [10, 50, 300]], { | ||
name:'Tiefe', | name:'Tiefe', | ||
| - | snapWidth:1 | + | snapWidth:1, |
| + | fixed:true | ||
}); | }); | ||
| Zeile 17: | Zeile 18: | ||
const sliderZoom = board.create('slider', [[-2.3, 1.2], [0.5, 1.2], [1, 1, 50]], { | const sliderZoom = board.create('slider', [[-2.3, 1.2], [0.5, 1.2], [1, 1, 50]], { | ||
name:'Zoom', | name:'Zoom', | ||
| - | snapWidth:1 | + | snapWidth:1, |
| + | fixed:true | ||
}); | }); | ||
| Zeile 24: | Zeile 26: | ||
const div = document.getElementById('jxgbox'); | const div = document.getElementById('jxgbox'); | ||
const canvas = document.createElement('canvas'); | const canvas = document.createElement('canvas'); | ||
| - | canvas.width = | + | canvas.width = 600; |
canvas.height = 600; | canvas.height = 600; | ||
canvas.style.position = 'absolute'; | canvas.style.position = 'absolute'; | ||
Version vom 13:14, 22. Dez. 2025
Mit den Schiebereglern können Iterations-Tiefe und Zoom gesteuert werden. Mit der Maus+linke Maustaste kann der Bildausschnitt verschoben werden.
