rohitvarkey / ThreeJS.jl

Julia interface to WebGL using Three-js custom elements and Patchwork.jl
https://rohitvarkey.github.io/ThreeJS.jl
Other
56 stars 15 forks source link

Added shadermaterial and datatexture functions, with examples #35

Closed izaid closed 8 years ago

izaid commented 8 years ago

This PR adds wrappers for the ThreeJS shadermaterial and datatexture. It therefore allows arbitrary WebGL shaders to be attached to meshes. This requires the latest releases of Patchwork.jl and Escher.jl. At the moment, it won't work in Jupyter, but hopefully we can fix that in time.

For datatexture, Julia arrays are serialized as base64 strings. This is the most efficient option to my knowledge. As such, I've added a base64 decoder in JavaScript.

This PR is ready to be merged. It also requires the merging of https://github.com/rohitvarkey/three-js/pull/4.

codecov-io commented 8 years ago

Current coverage is 89.88% (diff: 0.00%)

Merging #35 into master will decrease coverage by 3.13%

@@             master        #35   diff @@
==========================================
  Files             3          3          
  Lines            86         89     +3   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
  Hits             80         80          
- Misses            6          9     +3   
  Partials          0          0          

Powered by Codecov. Last update 2104c34...f4d24f7

rohitvarkey commented 8 years ago

@izaid I tried pulling Escher and Patchwork master and running the examples, but I'm getting PropHook not defined. Are the PR's there merged yet?

izaid commented 8 years ago

@shashi said they'd be merged today -- looks like it hasn't happened yet...

shashi commented 8 years ago

I have pushed them now. Sorry for the wait.

This branch has conflicts merge conflicts against shadermaterial.

These examples are cool!