Changes between Version 52 and Version 53 of PythonOcc
- Timestamp:
- Oct 31, 2015, 5:21:47 PM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
PythonOcc
v52 v53 55 55 }}} 56 56 57 The next step is to init the display functions:58 57 V naslednjem koraku inicializiramo funkcije za display: 59 58 {{{ … … 62 61 }}} 63 62 [[Image(3Dprimitives.png, width=480px, right)]] 64 Let’s now define the two functions that create and display a box and a cylinder:65 63 Nato definiramo dve funkciji, ki izdelata kocko in cilinder: 66 64 {{{ … … 129 127 aEdge4 = BRepBuilderAPI_MakeEdge(aSegment4.Value()) 130 128 129 ''' 130 #Robove se lahko določi tudi direktno s točkami: 131 aEdge1 = BRepBuilderAPI_MakeEdge(aPnt1, aPnt2) 132 aEdge2 = BRepBuilderAPI_MakeEdge(aPnt2, aPnt3) 133 aEdge3 = BRepBuilderAPI_MakeEdge(aPnt3, aPnt4) 134 aEdge4 = BRepBuilderAPI_MakeEdge(aPnt4, aPnt1) 135 ''' 131 136 #Povezovanje robov v mrežo 132 137 aWire = BRepBuilderAPI_MakeWire(aEdge1.Edge() , aEdge2.Edge() ,\ … … 140 145 myBody = BRepPrimAPI_MakePrism(myFaceProfile.Face() , aPrismVec).Shape() 141 146 147 #Spodaj so zakomentirani ukazi za prikazovanje posameznih delov. 148 ''' 149 #Prikaz točk 150 display.DisplayShape(aPnt1) 151 display.DisplayShape(aPnt2) 152 display.DisplayShape(aPnt3) 153 display.DisplayShape(aPnt4) 154 ''' 155 ''' 156 #Prikaz robov 157 display.DisplayShape(aEdge1.Shape()) 158 display.DisplayShape(aEdge2.Shape()) 159 display.DisplayShape(aEdge3.Shape()) 160 display.DisplayShape(aEdge4.Shape()) 161 ''' 162 ''' 163 #Prikaz mreže 164 display.DisplayShape(aWire.Shape()) 165 ''' 166 ''' 167 #Prikaz profila 168 display.DisplayShape(myFaceProfile.Shape()) 169 ''' 170 #Prikaz telesa 142 171 display.DisplayShape(myBody) 172 143 173 start_display() 144 174 }}}