MantisBT - ParaView
View Issue Details
0013576ParaView(No Category)public2012-10-26 14:322012-10-31 20:09
Patrick O'Leary 
Sebastien Jourdain 
normalminorhave not tried
closedfixed 
3.14.1 
3.98.0 
TBD
13469_fix_cube_axes_parallel_rendering
incorrect functionality
0013576: labels don't show up or are clipped in plots.
I would like to put axes with labels on the figures that I am generating. I've tried clicking show cube axes under the display menu for an extract subset. I can get the tick marks and axis lines to show up. But, I cannot get the labels to show up unless I rotate the screen (see attached images). I have tried using the axes source, but I run into the same problem. It seams like there is a bounding box or something that cuts the annotation off when for example looking directly down from the top. For runs of HIGRAD/FIRETEC at LANL reported by Jesse M Canfield, jessec@lanl.gov
No tags attached.
related to 0013469closed Sebastien Jourdain 2d doesn't load correctly remote server 
png Screen Shot 2012-10-26 at 8.52.27 AM.png (347,139) 2012-10-26 14:32
https://www.vtk.org/Bug/file/9319/Screen%20Shot%202012-10-26%20at%208.52.27%20AM.png
png Screen Shot 2012-10-26 at 8.50.42 AM.png (212,498) 2012-10-26 14:32
https://www.vtk.org/Bug/file/9320/Screen%20Shot%202012-10-26%20at%208.50.42%20AM.png
png

png Screen Shot 2012-10-26 at 8.53.04 AM.png (386,584) 2012-10-26 14:33
https://www.vtk.org/Bug/file/9321/Screen%20Shot%202012-10-26%20at%208.53.04%20AM.png
Issue History
2012-10-26 14:32Patrick O'LearyNew Issue
2012-10-26 14:32Patrick O'LearyFile Added: Screen Shot 2012-10-26 at 8.52.27 AM.png
2012-10-26 14:32Patrick O'LearyFile Added: Screen Shot 2012-10-26 at 8.50.42 AM.png
2012-10-26 14:33Patrick O'LearyFile Added: Screen Shot 2012-10-26 at 8.53.04 AM.png
2012-10-29 11:47Utkarsh AyachitRelationship addedrelated to 0013469
2012-10-30 09:04Sebastien JourdainAssigned To => Sebastien Jourdain
2012-10-30 09:05Sebastien JourdainTopic Name => 13469_fix_cube_axes_parallel_rendering
2012-10-30 09:05Sebastien JourdainStatusbacklog => gatekeeper review
2012-10-30 09:05Sebastien JourdainResolutionopen => fixed
2012-10-30 13:30Sebastien JourdainNote Added: 0029600
2012-10-31 10:46Utkarsh AyachitFixed in Version => 3.98.0
2012-10-31 10:47Utkarsh AyachitStatusgatekeeper review => customer review
2012-10-31 10:47Utkarsh AyachitNote Added: 0029617
2012-10-31 20:09Alan ScottNote Added: 0029636
2012-10-31 20:09Alan ScottStatuscustomer review => closed

Notes
(0029600)
Sebastien Jourdain   
2012-10-30 13:30   
This issue is related to the bounds reported by CubeAxes which make IceT to crop labels...


commit 907a59e775a94c951c38785821167009ab440cfc
Author: Sebastien Jourdain <sebastien.jourdain@kitware.com>
Date: Tue Oct 30 08:55:54 2012 -0400

    Make sure axis label are shown when looking at a 2D plane in 3D
    
    Change-Id: Ie5e06e4f190ff5a354d863d1defd2b821059d04d

[...]

diff --git a/Rendering/Annotation/vtkCubeAxesActor.cxx b/Rendering/Annotation/vtkCubeAxesActor.cxx
index 770d15c..8554c22 100644
--- a/Rendering/Annotation/vtkCubeAxesActor.cxx
+++ b/Rendering/Annotation/vtkCubeAxesActor.cxx
@@ -17,6 +17,7 @@
[...]
+// --------------------------------------------------------------------------
+void vtkCubeAxesActor::GetRenderedBounds(double *b)
+{
+ vtkBoundingBox bbox(this->GetBounds()); // Data bounds
+
+ // Make a heuristic on the final bounds that embed test labels
+ // Just inflate the box based on its max length
+ bbox.Inflate(bbox.GetMaxLength());
+
+ bbox.GetBounds(b);
+}

+++++++++++++++++++


diff --git a/ParaViewCore/VTKExtensions/Rendering/vtkIceTCompositePass.cxx b/ParaViewCore/VTKExtensions/Rendering/vtkIceTCompositePass.cxx
index ed5a409..76016ae 100644
--- a/ParaViewCore/VTKExtensions/Rendering/vtkIceTCompositePass.cxx
+++ b/ParaViewCore/VTKExtensions/Rendering/vtkIceTCompositePass.cxx
@@ -59,11 +59,8 @@ namespace
   void MergeCubeAxesBounds(double bounds[6], const vtkRenderState* rState)
     {
     vtkBoundingBox bbox(bounds);
- // scale the bounds a bit so that when showing a box we don't end up with
- // clipped edges e.g. when a Mandelbrot source was shown with parallel
- // rendering, the front edges would appear clipped in outline mode.
- bbox.Scale(1.1, 1.1, 1.1);
 
+ // Hande CubeAxes specifically has it wrongly implement the GetBounds()
     for (int cc=0; cc < rState->GetPropArrayCount(); cc++)
       {
       vtkProp* prop = rState->GetPropArray()[cc];
@@ -71,13 +68,11 @@ namespace
       if (cubeAxes != NULL && prop->GetVisibility() &&
         prop->GetUseBounds())
         {
- // cubeAxes has not clean API to give us the bounds it's using. So, we
- // use a heuristic instead. Simply scale the data bounds by 1.5 and we
- // call it 'even'.
- bbox.Scale(1.5, 1.5, 1.5);
- break;
+ // Use custom bounds API for cube axes to embed titles and labels
+ bbox.AddBounds(cubeAxes->GetRenderedBounds());
         }
       }
+
     bbox.GetBounds(bounds);
     }
 };
(0029617)
Utkarsh Ayachit   
2012-10-31 10:47   
merged into master, if applicable.
(0029636)
Alan Scott   
2012-10-31 20:09   
This has been fixed. Note that when the plane is very close to edge on that the text still disappears, but that probably makes sense. If this bug still exists, please try to replicate it with sources/ mandlebrot, add a note to this bug how to replicate it, and re-open this bug. See the related bug 13469.

Tested remote server, master, Linux.