Coder Social home page Coder Social logo

openrndr / openrndr-guide Goto Github PK

View Code? Open in Web Editor NEW
21.0 21.0 23.0 236.22 MB

Source files for the OPENRNDR guide

Home Page: https://guide.openrndr.org

C# 0.09% HTML 0.70% Ruby 0.19% SCSS 1.11% Shell 0.37% Kotlin 97.54%
creative-coding gradle jvm kotlin maven

openrndr-guide's Introduction

OPENRNDR

Download Build status

A Kotlin/JVM and Kotlin/JS library for creative coding, real-time and interactive graphics. Can currently be used on Windows, macOS and Linux/x64 to create standalone graphical applications.

Basics and use are further explained in the OPENRNDR guide.

Repository structure

module description
openrndr-animatable Tooling for interactive animations
openrndr-application Application and Program classes
openrndr-binpack Binpacking algorithm used for texture atlasses
openrndr-color Color spaces
openrndr-dds DirectDraw Surface file (.dds) loader
openrndr-demos A collection of small in-repository demos
openrndr-draw Drawing primitives
openrndr-event Event classes
openrndr-extensions Built-in OPENRNDR extensions
openrndr-filter Built-in filters
openrndr-js Kotlin/JS specific modules
openrndr-jvm Kotlin/JVM specific modules
openrndr-math Math functions and classes
openrndr-nullgl Mock graphics back-end
openrndr-shape Classes and functions for working with 2D shapes
openrndr-svg Loading and saving SVG
openrndr-utils Assorted utilities

Using OPENRNDR

You are advised to use the OPENRNDR template which provides a quick start to using the library.

OPENRNDR's Javascript/WebGL is still experimental and under development. However, if you feel like trying it you should use the OPENRNDR JS template.

Building OPENRNDR

After cloning the repository, make sure you have Java 11 or newer installed and run the following command:

./gradlew build

This should start the build process, which will take some time to complete.

Note that OPENRNDR does not depend on anything that is not on Maven Central, builds should be easy and predictable.

Installing OPENRNDR as Maven artifacts

In order to use the OPENRNDR build from your applications one has to install OPENRNDR's Maven artifacts in the local Maven repository.

./gradlew publishToMavenLocal snapshot

A more detailed walk-through of building, publishing to Maven local and contributing can be found in the wiki.

Community

Visit the OPENRNDR website for the latest news on OPENRNDR, showcases and events

Join us on the OPENRNDR forum for questions, tutorials and showcases.

Reach us more directly on the OPENRNDR Slack.

openrndr-guide's People

Contributors

alessiofaieta avatar dependabot[bot] avatar edwinrndr avatar ellenspertus avatar hamoid avatar krksgbr avatar morisil avatar nfletton avatar vechro avatar yvee1 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

openrndr-guide's Issues

Missing ':run' in explanation howto run tutorials?

Hi - I think there is a ':run' missing in the last sentence of

https://guide.openrndr.org/#/02_Getting_Started_with_OPENRNDR/C01_TutorialRepository?id=running-tutorials-from-the-command-line

You can run an individual example from the tutorial repository from the command line using ./gradlew :<project-name> โ†’ You can run an individual example from the tutorial repository from the command line using ./gradlew :<project-name>:run

At least for me this is required to actually run a tutorial.

Dead links

There are a number of dead links floating around online to pages in the guide that are no longer there.

For example, the Tutorials link on the OpenRNDR homepage itself is dead. So are old links in Github issues (e.g. this issue).

It'd be great if the guide automatically redirected from the old links to the new links. Alternatively, it could at least show search results for missing pages based on the slug.

how to preview or build static files?

hello
wanna translate guide document to korean. and want to preview results as follow here but there is no task, build directory under the repository.

did I miss something of thouse files are missing in this repo?

thank you.

Is there a way to write a png file for every frame?

I'd like to create a PNG file for each frame within the extend {} block until it reaches a certain number of frames.

I tried using the Screenshots extension but I find it a bit hard to control. I am looking for something similar to the VideoWriter that works within the extend draw loop block but for pngs.

How to access raw pixel values?

I have a quite specific usecase, where I need to compute similarity between two images:

var similarity = 0.0
for (x in 0..width) for (y in 0..height) {
  euclid_distance(image0.rgb(x,y), image1.rgb(x,y)) // image 0,1 are composite shapes or svg
}
return similarity / width*height

I wasn't able to find .rgb(x,y) in the guide or the API, is there anything like it?
Moreover, I need this operation to be super fast, so the call to .rgb should have zero overhead. Also I wonder if openrdnr could allow me to implement it on GPU to get some further speedups.

Fonts not found

When trying to draw some text as explained in https://guide.openrndr.org/#/04_Drawing_basics/C02_Text using the current master of https://github.com/openrndr/openrndr-template with

fun main() = application {
    configure {
        width = 800
        height = 800
    }
    program  {
        val font = loadFont("file:data/IBMPlexMono-Bold.ttf", 24.0)

        extend {
            drawer.fontMap = font
            drawer.fill = ColorRGBa.WHITE
            drawer.text("Counter $seconds", width / 2.0 - 100.0, height / 2.0)
        }
    }
}

it fails with

Exception in thread "main" java.io.FileNotFoundException: data\IBMPlexMono-Bold.ttf (The system cannot find the file specified)

It would be great if example-template (or one of the dependencies) could either somehow include these fonts, or the doc-example would use a default system font.

I managed to solve the issue by downloading the fonts from https://fonts.google.com/specimen/IBM+Plex+Mono

docsify reformats code producing long lines

When I run the docsify gradle task after editing a guide page, the texts are indeed updated, but the part inside the code block stays unchanged for some reason.

I tried deleting

  • build/classes/kotlin/GeneratedExamples/examples/04_Drawing_basics/C05_ComplexShapes005Kt.class
  • build/dokgen/generated/examples-export/04_Drawing_basics/C05_ComplexShapes005.kt
  • build/dokgen/generated/examples/04_Drawing_basics/C05_ComplexShapes005.kt

and running docsify again but somehow the code in the html page does not change.

[Topic] How to make use of Bytebuffers?

A small entry on how to use them, reading, converting to indented type and why they could be a better choice than using a ColorBufferShadow (when it's an alternative).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.