mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-03 17:56:21 +03:00
0026307: Minor improvements in snowflake sample
- background is set to while, and lines are black - dimension line added - category is corrected
This commit is contained in:
parent
e11850fd23
commit
031224c91c
@ -1,10 +1,12 @@
|
||||
# Creation of 2d drawing
|
||||
|
||||
#Category: Modeling
|
||||
#Title: Snowflake - creation of 2d geometry
|
||||
#Category: Modeling
|
||||
#Title: Snowflake - creation of 2d drawing
|
||||
|
||||
pload MODELING AISV
|
||||
|
||||
puts "Generating sample drawing of snowflake..."
|
||||
|
||||
# make circular elements
|
||||
circle c11 5 5 0 5
|
||||
circle c12 5 5 0 3
|
||||
@ -121,10 +123,22 @@ eval compound [explode scale w] scale
|
||||
eval compound [explode mass w] mass
|
||||
compound sample occ name material sheets scale mass text
|
||||
|
||||
compound snowflake frame text drawing
|
||||
compound snowflake lines text drawing
|
||||
|
||||
# display in 3d view
|
||||
vinit Driver1/Viewer1/View1 w=1024 h=768
|
||||
vdisplay snowflake lines text
|
||||
vsetcolor snowflake 0 0 0
|
||||
vsetcolor lines 0 0 0
|
||||
vsetcolor text 0 0 0
|
||||
vsetcolorbg 255 255 255
|
||||
vtop
|
||||
vfit
|
||||
vfit
|
||||
|
||||
# add dimension
|
||||
explode snowflake v
|
||||
vdimension length -length -shapes snowflake_93 snowflake_15 -plane xoy -value 0.001 -dispunits mm -showunits -flyout 70 -label above -color black -text 5 3d sh
|
||||
|
||||
if { [regexp HAVE_GL2PS [dversion]] } {
|
||||
puts "You can use command vexport to generate PDF: vexport your_file_path.pdf"
|
||||
}
|
||||
|
@ -236,10 +236,10 @@ proc vsamples {} {
|
||||
set istitlefound 0
|
||||
while {[gets $chan line] >= 0} {
|
||||
if {[lindex [split $line " "] 0] == "#Category:"} {
|
||||
set acategory [string trimleft $line "#Category: "]
|
||||
set acategory [string trim [string trimleft $line "#Category: "]]
|
||||
}
|
||||
if {[lindex [split $line " "] 0] == "#Title:"} {
|
||||
set atitle [string trimleft $line "#Title: "]
|
||||
set atitle [string trim [string trimleft $line "#Title: "]]
|
||||
lappend alistofthree $acategory $atitle $fname
|
||||
incr istitlefound
|
||||
break
|
||||
|
Loading…
x
Reference in New Issue
Block a user