Skip to content

Commit 1d54076

Browse files
committed
explain about wrapping hexadecimal colors
1 parent 6171b64 commit 1d54076

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

external_library/java/pixel_flow/README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,15 @@ end
3333
# init skylight renderer
3434
@skylight = DwSkyLight.new(context, scene_display, mat_scene_bounds)
3535
```
36+
37+
38+
In [antialiasing.rb][anti] if we just use the overloaded `color` method, jruby complains of overloaded method but guesses right and chooses the correct java signature (float, float, float). Mainly to show how we can do it, we provide an alias method `color_float` that avoids the look up cost in detecting the correct signature, this is not generally important if you can put up with the warning.
39+
40+
41+
The ControlP5 library is overly complicated and does not seem to work well with JRubyArt, the built in `control_panel` is much simpler to use. If you must use ControlP5 see [examples][p5] and the revised [basic_fluid.rb][basic]
42+
43+
NB: where processing sketches use `fill(hexadecimal)` etc in propane we must wrap hexadecimal with color `fill(color(hexadecimal))` (_otherwise fill etc will complain of int too big_)
44+
45+
[anti]:https://github.com/ruby-processing/JRubyArt-examples/blob/master/external_library/java/PixelFlow/anti_aliasing.rb
46+
[p5]:https://github.com/ruby-processing/JRubyArt-examples/tree/master/external_library/java/controlP5
47+
[basic]:https://github.com/ruby-processing/propane-examples/blob/master/external_library/java/pixel_flow/fluid_basic.rb

0 commit comments

Comments
 (0)