hiding far labels

View: New views
4 Messages — Rating Filter:   Alert me  

hiding far labels

by Murat Aydın :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
Hi,
 
I am trying this example :
 
How can i hide far labels ? There are many labels and its hard to understand which label belongs to which object.
 
Whats MaximumLabelFraction of vtkLabelPlacer?
 
Another question is how can i display labels vertical. i set LabelGravity to 
   VerticalBottomBit , VerticalBaselineBit  but labels are not displayed vertical.
 
 
Kind Regards,
 
murat

_______________________________________________
Powered by 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

Re: hiding far labels

by Jeff Baumes :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

2009/11/9 Murat Aydın <murat.aydin@...>
Hi,
 
I am trying this example :
 
How can i hide far labels ? There are many labels and its hard to understand which label belongs to which object.

You can hide labels that are behind other objects with UseDepthBufferOn(). There is no explicit way to turn off far labels, except that the labeler should automatically try to place labels close to the camera first, so far labels should be less frequent.
 
 
Whats MaximumLabelFraction of vtkLabelPlacer?

Maximum amount of screen space labels can take up before placement stops. I've checked in a documentation fix.
 
 
Another question is how can i display labels vertical. i set LabelGravity to 
   VerticalBottomBit , VerticalBaselineBit
  but labels are not displayed vertical.

These flags just adjust the where the text is vertically aligned, not the rotation. The default text rendering strategy (freetype) does not support nicely rotated text. To get rotated text labels, you would need:

1. Compile VTK with VTK_USE_QT.
2. Use vtkLabelPlacementMapper instead of vtkLabelPlacer (it has similar API but a few more features).
3. Set the label rendering strategy to an instance of vtkQtLabelRenderStrategy.
4. Set the orientation of the text property in vtkPointSetToLabelHierarchy to the angle you desire (e.g. 90.0).

Most of this code to do this is in
Views/Testing/Cxx/TestQtLabelStrategy.cxx

Jeff

_______________________________________________
Powered by 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

Re: hiding far labels

by Murat Aydın :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
Hi,
 
Thanks for your help. I dont have vtkLabelPlacementMapper class in vtk 5.4.2. I am using vtkLabelPlacer and i couldnt find something similar to
UseDepthBufferOn in vtkLabelPlacer. When i compile with vtk_use_qt, i cant wrap some classes and methods (i am use .net wrapper for vtk).
 
Kind Regards,
 
murat
 
 
----- Original Message -----
Sent: Tuesday, November 10, 2009 3:58 PM
Subject: Re: [vtkusers] hiding far labels

2009/11/9 Murat Aydın <murat.aydin@...>
Hi,
 
I am trying this example :
 
How can i hide far labels ? There are many labels and its hard to understand which label belongs to which object.

You can hide labels that are behind other objects with UseDepthBufferOn(). There is no explicit way to turn off far labels, except that the labeler should automatically try to place labels close to the camera first, so far labels should be less frequent.
 
 
Whats MaximumLabelFraction of vtkLabelPlacer?

Maximum amount of screen space labels can take up before placement stops. I've checked in a documentation fix.
 
 
Another question is how can i display labels vertical. i set LabelGravity to 
   VerticalBottomBit , VerticalBaselineBit
  but labels are not displayed vertical.

These flags just adjust the where the text is vertically aligned, not the rotation. The default text rendering strategy (freetype) does not support nicely rotated text. To get rotated text labels, you would need:

1. Compile VTK with VTK_USE_QT.
2. Use vtkLabelPlacementMapper instead of vtkLabelPlacer (it has similar API but a few more features).
3. Set the label rendering strategy to an instance of vtkQtLabelRenderStrategy.
4. Set the orientation of the text property in vtkPointSetToLabelHierarchy to the angle you desire (e.g. 90.0).

Most of this code to do this is in
Views/Testing/Cxx/TestQtLabelStrategy.cxx

Jeff

_______________________________________________
Powered by 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

Help with vtkInterpolateDataSetAttributes

by "Björn Zehner" :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Dear friends of VTK,
 
I want to interpolate the point attributes between different data sets (with the same topology of course) and I tried to use the vtkInterpolateDataSetAttributes filter for this. Generally it seems to work, but the output data set always only has one of the scalar values interpolated (the first one). The rest seems to be missing. I also tried to use the following line:

SetInputArrayToProcess(0, 0, 0, vtkDataObject::FIELD_ASSOCIATION_POINTS, "SomeName")


But it then still just interpolates the first DataArray. What do I need to do to get all scalars interpolated? Some hint would be appreciated.
Kind regards,
Björn Zehner

-------------------------------------------------------------------------
Dr. Bjoern Zehner
UFZ Centre for Environmental Research Leipzig-Halle
Permoserstrasse 15
04318 Leipzig
Germany
http://www.ufz.de/index.php?en=5673
Tel: ++49 (341) 235 1979
Fax: ++49 (341) 235 1939


_______________________________________________
Powered by 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