[Paraview] Toggling between 2D & 3D view Issue

komeil komeil at infovalley.net.my
Mon Sep 1 21:04:22 EDT 2014


Dear friends,

 

here is my implementation for having 2D view along with 3D view:

 

$("#view_3d").bind("mousedown", function(){

                                  if ($(this).hasClass("session_started")) {

 
pv.connection.session.call('vtk:load3DView', null);

                                                return false;

       }else{

                                 $(this).addClass("session_started");

                                  create3DView("#view_3d);


 
pv.connection.session.call('vtk:save3DView', null);

                }              

 

$(UI_AXIAL).bind("mouseup", function(){

                                pv.connection.session.call('vtk:save3DView',
null);

});

 

I have the similar code for 2D. There are 2 viewports created to show loaded
volume:

 

pv.viewport_3D = vtkWeb.createViewport({

                                                                session:
pv.connection.session

                                                });

 
pv.viewport_3D.bind("#view_3d");

 

and same code for 2D.

 

By clicking on each view, RPC function 'vtk:save3DView' or 'vtk:save2DView'
will be called. Each one changes the display properties & render view for
representing appropriate view. For example for loading 3D:

 

                dp.Representation = 'Volume'

                view = simple.GetRenderView()

                view.InteractionMode = '3D'

 

I can expect that it takes time to render the scene when the user clicks on
the other view, especially changing from 2D to 3D.

But, the issue is by clicking on the other view, the last view is shown
before the completion of the rendering. For instance, if the current view is
2D, and user clicks on 3D, immediately, the last 2D scene is displayed in 3D
view for a while, before having the rendered 3D view from the server.

 

My question is how to prevent system to show the 2D view in 3D view, and
just wait for the server to send rendered 3D scene.

 

 

Best regards,

 

 <http://www.infovalley.net.my/> cid:image007.jpg at 01CE563F.6F03C710
<https://www.facebook.com/INFOVALLEY> cid:image008.jpg at 01CE563F.6F03C710
<http://www.youtube.com/user/INFOVALLEYART>
cid:image009.jpg at 01CE563F.6F03C710 <https://twitter.com/infovalleyco>
cid:image010.jpg at 01CE563F.6F03C710 <http://infovalleyart.blogspot.com/>
cid:image011.jpg at 01CE563F.6F03C710

 

Komeil | Software Developer

iGeneR Sdn. Bhd.

INFOVALLEYR Group of Companies 

Unit 1.1, Level 1, Block B, MINES Waterfront Business Park

No.3, JalanTasik, MINES Resort City

43300 Selangor, Malaysia

Tel: +6 03 8941 5830| Fax: +6 03 8941 5970

 

"This mail (including any attachments) may contain confidential, proprietary
or legally privileged information belonging to INFOVALLEY Group of
Companies. In case you are not the original intended recipient of the
message; you must not directly or indirectly, use, disclose, distribute,
print, or copy any part of this message. You are requested to delete it and
inform the sender. Any views expressed in this message are those of the
individual sender unless otherwise stated. We have taken enough precautions
to prevent the spread of viruses. However the company accepts no liability
for any damage caused by any virus inadvertently transmitted by this email."

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20140902/b6dbe0d2/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 1314 bytes
Desc: not available
URL: <http://public.kitware.com/pipermail/paraview/attachments/20140902/b6dbe0d2/attachment.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image002.jpg
Type: image/jpeg
Size: 904 bytes
Desc: not available
URL: <http://public.kitware.com/pipermail/paraview/attachments/20140902/b6dbe0d2/attachment-0001.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image003.jpg
Type: image/jpeg
Size: 1036 bytes
Desc: not available
URL: <http://public.kitware.com/pipermail/paraview/attachments/20140902/b6dbe0d2/attachment-0002.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image004.jpg
Type: image/jpeg
Size: 848 bytes
Desc: not available
URL: <http://public.kitware.com/pipermail/paraview/attachments/20140902/b6dbe0d2/attachment-0003.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image005.jpg
Type: image/jpeg
Size: 925 bytes
Desc: not available
URL: <http://public.kitware.com/pipermail/paraview/attachments/20140902/b6dbe0d2/attachment-0004.jpg>


More information about the ParaView mailing list