1 # Copyright (C) 2010-2014 CEA/DEN, EDF R&D
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # Lesser General Public License for more details.
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 # This case corresponds to: /visu/3D_viewer/B1 case
22 from paravistest import *
23 from presentations import *
24 from pvsimple import *
29 # 1. First viewer creation
30 view1 = GetRenderView()
32 # 2. Second viewer creation
33 view2 = CreateRenderView()
36 size1 = view1.ViewSize
37 size2 = view2.ViewSize
39 w = size1[0] + size2[0]
40 w1 = math.trunc(w * 0.7)
43 view1.ViewSize = [w1, size1[1]]
44 view2.ViewSize = [w2, size2[1]]
46 # 4. Change view position
48 view1.ViewSize = [h//2, w]
49 view2.ViewSize = [h//2, w]
50 view1.ViewPosition = [0, h//2]
51 view1.ViewPosition = [0, 0]