Macro Rotate View/cs: Difference between revisions
(Created page with "{{Macro|Icon=Text-x-python|Name=Rotate View by 90°|Description=Toto makro otočí objekt o 90° doleva. Funguje jen pokud jste v pohledu shora|Author=Yorik}}") |
(Created page with "Toto makro otočí objekt o 90° doleva. Funguje jen pokud jste v pohledu shora") |
||
Line 1: | Line 1: | ||
{{Macro|Icon=Text-x-python|Name=Rotate View by 90°|Description=Toto makro otočí objekt o 90° doleva. Funguje jen pokud jste v pohledu shora|Author=Yorik}} |
{{Macro|Icon=Text-x-python|Name=Rotate View by 90°|Description=Toto makro otočí objekt o 90° doleva. Funguje jen pokud jste v pohledu shora|Author=Yorik}} |
||
Toto makro otočí objekt o 90° doleva. Funguje jen pokud jste v pohledu shora |
|||
This macro rotates the current view by 90° to the left. Only works if you are in Top view |
|||
Revision as of 17:58, 6 February 2014
File:Text-x-python Rotate View by 90° |
Description |
---|
Toto makro otočí objekt o 90° doleva. Funguje jen pokud jste v pohledu shora Author: Yorik |
Author |
Yorik |
Download |
None |
Links |
Macros recipes How to install macros How to customize toolbars |
Macro Version |
1.0 |
Date last modified |
None |
FreeCAD Version(s) |
None |
Default shortcut |
None |
See also |
None |
Toto makro otočí objekt o 90° doleva. Funguje jen pokud jste v pohledu shora
import math
from pivy import coin
cam = Gui.ActiveDocument.ActiveView.getCameraNode()
rot = coin.SbRotation()
rot.setValue(coin.SbVec3f(0,0,1),math.pi/2)
nrot = cam.orientation.getValue() * rot
cam.orientation = nrot