Improve demos for better screenshots, cleanup
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import org.openrndr.application
|
||||
import org.openrndr.color.ColorRGBa
|
||||
import org.openrndr.extensions.SingleScreenshot
|
||||
import org.openrndr.extra.shapes.RoundedRectangle
|
||||
import org.openrndr.extra.shapes.regularStar
|
||||
import kotlin.math.cos
|
||||
import kotlin.math.sin
|
||||
@@ -17,12 +16,12 @@ fun main() = application {
|
||||
extend {
|
||||
drawer.fill = ColorRGBa.PINK
|
||||
drawer.stroke = ColorRGBa.WHITE
|
||||
val radius0 = cos(seconds) * 50.0 + 130.0
|
||||
val radius1 = sin(seconds) * 50.0 + 130.0
|
||||
val radius0 = cos(seconds + 2) * 50.0 + 130.0
|
||||
val radius1 = sin(seconds + 2) * 50.0 + 130.0
|
||||
|
||||
val star = regularStar(5, radius0, radius1)
|
||||
|
||||
drawer.translate(width/2.0, height / 2.0)
|
||||
drawer.translate(width / 2.0, height / 2.0)
|
||||
drawer.rotate(seconds * 45.0)
|
||||
drawer.contour(star)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user