Open amicoleo opened 8 years ago
Hmm, I'll look into this. The latest aframe branch has custom shaders which are probably which'll be used for this module once it's released.
I just ran into this. To fix it, in createCanvas:
change
this.el.object3D.material = new THREE.MeshBasicMaterial();
this.el.object3D.material.map = this.texture;
to
this.el.object3D.children[0].material = new THREE.MeshBasicMaterial();
this.el.object3D.children[0].material.map = this.texture;
I'll take care of this tomorrow, thanks!
On Fri, Mar 18, 2016 at 4:54 PM, Paul M. Christian <notifications@github.com
wrote:
I just ran into this. To fix it, in createCanvas:
change
this.el.object3D.material = new THREE.MeshBasicMaterial(); this.el.object3D.material.map = this.texture;
to
this.el.object3D.children[0].material = new THREE.MeshBasicMaterial(); this.el.object3D.children[0].material.map = this.texture;
— You are receiving this because you commented. Reply to this email directly or view it on GitHub https://github.com/maxkrieger/aframe-draw-component/issues/4#issuecomment-198538338
This solution isn't backwards compatible, so I made a quick and dirty if...else.
Should be solved in 1.4.0
, let me know how it goes.
I've tried to get this component to work with A-Frame 0.2.0, but it doesn't work.
This example just renders a white cube with A-Frame 0.2.0 and version 1.4.0 of this component:
<a-scene>
<a-sky color="blue"></a-sky>
<a-entity position="0 1 0" geometry="primitive: box" draw="width: 256; height: 256" square="text: Hello">
</a-entity>
</a-scene>
@RSpace this should be fixed in 1.5.0
.
I tried it with the latest branch of aframe.io 0.3.0 and it works fine for me. Though i|ve to admit one should use the complete example code of the repository, not the short hints giving snippets of the repository page. And .. i've a question: is there an issue if one is using html-component, too? I seams to me as a normal draw component is running into a permanent loop than. I can show you some example code, if you want.
Hi,
The components works perfectly if using aframe-core, as you have in your package
"aframe-core": "0.1.2",
but the with the latest aframe branch"aframe": "aframevr/aframe#dev"
The canvas is not drawn on the entity and I didn't get any message on the console about it.