I have a curved line, I would like to know how do PointClouds or sprites to move along this line. I want to do something like this: http://armsglobe.chromeexperiments.com/ how can I do it?. You can make it easier using tween.js?
I have this is a mesh tube that also I have a line, how I can do to make a sprite / PointCloud move along its structure?
Related
I'm simulating an earth using THREE.SphereGeometry with only 32x16 or 64x32 segments. It has very large flat spots several km deep. 1024x512 is nicer but not really an option. For the area I'm working in, I'd like to fill that area in with more segments so that the surface and the graphics match within centimeters.
I could use the phi and theta of SphereGeometry to define the portion I want...
But then I want to texture it. When I use the whole sphere texture for a portion, it squishes the whole image into that portion. Is there a way to just get the texture of the portion I want?
I'm new to UV mapping - are there options with that that can help?
This is more about geometry than level of detail. The LOD is very crude and I'm fine with that for now.
I've been looking for a solution to this problem for a project I'm working on. I'd like to know if there is a way to click on a plane geometry and draw onto it, paint style, and have the texture update as you draw on it.
After this, is there a way to save that texture while in the browser now that you've edited it?
You could use raycasting to determine the UV texture position where the mouse intersection takes place. Raycaster.intersectObject returns an array of objects, one of its properties is .uv. You can see it in action in this demo.
You can use a 2D <canvas> as the source of the texture. Once you have the UVs from the intersection, you could use that position to draw on the canvas as demonstrated in this other demo
I'm trying NPR with three.js. I'm new with computer graphics. I want to extrude the lines segments and put textures on it. Is it possible to put texture after extruding the line segments using ExtrudeGeometry or should I first triangulate the lines, and then put texture on it?
Thanks in advance.
I want to be able to show or hide the diagonal lines in the wireframe of my PlaneGeometry mesh, as well as being able to show or hide vertical or horizontal lines. Is there a way to do this and retain the triangles in my mesh? I already have 'wireframe: true' set on the material and can color it. I've been able to do this in the past with OpenGL, is it possible with Three.js?
You can use, or modify to your liking, src/extras/helpers/GridHelper.js.
There is also src/extras/helpers/WireframeHelper.js.
See http://threejs.org/examples/webgl_helpers.html
EDIT: THREE.EdgesHelper has been added to the library. It will not render the diagonal lines of flat faces.
three.js. r.65
Can someone help with videotexture on cube in three.js with WebGLRenderer.
I am trying to use Three.js to render a cube with one-piece videotexture from one file without use
THREE.ImageUtils.loadTextureCube
instead image such as jpg, but I don't get visible cubes. Should ideally i need create something like 180 degrees half sphere video panorama but only with cube. That is, i want to put a texture to all faces of a cube, not cutting it, in the one stream because if I use different video textures on every face then this will affect the performance.
I am trying to use video texture on sphere like here
http://mrdoob.github.com/three.js/examples/webgl_panorama_equirectangular.html
and all works fine, but i want use cube like here
http://mrdoob.github.com/three.js/examples/webgl_materials_cubemap_balls_refraction.html
but I don't get visible cubes.
I don't want to cut a movie file to six different parts to put them on every face of the cube as in this example.
Maybe other methods to overlay material on cube form one video file than using different textures for each face?
Thx and sorry for my english.