[orx-poisson-fill] Fix demos
This commit is contained in:
@@ -1,19 +1,30 @@
|
|||||||
|
import ScreenshotsHelper.collectScreenshots
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
demo {
|
val main by getting { }
|
||||||
|
val demo by creating {
|
||||||
java {
|
java {
|
||||||
srcDirs = ["src/demo/kotlin"]
|
srcDir("src/demo/kotlin")
|
||||||
compileClasspath += main.getCompileClasspath()
|
compileClasspath += main.getCompileClasspath()
|
||||||
runtimeClasspath += main.getRuntimeClasspath()
|
runtimeClasspath += main.getRuntimeClasspath()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
collectScreenshots(project, demo) { }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
val openrndrVersion: String by rootProject.extra
|
||||||
|
val openrndrOS: String by rootProject.extra
|
||||||
|
|
||||||
|
val demoImplementation by configurations.getting {}
|
||||||
|
val demoRuntimeOnly by configurations.getting {}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation project(":orx-fx")
|
implementation(project(":orx-fx"))
|
||||||
implementation project(":orx-noise")
|
implementation(project(":orx-noise"))
|
||||||
implementation("org.openrndr:openrndr-filter:$openrndrVersion")
|
implementation("org.openrndr:openrndr-filter:$openrndrVersion")
|
||||||
demoImplementation("org.openrndr:openrndr-application:$openrndrVersion")
|
demoImplementation("org.openrndr:openrndr-application:$openrndrVersion")
|
||||||
demoImplementation("org.openrndr:openrndr-extensions:$openrndrVersion")
|
demoImplementation("org.openrndr:openrndr-extensions:$openrndrVersion")
|
||||||
demoRuntimeOnly("org.openrndr:openrndr-gl3:$openrndrVersion")
|
demoRuntimeOnly("org.openrndr:openrndr-gl3:$openrndrVersion")
|
||||||
demoRuntimeOnly("org.openrndr:openrndr-gl3-natives-$openrndrOS:$openrndrVersion")
|
demoRuntimeOnly("org.openrndr:openrndr-gl3-natives-$openrndrOS:$openrndrVersion")
|
||||||
demoImplementation(sourceSets.getByName("main").output)
|
demoImplementation(sourceSets.getByName("main").output)
|
||||||
}
|
}
|
||||||
@@ -16,19 +16,13 @@ import org.openrndr.poissonfill.PoissonFill
|
|||||||
import org.openrndr.shape.Rectangle
|
import org.openrndr.shape.Rectangle
|
||||||
import kotlin.math.sin
|
import kotlin.math.sin
|
||||||
|
|
||||||
data class Thing(val color: ColorRGBa, var pos: Polar, val speed: Polar)
|
|
||||||
|
|
||||||
fun main() {
|
fun main() {
|
||||||
|
data class Thing(val color: ColorRGBa, var pos: Polar, val speed: Polar)
|
||||||
|
|
||||||
|
|
||||||
application {
|
application {
|
||||||
program {
|
program {
|
||||||
|
|
||||||
// -- this block is for automation purposes only
|
|
||||||
if (System.getProperty("takeScreenshot") == "true") {
|
|
||||||
extend(SingleScreenshot()) {
|
|
||||||
this.outputFile = System.getProperty("screenshotPath")
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
val dry = renderTarget(width, height) {
|
val dry = renderTarget(width, height) {
|
||||||
colorBuffer(type = ColorType.FLOAT32)
|
colorBuffer(type = ColorType.FLOAT32)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user