picrate 2.1.1-java → 2.4.1-java
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.mvn/extensions.xml +1 -1
- data/.mvn/wrapper/MavenWrapperDownloader.java +1 -1
- data/.mvn/wrapper/maven-wrapper.properties +2 -2
- data/CHANGELOG.md +11 -1
- data/README.md +3 -2
- data/Rakefile +2 -1
- data/docs/_includes/footer.html +1 -1
- data/docs/_layouts/post.html +1 -1
- data/docs/_methods/noise_mode.md +88 -0
- data/docs/_posts/2018-05-06-install_jruby.md +3 -3
- data/docs/_posts/2018-11-18-building-gem.md +3 -1
- data/docs/_posts/2020-05-11-getting_started_manjaro.md +19 -7
- data/docs/classes.md +2 -2
- data/docs/editors.md +2 -2
- data/docs/gems.md +3 -3
- data/docs/index.html +1 -1
- data/docs/libraries.md +2 -2
- data/docs/live.md +2 -2
- data/docs/magic.md +2 -2
- data/docs/methods.md +2 -2
- data/docs/modules.md +3 -3
- data/docs/objects.md +2 -2
- data/lib/picrate.rb +2 -1
- data/lib/picrate/app.rb +3 -2
- data/lib/picrate/helper_methods.rb +1 -1
- data/lib/picrate/native_folder.rb +1 -3
- data/lib/picrate/runner.rb +4 -4
- data/lib/picrate/version.rb +1 -1
- data/library/jcomplex/jcomplex.rb +1 -0
- data/library/pdf/pdf.rb +7 -0
- data/library/svg/svg.rb +7 -0
- data/mvnw +2 -2
- data/mvnw.cmd +2 -2
- data/picrate.gemspec +5 -3
- data/pom.rb +31 -9
- data/pom.xml +41 -6
- data/src/main/java/monkstone/FastNoiseModuleJava.java +127 -0
- data/src/main/java/monkstone/PicrateLibrary.java +3 -1
- data/src/main/java/monkstone/SmoothNoiseModuleJava.java +127 -0
- data/src/main/java/monkstone/complex/JComplex.java +252 -0
- data/src/main/java/monkstone/fastmath/DegLutTables.java +111 -0
- data/src/main/java/monkstone/fastmath/Deglut.java +41 -93
- data/src/main/java/monkstone/noise/OpenSimplex2F.java +914 -0
- data/src/main/java/monkstone/noise/OpenSimplex2S.java +1138 -0
- data/src/main/java/monkstone/vecmath/package-info.java +1 -1
- data/src/main/java/monkstone/vecmath/vec3/Vec3.java +1 -1
- data/src/main/java/monkstone/videoevent/package-info.java +1 -1
- data/src/main/java/processing/awt/ShimAWT.java +260 -94
- data/src/main/java/processing/core/PApplet.java +14664 -13450
- data/src/main/java/processing/core/PConstants.java +5 -5
- data/src/main/java/processing/core/PFont.java +1 -1
- data/src/main/java/processing/core/PGraphics.java +200 -201
- data/src/main/java/processing/core/PImage.java +539 -549
- data/src/main/java/processing/core/PShape.java +18 -18
- data/src/main/java/processing/core/PVector.java +23 -23
- data/src/main/java/processing/data/Table.java +4 -4
- data/src/main/java/processing/net/Client.java +13 -13
- data/src/main/java/processing/net/Server.java +5 -5
- data/src/main/java/processing/opengl/PGraphicsOpenGL.java +4 -4
- data/src/main/java/processing/pdf/PGraphicsPDF.java +529 -0
- data/src/main/java/processing/svg/PGraphicsSVG.java +378 -0
- data/test/deglut_spec_test.rb +2 -2
- data/test/respond_to_test.rb +0 -2
- data/vendors/Rakefile +31 -22
- data/vendors/geany.rb +3 -3
- metadata +26 -13
- data/src/main/java/monkstone/noise/SimplexNoise.java +0 -465
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cecab16a0e1abbcc010dc18037cba16121861f942a95aff9a898f9a5af4582ef
|
4
|
+
data.tar.gz: 3990c04c7008c66b54cf1af01d81980b7037ede67f6579bebb1294dd503a0260
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e365629d95d9077838b5a65300144fb817022dbfb21eda3754903f41aa29d39345986bc90d24021b9b1776f4f6b28206cab68ebda35f199502dcfe8a8ea1d8c0
|
7
|
+
data.tar.gz: 214a0c654b63653da787cf5afbd762420e3d6ae5d2e8ac9563b3b927ead5b7f3d10d7b63061cc1dea364511d3f39527296e2653e54dcd177cb87813666332210
|
data/.mvn/extensions.xml
CHANGED
@@ -20,7 +20,7 @@ import java.util.Properties;
|
|
20
20
|
|
21
21
|
public class MavenWrapperDownloader {
|
22
22
|
|
23
|
-
private static final String WRAPPER_VERSION = "0.5.
|
23
|
+
private static final String WRAPPER_VERSION = "0.5.6";
|
24
24
|
/**
|
25
25
|
* Default URL to download the maven-wrapper.jar from, if no 'downloadUrl' is provided.
|
26
26
|
*/
|
@@ -1,2 +1,2 @@
|
|
1
|
-
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.6.
|
2
|
-
wrapperUrl=https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.
|
1
|
+
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.6.3/apache-maven-3.6.3-bin.zip
|
2
|
+
wrapperUrl=https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar
|
data/CHANGELOG.md
CHANGED
@@ -1,4 +1,14 @@
|
|
1
|
-
v2.
|
1
|
+
v2.4.1 patch library loader, add PGS library examples.
|
2
|
+
|
3
|
+
v2.4.0 Refactor noise to two modules, FastNoise (default) & SmoothNoise, with terrain noise `:tnoise` option.
|
4
|
+
|
5
|
+
v2.3.0 Abandon Processing Value Noise in favour of OpenSimplex2, with choosable options. Added pdf library using iText5.
|
6
|
+
|
7
|
+
v2.2.0 Bump to latest JOGL-rc January 2021
|
8
|
+
|
9
|
+
v2.1.2 Bump to JRuby-9.2.14.0
|
10
|
+
|
11
|
+
v2.1.1 Bump to JRuby-9.2.13.0, include examples using ruby `clamp` in place of processing `constrain`, update to video-2.0 release, add run instruction to help
|
2
12
|
|
3
13
|
v2.1.0 Refactor how we configure geany so we can use ENV['HOME'] rather hard code config file. Bump to JRuby-9.2.12.0, include Sam Pottingers July 2020 staging changes.
|
4
14
|
|
data/README.md
CHANGED
@@ -14,12 +14,12 @@ jgem install picrate
|
|
14
14
|
|
15
15
|
Clone main branch:-
|
16
16
|
|
17
|
-
Requires java to build (and jogl-2.4.0-rc jars), but uses a maven wrapper so you don't need to install maven. Suggest build/test on regular linux box, but is designed for use on both RaspberryPI 3B+ and RaspberryPI4. Needs installed jruby to test/run.
|
17
|
+
Requires java to build (and [jogl-2.4.0-rc jars][jogl_jars]), but uses a maven wrapper so you don't need to install maven. Suggest build/test on regular linux box, but is designed for use on both RaspberryPI 3B+ and RaspberryPI4. Needs installed jruby to test/run.
|
18
18
|
|
19
19
|
```bash
|
20
20
|
cd PiCrate # or whatever you call it
|
21
21
|
rake # assumes an installed version of vanilla processing
|
22
|
-
jgem install picrate-2.
|
22
|
+
jgem install picrate-2.4.1-java.gem
|
23
23
|
|
24
24
|
```
|
25
25
|
To create a template sketch:-
|
@@ -59,3 +59,4 @@ jruby --dev my_sketch.rb # --dev flag speeds start-up
|
|
59
59
|
[propane]:https://ruby-processing.github.io/propane/
|
60
60
|
[vim]:https://github.com/ruby-processing/PiCrate/blob/master/docs/_editors/vim.md
|
61
61
|
[geany]:https://github.com/ruby-processing/PiCrate/blob/master/docs/_editors/geany.md
|
62
|
+
[jogl_jars]:https://jogamp.org/deployment/archive/rc/v2.4.0-rc-20210111/jar/
|
data/Rakefile
CHANGED
@@ -9,7 +9,7 @@ task default: %i[init compile install test gem]
|
|
9
9
|
# Currently depends on local jogl-2.4.0 jars on path ~/jogl24
|
10
10
|
desc 'Copy Jars'
|
11
11
|
task :init do
|
12
|
-
jogl24 = File.join(HOME_DIR, '
|
12
|
+
jogl24 = File.join(HOME_DIR, 'jogl-2.4-rc2021011')
|
13
13
|
opengl = Dir.entries(jogl24).grep(/amd64|armv6hf|aarch64/).select { |jar| jar =~ /linux/ }
|
14
14
|
opengl.concat %w[jogl-all.jar gluegen-rt.jar]
|
15
15
|
opengl.each do |gl|
|
@@ -19,6 +19,7 @@ end
|
|
19
19
|
|
20
20
|
desc 'Install'
|
21
21
|
task :install do
|
22
|
+
sh "mvn dependency:copy"
|
22
23
|
FileUtils.mv "target/picrate-#{PiCrate::VERSION}.jar", 'lib'
|
23
24
|
end
|
24
25
|
|
data/docs/_includes/footer.html
CHANGED
data/docs/_layouts/post.html
CHANGED
@@ -5,7 +5,7 @@ layout: default
|
|
5
5
|
|
6
6
|
<header class="post-header">
|
7
7
|
<h1 class="post-title">{{ page.title }}</h1>
|
8
|
-
<p class="post-meta">{{ page.date | date: "%b %-d, %Y" }}{% if page.author %} • {{ page.author }}{% endif %}{% if page.meta %} • {{ page.meta }}{% endif %}
|
8
|
+
<p class="post-meta">{{ page.date | date: "%b %-d, %Y" }}{% if page.author %} • {{ page.author }}{% endif %}{% if page.meta %} • {{ page.meta }}{% endif %}
|
9
9
|
</header>
|
10
10
|
|
11
11
|
<article class="post-content">
|
@@ -0,0 +1,88 @@
|
|
1
|
+
---
|
2
|
+
layout: post
|
3
|
+
title: "noise_mode"
|
4
|
+
---
|
5
|
+
|
6
|
+
### Name ###
|
7
|
+
|
8
|
+
`noise_mode` _NB: not currently available in vanilla processing_.
|
9
|
+
|
10
|
+
### Examples ###
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
#!/usr/bin/env jruby -w
|
14
|
+
require 'picrate'
|
15
|
+
|
16
|
+
class TestNoise < Processing::App
|
17
|
+
attr_reader :z
|
18
|
+
|
19
|
+
def setup
|
20
|
+
stroke(255, 64)
|
21
|
+
@z = 0
|
22
|
+
end
|
23
|
+
|
24
|
+
def draw
|
25
|
+
noise_scale = 0.01
|
26
|
+
background(0)
|
27
|
+
grid(width, height, 10, 10) do |x, y|
|
28
|
+
arrow(x, y, noise(x * noise_scale, y * noise_scale, z * noise_scale) * TWO_PI * 2)
|
29
|
+
end
|
30
|
+
@z += 1
|
31
|
+
end
|
32
|
+
|
33
|
+
def mouse_pressed
|
34
|
+
mode = NoiseMode::OPEN_SMOOTH # Smooth classic OpenSimplex2
|
35
|
+
noise_mode mode
|
36
|
+
sketch_title mode.description
|
37
|
+
end
|
38
|
+
|
39
|
+
def mouse_released
|
40
|
+
mode = NoiseMode::DEFAULT # Fast classic OpenSimplex2
|
41
|
+
noise_mode(mode)
|
42
|
+
sketch_title mode.description
|
43
|
+
end
|
44
|
+
|
45
|
+
|
46
|
+
def arrow(x, y, ang)
|
47
|
+
push_matrix()
|
48
|
+
translate(x, y)
|
49
|
+
rotate(ang)
|
50
|
+
line(0, 0, 20, 0)
|
51
|
+
translate(20, 0)
|
52
|
+
rotate(PI + 0.4)
|
53
|
+
line(0, 0, 5, 0)
|
54
|
+
rotate(-0.8)
|
55
|
+
line(0, 0, 5, 0)
|
56
|
+
pop_matrix()
|
57
|
+
end
|
58
|
+
|
59
|
+
def settings
|
60
|
+
size(600, 400, P2D)
|
61
|
+
end
|
62
|
+
end
|
63
|
+
|
64
|
+
TestNoise.new
|
65
|
+
|
66
|
+
```
|
67
|
+
|
68
|
+
### Description ###
|
69
|
+
|
70
|
+
Currently supports four implementations of noise:-
|
71
|
+
1. DEFAULT # fast classic OpenSimplex2
|
72
|
+
2. OPEN_SMOOTH # smoother class OpenSimplex2F
|
73
|
+
3. FAST_TERRAIN # more suited to terrain
|
74
|
+
4. SMOOTH_TERRAIN # as above but smoother
|
75
|
+
|
76
|
+
### Syntax ###
|
77
|
+
|
78
|
+
```ruby
|
79
|
+
noise_mode(mode) # default is NoiseMode::DEFAULT, a fast classic OpenSimplex2
|
80
|
+
```
|
81
|
+
|
82
|
+
### Related ###
|
83
|
+
|
84
|
+
`noise(x, y, z, w)`
|
85
|
+
|
86
|
+
`noise(x, y, z)`
|
87
|
+
|
88
|
+
`noise(x, y)`
|
@@ -14,7 +14,7 @@ Get the latest version from [http://jruby.org/download][download]
|
|
14
14
|
|
15
15
|
```bash
|
16
16
|
cd /opt
|
17
|
-
sudo tar xzvf /pathToDownload/jruby-bin-9.2.
|
17
|
+
sudo tar xzvf /pathToDownload/jruby-bin-9.2.14.0.tar.gz
|
18
18
|
```
|
19
19
|
|
20
20
|
Then use the excellent `update-alternatives` tool to provide symbolic links to `jruby`, `jgem`, `jirb` and `rake` especially if you haven't installed `mri` ruby.
|
@@ -38,9 +38,9 @@ export PATH="${PATH}:${GEM_PATH}/bin"
|
|
38
38
|
|
39
39
|
### Automated install using bash ###
|
40
40
|
|
41
|
-
The [picrate2_install.sh][bash] script currently installs jruby-9.2.
|
41
|
+
The [picrate2_install.sh][bash] script currently installs jruby-9.2.14.0 and picrate-2.2.0.
|
42
42
|
|
43
43
|
If you know better please post on wiki
|
44
44
|
|
45
|
-
[download]:"https://repo1.maven.org/maven2/org/jruby/jruby-dist/9.2.
|
45
|
+
[download]:"https://repo1.maven.org/maven2/org/jruby/jruby-dist/9.2.14.0/jruby-dist-9.2.14.0-bin.tar.gz"
|
46
46
|
[bash]:https://gist.github.com/monkstone/6ae9840d7b7008c177b4a9f589d14ec6
|
@@ -6,7 +6,7 @@ categories: PiCrate update
|
|
6
6
|
---
|
7
7
|
Requirements:-
|
8
8
|
|
9
|
-
1. Latest jogl-2.4.0-rc jars (place in ~/
|
9
|
+
1. Latest jogl-2.4.0-rc jars (place in ~/jogl-2.4-rc2021011 folder see [jogl-jars][jars]).
|
10
10
|
|
11
11
|
2. jdk-11+ and maven
|
12
12
|
|
@@ -16,3 +16,5 @@ git clone --depth 1 https://github.com/ruby-processing/PiCrate.git
|
|
16
16
|
cd PiCrate
|
17
17
|
rake # to build gem
|
18
18
|
```
|
19
|
+
|
20
|
+
[jars]:https://jogamp.org/deployment/archive/rc/v2.4.0-rc-20210111/jar/
|
@@ -5,12 +5,20 @@ date: 2020-05-11 07:34:13
|
|
5
5
|
categories: PiCrate update
|
6
6
|
permalink: /getting_manjaro/
|
7
7
|
---
|
8
|
-
|
8
|
+
If Manjaro does not come with a pre-installed java, then the first step is to install a `jdk` the distro version (jdk14) should work.
|
9
9
|
|
10
10
|
```bash
|
11
|
-
|
11
|
+
sudo pacman -S jdk-openjdk # current distro version jdk14
|
12
12
|
```
|
13
|
+
You can also use pacman to install jruby
|
14
|
+
```bash
|
15
|
+
sudo pacman -S jruby # current version jruby-9.2.14.0
|
16
|
+
```
|
17
|
+
It is probably a good idea to create a local gem store (rather needing to use sudo to install gems)
|
13
18
|
|
19
|
+
```bash
|
20
|
+
mkdir -p ~/.gem/ruby/2.5.0 # current MRI version supported by jruby
|
21
|
+
```
|
14
22
|
Now set your `GEM_HOME`, `GEM_PATH` and amend your `PATH` as follows:-
|
15
23
|
|
16
24
|
```bash
|
@@ -19,16 +27,20 @@ echo "export GEM_PATH=\"\${HOME}/.gem/ruby/${MRI_RUBY}\"" >> ~/.bashrc
|
|
19
27
|
echo "export PATH=\"\${PATH}:\${GEM_PATH}/bin\"" >> ~/.bashrc
|
20
28
|
source ~/.bashrc # to update environment without re-logging in
|
21
29
|
```
|
22
|
-
Now should be ready to install `picrate` and other gems.
|
23
|
-
|
30
|
+
Now should be ready to install `picrate` and other gems. But speed up install time you should set `--no-document` option in ~/.gemrc
|
31
|
+
|
24
32
|
```bash
|
25
|
-
|
33
|
+
touch ~/.gemrc
|
34
|
+
echo "gem: --no-document" > ~/.gemrc
|
26
35
|
```
|
27
36
|
To install latest picrate and its dependencies:-
|
28
37
|
|
29
38
|
```bash
|
30
39
|
jgem install picrate
|
31
40
|
```
|
41
|
+
|
42
|
+
Geany is a good editor/ide for PiCrate on the RaspberryPI (install via pacman), but some may prefer vim. For geany you should edit/preferences/Terminal to `Execute programs in the VTE`.
|
43
|
+
|
32
44
|
__For a first install:-__
|
33
45
|
|
34
46
|
```bash
|
@@ -37,7 +49,7 @@ picrate --install # no args, install samples and geany config
|
|
37
49
|
picrate -i Samples # to omit geany config
|
38
50
|
```
|
39
51
|
|
40
|
-
This installs example sketches in `~/projects/examples` and ties them into a `geany` project `examples.geany`. It should also be possible to run sketches from the `geany` ide.
|
52
|
+
This installs example sketches in `~/projects/examples` and ties them into a `geany` project `examples.geany`. It should also be possible to run sketches from the `geany` ide. The geany config creates `picrate.rb` template sketch so you can create a new sketch with template.
|
41
53
|
|
42
54
|
To create a template sketch from the command line:-
|
43
55
|
|
@@ -77,7 +89,7 @@ vim my_sketch.rb
|
|
77
89
|
To run sketches from command line:-
|
78
90
|
|
79
91
|
```bash
|
80
|
-
jruby my_sketch.rb
|
92
|
+
jruby --dev my_sketch.rb
|
81
93
|
```
|
82
94
|
|
83
95
|
Or even `chmod +x my_sketch.rb` to make an executable script.
|
data/docs/classes.md
CHANGED
@@ -5,6 +5,6 @@ title: Classes
|
|
5
5
|
|
6
6
|
{% for class in site.classes %}
|
7
7
|
<h2>{{ item.title }}</h2>
|
8
|
-
<p>{{ item.description }}
|
9
|
-
<p><h2><a href="{{ class.url | prepend: site.github.url }}">{{ class.title }}</a></h2
|
8
|
+
<p>{{ item.description }}
|
9
|
+
<p><h2><a href="{{ class.url | prepend: site.github.url }}">{{ class.title }}</a></h2>
|
10
10
|
{% endfor %}
|
data/docs/editors.md
CHANGED
@@ -5,6 +5,6 @@ title: Editors
|
|
5
5
|
|
6
6
|
{% for editor in site.editors %}
|
7
7
|
<h2>{{ item.title }}</h2>
|
8
|
-
<p>{{ item.description }}
|
9
|
-
<p><h2><a href="{{ editor.url | prepend: site.github.url }}">{{ editor.title }}</a></h2
|
8
|
+
<p>{{ item.description }}
|
9
|
+
<p><h2><a href="{{ editor.url | prepend: site.github.url }}">{{ editor.title }}</a></h2>
|
10
10
|
{% endfor %}
|
data/docs/gems.md
CHANGED
@@ -4,8 +4,8 @@ title: Gems
|
|
4
4
|
---
|
5
5
|
{% for gem in site.gems %}
|
6
6
|
<h2>{{ item.title }}</h2>
|
7
|
-
<p>{{ item.description }}
|
8
|
-
<p><h2><a href="{{ gem.url | prepend: site.github.url }}">{{ gem.title }}</a></h2
|
7
|
+
<p>{{ item.description }}
|
8
|
+
<p><h2><a href="{{ gem.url | prepend: site.github.url }}">{{ gem.title }}</a></h2>
|
9
9
|
{% endfor %}
|
10
10
|
|
11
|
-
<p>If you are new to ruby, see <a href="http://guides.rubygems.org/what-is-a-gem/">what is a gem here</a
|
11
|
+
<p>If you are new to ruby, see <a href="http://guides.rubygems.org/what-is-a-gem/">what is a gem here</a>
|
data/docs/index.html
CHANGED
@@ -23,6 +23,6 @@ layout: default
|
|
23
23
|
{% endfor %}
|
24
24
|
</ul>
|
25
25
|
|
26
|
-
<p class="rss-subscribe">subscribe <a href="{{ "/feed.xml" | prepend: site.github.url }}">via RSS</a
|
26
|
+
<p class="rss-subscribe">subscribe <a href="{{ "/feed.xml" | prepend: site.github.url }}">via RSS</a>
|
27
27
|
|
28
28
|
</div>
|
data/docs/libraries.md
CHANGED
@@ -6,8 +6,8 @@ It is possible to use vanilla <a href="https://www.processing.org/reference/libr
|
|
6
6
|
|
7
7
|
{% for library in site.libraries %}
|
8
8
|
<h2>{{ item.title }}</h2>
|
9
|
-
<p>{{ item.description }}
|
10
|
-
<p><h2><a href="{{ library.url | prepend: site.github.url }}">{{ library.title }}</a></h2
|
9
|
+
<p>{{ item.description }}
|
10
|
+
<p><h2><a href="{{ library.url | prepend: site.github.url }}">{{ library.title }}</a></h2>
|
11
11
|
{% endfor %}
|
12
12
|
|
13
13
|
<h4>Key To Library Types</h4>
|
data/docs/live.md
CHANGED
@@ -6,6 +6,6 @@ Spoiler alert, initially a least it is better just to accept the live works...
|
|
6
6
|
|
7
7
|
{% for live_mode in site.live %}
|
8
8
|
<h2>{{ item.title }}</h2>
|
9
|
-
<p>{{ item.description }}
|
10
|
-
<p><h2><a href="{{ live_mode.url | prepend: site.github.url }}">{{ live_mode.title }}</a></h2
|
9
|
+
<p>{{ item.description }}
|
10
|
+
<p><h2><a href="{{ live_mode.url | prepend: site.github.url }}">{{ live_mode.title }}</a></h2>
|
11
11
|
{% endfor %}
|
data/docs/magic.md
CHANGED
@@ -6,6 +6,6 @@ Spoiler alert, initially a least it is better just to accept the magic works...
|
|
6
6
|
|
7
7
|
{% for spell in site.magic %}
|
8
8
|
<h2>{{ item.title }}</h2>
|
9
|
-
<p>{{ item.description }}
|
10
|
-
<p><h2><a href="{{ spell.url | prepend: site.github.url }}">{{ spell.title }}</a></h2
|
9
|
+
<p>{{ item.description }}
|
10
|
+
<p><h2><a href="{{ spell.url | prepend: site.github.url }}">{{ spell.title }}</a></h2>
|
11
11
|
{% endfor %}
|
data/docs/methods.md
CHANGED
@@ -5,6 +5,6 @@ title: Methods
|
|
5
5
|
|
6
6
|
{% for method in site.methods %}
|
7
7
|
<h2>{{ item.title }}</h2>
|
8
|
-
<p>{{ item.description }}
|
9
|
-
<p><h2><a href="{{ method.url | prepend: site.github.url }}">{{ method.title }}</a></h2
|
8
|
+
<p>{{ item.description }}
|
9
|
+
<p><h2><a href="{{ method.url | prepend: site.github.url }}">{{ method.title }}</a></h2>
|
10
10
|
{% endfor %}
|
data/docs/modules.md
CHANGED
@@ -5,8 +5,8 @@ title: Modules
|
|
5
5
|
|
6
6
|
{% for module in site.modules %}
|
7
7
|
<h2>{{ item.title }}</h2>
|
8
|
-
<p>{{ item.description }}
|
9
|
-
<p><h2><a href="{{ module.url | prepend: site.github.url }}">{{ module.title }}</a></h2
|
8
|
+
<p>{{ item.description }}
|
9
|
+
<p><h2><a href="{{ module.url | prepend: site.github.url }}">{{ module.title }}</a></h2>
|
10
10
|
{% endfor %}
|
11
11
|
|
12
|
-
<p>If you are new to ruby, you can read more about <a href="https://www.tutorialspoint.com/ruby/ruby_modules.htm">modules here</a
|
12
|
+
<p>If you are new to ruby, you can read more about <a href="https://www.tutorialspoint.com/ruby/ruby_modules.htm">modules here</a>
|
data/docs/objects.md
CHANGED
@@ -4,6 +4,6 @@ title: Variables and Objects
|
|
4
4
|
---
|
5
5
|
{% for object in site.objects %}
|
6
6
|
<h2>{{ item.title }}</h2>
|
7
|
-
<p>{{ item.description }}
|
8
|
-
<p><h2><a href="{{ object.url | prepend: site.github.url }}">{{ object.title }}</a></h2
|
7
|
+
<p>{{ item.description }}
|
8
|
+
<p><h2><a href="{{ object.url | prepend: site.github.url }}">{{ object.title }}</a></h2>
|
9
9
|
{% endfor %}
|
data/lib/picrate.rb
CHANGED
data/lib/picrate/app.rb
CHANGED
@@ -5,7 +5,7 @@ require_relative 'helper_methods'
|
|
5
5
|
require_relative 'library_loader'
|
6
6
|
# A wrapper module for the processing App
|
7
7
|
module Processing
|
8
|
-
include_package 'processing.core' # imports the processing
|
8
|
+
include_package 'processing.core' # imports the processing classes.
|
9
9
|
# Load vecmath, fastmath and mathtool modules
|
10
10
|
Java::Monkstone::PicrateLibrary.load(JRuby.runtime)
|
11
11
|
SKETCH_ROOT = File.absolute_path('.')
|
@@ -55,6 +55,7 @@ module Processing
|
|
55
55
|
include HelperMethods
|
56
56
|
include MathTool
|
57
57
|
include Math
|
58
|
+
include FastNoise
|
58
59
|
# Alias some methods for familiarity for Shoes coders.
|
59
60
|
alias oval ellipse
|
60
61
|
alias stroke_width stroke_weight
|
@@ -144,7 +145,7 @@ module Processing
|
|
144
145
|
def data_path(dat)
|
145
146
|
dat_root = File.join(SKETCH_ROOT, 'data')
|
146
147
|
Dir.mkdir(dat_root) unless File.exist?(dat_root)
|
147
|
-
File.join(dat_root, dat)
|
148
|
+
File.join(dat_root, dat).to_java(:string)
|
148
149
|
end
|
149
150
|
|
150
151
|
private
|