I modified Andrew Jackson’s cool zebra stripe hack so it sets image quality (SetTessellationQuality) to “100”. I am trying to create another macro that sets the image quality back to “8” and turns off draft analysis (to help prevent users from saving oversize part files).
I got the image quality changes done, but I cannot figure out how to turn off the draft analysis. I was able to change display modes, but that doesn’t kill draft analysis. I could use some help.
Thanks
Dwight
Dim swApp As Object
Dim swModel As Object
Sub main()
Set swApp = Application.SldWorks
Set swModel = swApp.ActiveDoc
’ Set the image quality to coarse
swModel.SetTessellationQuality 8
. . . but a “1000” tessellation takes it to the very top. The difference is this . . .
image.png
. . . and this . . .
image.png
However, there’s still something wrong, not always making the change.
Case 1: starting with tessellation set manually to low, the line . . .
swModel.SetTessellationQuality 1000
. . . sets the image quality slider to the top of the red, but the image quality shows a tessellation that’s only about at the bottom of the red. I can then use macro commands to move the tessellation setting anywhere, but the actual image quality never goes above the bottom of the red.
Case 2: starting with tessellation set manually to the top of the red, the actual image quality is at the top of the red. I can then use macro commands to move the tessellation setting anywhere, and when I use the line . . .
swModel.SetTessellationQuality 1000
. . . it sets both the image quality slider and the actual image quality to the top of the red.
I don’t know what it is about setting it manually that makes a difference.