Julia mit GameZero

This commit is contained in:
Sven Riwoldt
2026-01-10 18:12:48 +01:00
parent 3ed816dd67
commit 6acf34db5c

View File

@@ -1,8 +1,24 @@
#using Plots
#plot([1,2,3,4], [1,4,9,16], label="Quadratisch")
#= using Plots
plot([1,2,3,4], [1,4,9,16], label="Quadratisch") =#
using GLMakie
lines(0:0.01:10, sin)
#using GLMakie
#lines(0:0.01:10, sin)
#using Gadfly
#plot(x=1:10, y=(1:10).^2, Geom.line)
#plot(x=1:10, y=(1:10).^2, Geom.line)
using GameZero
using Colors
# Fenster-Einstellungen
WIDTH = 400
HEIGHT = 400
BACKGROUND = :black
# Die draw-Funktion wird jeden Frame aufgerufen
function draw()
# Zeichnet einen einzelnen Punkt (Pixel) bei x=200, y=200
# Da ein Pixel winzig ist, nutzt man oft ein kleines Rechteck
# oder die Point-Funktion.
draw(Rect(200, 200, 1, 1), :red, fill=true)
end