-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changing point color dynamically #65
Comments
I see a couple of problem with this code. I am not sure what the context this code is in or where you got the It seems to me you're setting assigning the color components to a single slot within the array (just the Also, if my memory serves me right, I am not sure there's an explicit https://github.com/verma/plasio/blob/master/js/render.js#L1795 May be try playing with that code first and see if you can get the color to change etc.? |
I do change all three channels. That was a typo from me, post edited.
|
Ah, that makes sense, thanks for clearing it up. I do see the That should have done it, three.js should have handled that. May be try a simpler example and see if you can get it to work, like a small three.js program may be? |
I want to change colors of some points dynamically.
I do following for point at location j:
geometry.attributes.color.array[3*j] = r;
geometry.attributes.color.array[3*j+1] = g;
geometry.attributes.color.array[3*j+2] = b;
geometry.attributes.color.needsUpdate = true;
But change is not reflected.
What else would I need to do to achieve it?
The text was updated successfully, but these errors were encountered: