mrdoob/three.js — Issue #1263: Vertex shader problem on SphereGeometry
Author: apros
Created: 2012-02-06 22:01:13+00:00
State: open
Labels: Question

Hi everybody, this is my first post on this great project!
I'm developing a 3D project about sites and planets, so I need to handle spheres to render stars and planets. Unfortunately, I've a problem with vertex shader manipulation on a SphereGeometry (I'm a quasi-total noob with glsl)...if I try to move pixels around, to create some noise, a crack opens throughout the sphere, allowing you to see the background (you can see it here http://img859.imageshack.us/img859/4958/schermata20120206a22435.png).

Here is the code I use:

How could I avoid this problem? I thought not to move the vertices along the crack, but I don't know how to locate them...thanks! ;)