[vtkusers] Color the 3D object wrt the time when the points were added
Divya
divya at triassicsolutions.com
Wed Apr 17 09:04:51 EDT 2013
Cory,
I am able to add colors to the object, but once the
vtkButterflySubdivisionFilter is applied, thousands of additional points
are created, when the new points are added, it adds colors which were
not specified.
Since I need to follow a predefined color scheme, this output is not the
desired one.
How can i make the new points obtained after the SubdivisionFilter to
also take the initial color. I am using InsertTuple3 function to add
color to each of the points before applying the
vtkButterflySubdivisionFilter.
Thanks,
Divya
On 4/16/2013 6:44 PM, Cory Quammen wrote:
> Divya,
>
> Here's an outline of a general approach you might use. You could
> create a scalar field for your 3D object that contains the time at
> which the point was added. Then you can use a transfer function that
> you use to color the 3D object according to those scalars. By
> appropriately defining the controls points of the transfer function,
> you can color the objects added in the last twenty seconds one color
> and the rest of the points another color.
>
> The only downside of this approach is that you might have a band of
> color across a surface cell if that cell is made up of old and new points.
>
> Hope this helps,
> Cory
>
>
> On Tue, Apr 16, 2013 at 2:26 AM, Divya <divya at triassicsolutions.com
> <mailto:divya at triassicsolutions.com>> wrote:
>
> Dear All,
>
> I am working on an application where I am adding 1 point at a time
> and the 3D object is re-rendered. I need to color this 3D object
> with respect to the time when the points were added.
>
> The final object is rendered after the
> vtkButterflySubdivisionFilter. I have implemented a timer with an
> interval of 20 secs, and I need to change the colors of the 3D
> object every 20 secs, ie : The region that was created within the
> last 20 secs should be rendered in 'red' color, and the region
> created in the previous 20secs in another color and so on.
>
> Is there a way to implement this in VTK? Also is there a way to
> get the points in the last modified region?
>
> Thanks in advance!
> --
>
>
>
> _______________________________________________
> Powered by www.kitware.com <http://www.kitware.com>
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
>
>
>
> --
> Cory Quammen
> Research Associate
> Department of Computer Science
> The University of North Carolina at Chapel Hill
--
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20130417/4ca851fd/attachment.htm>
More information about the vtkusers
mailing list