Thanks Pat - it works :)<div><br></div><div>Is there any change we could change line 198 in vtkProcessModule.cxx to set the Z shift value to 2.0e-4 instead of 2.0e-3? That fixes my cases. If this is remove altogether I get dotted lines when drawing contour lines on a surface.</div>
<div><br></div><div>Regards,<br>Paul</div><div><div><br><div class="gmail_quote">On 30 June 2010 18:00, pat marion <span dir="ltr"><<a href="mailto:pat.marion@kitware.com">pat.marion@kitware.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">It should be:<br><br>from libvtkRenderingPython import vtkMapper<br><br>This should work, but if it does not then you may need to set your LD_LIBRARY_PATH to include the directory with the .so.<br>
<br>For Windows it would be:<br>
<br> from vtkRenderingPython import vtkMapper<br><font color="#888888"><br>Pat</font><div><div></div><div class="h5"><br><br><div class="gmail_quote">On Wed, Jun 30, 2010 at 12:53 PM, Paul Edwards <span dir="ltr"><<a href="mailto:paul.m.edwards@gmail.com" target="_blank">paul.m.edwards@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204, 204, 204);padding-left:1ex"><div>I get the following error when calling "from libvtkRendering.so import vtkMapper":</div>
<div><br></div><div> ImportError: dynamic modules does not define init function</div><div><br></div><div>Can anyone see what I am doing wrong?</div>
<div><br></div><div>I'm on linux with an up-to-date development version.</div><div><br></div><div>Thanks in advance,<br><font color="#888888">Paul</font></div><div><br></div><div>PS I'm having problems with contour lines showing through the surface. Commenting out the lines (199 & 200) in vtkProcessModule.cxx but this is for a user who has an existing version...</div>
<div><div></div><div>
<div><br><div class="gmail_quote">On 30 October 2009 12:04, Utkarsh Ayachit <span dir="ltr"><<a href="mailto:utkarsh.ayachit@kitware.com" target="_blank">utkarsh.ayachit@kitware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204, 204, 204);padding-left:1ex">
Oluminde,<br>
<br>
It makes sense to provide an option in the "Settings" dialog to<br>
tweak/disable offsetting for resolving z-fighting. I've added a<br>
feature request to the bug tracker:<br>
<a href="http://paraview.org/Bug/view.php?id=9801" target="_blank">http://paraview.org/Bug/view.php?id=9801</a><br>
<br>
To fix this without recompiling, here's a crazy hack to overcome this<br>
issue in builtin mode (i.e. when not connected to server):<br>
Before loading any datasets<br>
* open python shell<br>
* Run the following commands:<br>
> import os<br>
> if <a href="http://os.name" target="_blank">os.name</a> == "posix":<br>
> from libvtkRendering.so import vtkMapper<br>
> else:<br>
> from vtkRenderingPython import vtkMapper<br>
> vtkMapper.SetResolveCoincidentTopologyToOff()<br>
<br>
If connected to a server, you can run the same python commands as part<br>
of the python script for a programmable source or filter.<br>
<font color="#888888"><br>
Utkarsh<br>
</font><div><div></div><div><br>
<br>
On Fri, Oct 30, 2009 at 6:48 AM, Utkarsh Ayachit<br>
<<a href="mailto:utkarsh.ayachit@kitware.com" target="_blank">utkarsh.ayachit@kitware.com</a>> wrote:<br>
> Ken,<br>
><br>
> Offsetting the points/lines handles the cases when people try to<br>
> render two overlapping datasets: one as surface and other as<br>
> wireframe, and they don't necessarily want to show surface with edges<br>
> (say they want scalar coloring for both surface and the wireframe). I<br>
> believe Jean Favre has several such use cases.<br>
><br>
> Utkarsh<br>
><br>
> On Mon, Oct 26, 2009 at 1:18 PM, Moreland, Kenneth <<a href="mailto:kmorel@sandia.gov" target="_blank">kmorel@sandia.gov</a>> wrote:<br>
>> Utkarsh,<br>
>><br>
>> After reading this question from Olumide, I noticed that ParaView now turns<br>
>> on ZShift for lines and points (vtkProcessModule.cxx, 198-199). I don’t<br>
>> know why this is. This effect is turned off when drawing surface+edges<br>
>> (vtkOpenGLCoincidentTopologyResolutionPainter.cxx, 56-58) because it<br>
>> automatically switches to offsetting the polygons the polygons back<br>
>> (vtkOpenGLRepresentationPainter.cxx, 79-85). Should we remove those two<br>
>> lines from vtkProcessModule.cxx?<br>
>><br>
>> -Ken<br>
>><br>
>><br>
>> On 10/26/09 12:53 AM, "Olumide" <<a href="mailto:50295@web.de" target="_blank">50295@web.de</a>> wrote:<br>
>><br>
>> Hi -<br>
>><br>
>> I use Paraview not for visualizing datasets, but for inspecting<br>
>> polygonal meshes and the operations I perform on them. My work involves<br>
>> computing various points and line segments on meshes, and I use<br>
>> VTK/Paraview to see if the points and line segments are where they ought<br>
>> to be (if not, I conclude that there's a bug in my code and then proceed<br>
>> to hunt it down).<br>
>><br>
>> <Digression><br>
>> Why I use VTK for this task: VTK is the the only publicly available 3d<br>
>> graphics file format I'm aware of that explicitly supports and points,<br>
>> lines, and meshes, and has a viewer for viewing these entities. Most<br>
>> other 3d graphics file formats either support surfaces alone or have no<br>
>> ready-made viewers.<br>
>> </Digression><br>
>><br>
>> Lately however, upon closer inspection, I've noticed that many of the<br>
>> points and line segments that I compute appear to hover above the mesh<br>
>> they are computed from and never quite touch it, and points never seem<br>
>> to lie on the line segments they are supposed to. For example, see:<br>
>> <a href="http://i17.photobucket.com/albums/b52/videohead/SurfaceError.png" target="_blank">http://i17.photobucket.com/albums/b52/videohead/SurfaceError.png</a><br>
>> (note that the yellow line segment hover above the blue surface in the<br>
>> horizon)<br>
>><br>
>> After much experimentation, debugging and consultation, I now suspect<br>
>> that this is caused by polygon offset in Paraview, designed to prevent<br>
>> z-fighting. I would therefore like to know:<br>
>><br>
>> (i.) if my suspicion is correct i.e. Paraview implement polygon offset<br>
>> for preventing z-fighting in this case<br>
>><br>
>> (ii.) if the above is true, how polygon offset can be disabled without<br>
>> recompiling the source<br>
>><br>
>> Thanks,<br>
>><br>
>> - Olumide<br>
>><br>
>> _______________________________________________<br>
>> Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
>><br>
>> Visit other Kitware open-source projects at<br>
>> <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
>><br>
>> Please keep messages on-topic and check the ParaView Wiki at:<br>
>> <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
>><br>
>> Follow this link to subscribe/unsubscribe:<br>
>> <a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
>><br>
>><br>
>><br>
>><br>
>> **** Kenneth Moreland<br>
>> *** Sandia National Laboratories<br>
>> ***********<br>
>> *** *** *** email: <a href="mailto:kmorel@sandia.gov" target="_blank">kmorel@sandia.gov</a><br>
>> ** *** ** phone: (505) 844-8919<br>
>> *** web: <a href="http://www.cs.unm.edu/%7Ekmorel" target="_blank">http://www.cs.unm.edu/~kmorel</a><br>
>><br>
>><br>
><br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
</div></div></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
<br></blockquote></div><br>
</div></div></blockquote></div><br></div></div>