mirror of
https://github.com/csd4ni3l/fractal-viewer.git
synced 2026-01-01 12:13:43 +01:00
change to template-based shaders, move fractal chooser to menus, add
burning ship and newton fractal, add escape radius to more fractals
This commit is contained in:
@@ -2,7 +2,7 @@ import arcade, arcade.gui, pyglet, json
|
||||
|
||||
from PIL import Image
|
||||
|
||||
from game.shader import create_mandelbrot_shader
|
||||
from game.shader import create_iter_calc_shader
|
||||
from utils.constants import menu_background_color, button_style, mandelbrot_initial_real_min, mandelbrot_initial_real_max, mandelbrot_initial_imag_min, mandelbrot_initial_imag_max
|
||||
from utils.preload import button_texture, button_hovered_texture
|
||||
|
||||
@@ -25,7 +25,7 @@ class MandelbrotViewer(arcade.gui.UIView):
|
||||
def on_show_view(self):
|
||||
super().on_show_view()
|
||||
|
||||
self.shader_program, self.mandelbrot_image = create_mandelbrot_shader(self.window.width, self.window.height, self.settings_dict.get("mandelbrot_precision", "Single").lower())
|
||||
self.shader_program, self.mandelbrot_image = create_iter_calc_shader("mandelbrot", self.window.width, self.window.height, self.settings_dict.get("mandelbrot_precision", "Single").lower(), int(self.settings_dict.get("mandelbrot_n", 2)), int(self.settings_dict.get("mandelbrot_escape_radius", 2)))
|
||||
|
||||
self.mandelbrot_sprite = pyglet.sprite.Sprite(img=self.mandelbrot_image)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user