Demos: ensure all use fun main() = application {

- Adjust some demo window sizes.
- Replace Random.double by Double.uniform
- Tweak some demos so screenshots look more interesting
This commit is contained in:
Abe Pazos
2025-01-26 20:57:04 +01:00
parent 1975a820fc
commit c8f7dd52c6
116 changed files with 2889 additions and 2942 deletions

View File

@@ -201,38 +201,36 @@ import org.openrndr.extra.fx.edges.EdgesWork
import org.openrndr.extra.gui.GUI
import org.openrndr.math.Vector2
fun main() {
application {
configure {
width = 768
height = 768
}
program {
val w2 = width / 2.0
val h2 = height / 2.0
fun main() = application {
configure {
width = 768
height = 768
}
program {
val w2 = width / 2.0
val h2 = height / 2.0
val c = compose {
draw {
drawer.fill = ColorRGBa.PINK
drawer.circle(width / 2.0, height / 2.0, 10.0)
}
layer {
blend(Add())
val c = compose {
draw {
drawer.fill = ColorRGBa.PINK
drawer.circle(width / 2.0, height / 2.0, 10.0)
drawer.circle(width / 2.0, height / 2.0, 100.0)
}
layer {
blend(Add())
draw {
drawer.circle(width / 2.0, height / 2.0, 100.0)
}
post(ApproximateGaussianBlur()) {
window = 10
sigma = Math.cos(seconds * 10.0) * 10.0 + 10.0
}
post(ApproximateGaussianBlur()) {
window = 10
sigma = Math.cos(seconds * 10.0) * 10.0 + 10.0
}
}
extend(gui)
extend {
c.draw(drawer)
}
}
extend(gui)
extend {
c.draw(drawer)
}
}
}