WWW.DANCAD3D.COM (sm): THE OFFICIAL DANCAD3D (tm) "BETA TEST" WEB SITE.

TERMS OF USE, HOME, INDEX, SHORTCUT, WHAT'S NEW, DOWNLOADS, GET MAIN ZIP, DOCUMENTATION, VIDEO, HOOKUP#1, #2, #3, KEYWORDS

FEATURE FILM 4K+ DIGITAL CINEMA UNCOMPRESSED EDITING AND SOUND MIXING
PLUS DIY MOVIE 35mm FILM SCANNING AND DIY 35mm FILM RECORDER SOFTWARE.
"FREEISH" DI (DIGITAL INTERMEDIATE) SOFTWARE TO DOWNLOAD FOR MAKING
FEATURE MOTION PICTURES FOR CINEMA THEATRE, ULTRA-HD, HD, AND BROADCAST.
WORKS WITH FOOTAGE FROM DIGITAL CINEMA CAMERAS AND MOVIE FILM SCANS.
HIGH DEPTH COLOR CORRECTION. FRAME ACCURATE EDITING. HI-FI SOUND MIXING.

DANCAD3D (tm) DRAWING EDITOR, click on image for more info. and larger images. 3D ROBOTIC ANIMATION, click on image for more info. and larger images. 3D CONTOUR SURFACE, click on image for more info. and larger images. 3D CAM TOOL PATH, click on image for more info. and larger images. STEPPER MOTORS FOR CAM, click on image for more info. and larger images. DANCAM.EXE (tm) OPERATING 3D MILL, click on image for more info. and video. IM HELP STATUS, click on image for more info. and IM address.
Kodak (tm) LAD film negative scan image made with Canon XTi (tm) DSLR. Kinema Edit list Grading Levels #1 color correction tool . Kinema Edit list Grading Curves #1 color correction tool. Kinema Edit list Grading chroma Masking tool Vector display. Kinema Edit list Grading chroma Masking tool Waveform display. Kinema Edit list Grading Sharp/Soft filter tool. Kodak (tm) LAD image color corrected positive.
Click on these thumbnails for related information about my current software, features, and IM support. Hold [Shift] and click [Reload] to refresh IM thumbnail.

If are helping "Beta Test" you should report bugs and feel free to ask questions about the program's commands, it is best to e-mail me at tempnulbox (at) yahoo (dot) com and put "DANCAD3D (tm) 24x7 SUPPORT SUBMISSION" in the email subject line so your mail is not deleted as junk. See Section: 8 for more information about support related issues. I want you to ask questions so long as they are on the subject and relate to the current program's commands. If you do not get some kind of reply assume I did not get your message and resend. All submissions and correspondence become the sole property of Daniel H. Hudgins to do with as he sees fit, so stay on subject.

SECTION: 3.4.52.C
Appendix B: Macro commands starting with C.
This Section, Overview, Steps, Details, and Commands C.

Copyright (C) 1986-2009 by Daniel H. Hudgins, All Rights Reserved.

No part of "This Web Site" (HTML document), including associated files, may be: distributed, sublicensed, transmitted, copied, archived, mirrored, modified, bundled, embedded, sold, given away, rented, loaned, or shared in any form without express written permission in a formal Vendor agreement contract dated and signed in ink obtained directly from Daniel H. Hudgins by registered postal mail. All agreements for permission to distribute expire after a period no greater than one year from the date of the signing of the agreement by Daniel H. Hudgins. See the current "EULA" for information regarding limited copying and storage for the purpose of "Beta Testing" "This Web Site."

To view or use the current version of this Web page you may need to reload or refresh the display of this page by your browser. Just clicking on the browser's [Reload] or [Refresh] icon may not be enough to insure that all of the page's most current contents have been cached and displayed. Some browsers may have additional commands to help display the page's most current contents such as: holding down the [Shift] key and clicking on the [Reload] icon, holding down the [Control] key and clicking on the [Refresh] icon, holding down the [Control] and [Shift] keys and clicking on the [Refresh] icon, pressing the [Control] and [F5] keys, pressing [Control] and the [R] key, or some other combination of keys or clicks. Check to see which commands your HTML browser uses to load the most current page contents into its cache and then to display them onto the screen.

This Web site is dedicated to the thousands of "users" of my programs, those who have helped test my programs over the last 23 or so years, and especially those who shared their experiences with me.

You must read this notice: This is a licensed Web site (HTML document and associated files). You must read and agree to be legally bound in contract by the Terms of Use and conditions given in the End User License Agreement ("EULA"), Legal Notices, Instructions, Warnings, Disclaimers, and all other text in "SECTION: 0" of "This Web Site" (HTML document and associated files) before reading or using any of the information, software programs, and or files, contained in, linked to, and or associated with, "This Web Site" (HTML document and associated files). Any use or "Beta Testing" of "This Web Site" constitutes your acknowledgment of your full agreement with the current End User License Agreement ("EULA") and your decision to have this current license supersede all prior and contemporaneous agreements and understandings. Information and files in "This Web Site" (HTML document and associated files) have been placed here so that long time users of "The Author's" programs DANCAD3D.COM (tm) , DANCAD87.EXE (tm), DANCINEL.EXE (tm), DANCINES.EXE (tm) , DANCAM.EXE (tm) , or DANPLOT.EXE (tm) could help proofread the text of the documentation files or screens displayed, and also help test data files, example files, and or any software programs that might be made available from time to time, to aid "The Author" in finding mistakes, bugs, and other errors, omissions, defects, mistakes, and faults. Everything in "This Web Site" (HTML document and associated files) is "Beta Test", "Beta Code", Experimental, Preliminary, requires proofreading, or is being evaluated for possible revision, and is NOT warranted to be free of defect. To help "The Author" report any bugs, foul-ups, defects, or mistakes that you find, see "SECTION: 8" for instructions. "This Web Site" (HTML document and associated files) and all other files and programs by Daniel H. Hudgins are made available "AS IS" without warranty of any kind express, expressed, or implied. All offers and specifications are subject to change or discontinuation without notice of any kind. Please look over "SECTION: 8" of "This Web Site" before contacting "The Author."


Click here to go back to SECTION 3.0.0.0 Index for documentation pages.
Click here to go back to SECTION 3.4.0.0 Index for supplemental documentation pages.
Click here to go back to SECTION 3.4.52.0 Index for Appendix B pages.
Click here for top of DANCAD3D.COM (tm) Web site home page or here for home page INDEX.
Click here to check the current internet document if you are viewing this from a disk copy.
Note: If you want to go back to the previous link use the [Back] button in your browser.

This Section.

The text in this section was derived from the v2.5 CAD manual, and has been updated somewhat, but differences between different releases of v2.5, v2.6 and v2.7 may mean that some of the information may not apply to the version you are using. Some adjustment may be required for versions prior or subsequent to v2.7A.

You may not distribute, sell, rent, share, or give away these HTML documentation files or printed copies of them. You may not extract text from these HTML documentation files for distribution, sale, rent, sharing, or giving away. You can use the [Print] option in your browser to make one copy for yourself to mark up in order to help me proofread the text for mistakes.

Documents may be available to download from time to time, you can check SECTION: 9 to see what the current situation with regard to downloadable files is. The names of these documentation files may change, and they may be edited, combined, or eliminated in the future, without notice.

You may need to adjust your browser for best viewing of the pre- formatted text by changing the "font" size using the commands in your browser (see the help in your browser, or use the pull-down menus in your HTML browser.) If some letters in words on the screen appear to be missing or scrambled try changing the font size in your browser as this sometimes happens even though the words are spelled correctly in the HTML code.

Use the "Edit, Find in page Ctrl+F" or "Edit, Find (in this page)... Ctrl+F" command in your browser to search for keywords within the documentation text in this HTML page. You will need to search over again in the other pages in this HTML document for the same keyword since your browser may not search for a keyword beyond the current page that is loaded.

Click here to go back to the top of this page.

Overview of Appendix B: Macro commands.

DANCAD3D (tm) macro commands can used to write a macro "program" that will operate DANCAD3D (tm) automatically. DANCAD3D (tm) can also automatically generate an output macro file of these commands while you use the programs menus. Appendix B lists detailed information about many of the individual macro commands.

Click here to go back to the top of this page.

Steps to use Macro commands.

Steps to use Appendix B: Macro commands.

  1. Read this section to learn what commands are available.

  2. Use [W]rite from DANCAD3D (tm)'s main menu to write or edit macros.

  3. Use the automatic [O]utput macro feature to automatically code these macro commands to a file while you use the menu commands.

Click here to go back to the top of this page.

Detailed discussion of Appendix B: Macro commands.

This Appendix B contains information on the DANCAD3D (tm) macro programming commands that are available for your use in writing automatic CAD, CAE, or CAM programs. See the pages in this Web site that link to this page for additional information.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

Appendix B: Macro Commands that start with C.

Below are details about macro commands that start with C.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CENTER

PURPOSE:      To change an elements center point.  Acts  on  the  last
              selected element.  The element's  center  point  is  the
              point  in  the  workspace  about  which the element will
              rotate when the ROTATE CENTER command is used,  grow  to
              and  from when the MAGNIFY CENTER command is used,  flip
              across when the FLIP CENTER command is used,  and  serve
              as the reference point when the OFFSET command is used.

MAIN MENU:    [D] [?...] [E] [S]

KEYWORD:      CENTER_ELEMENT_AT  or  CENTER

PARAMETERS:   3

TYPE:         r......... X_value -1E18 to 1E18.
              r......... Y_value -1E18 to 1E18.
              r......... Z_value -1E18 to 1E18.

FORMAT:       CENTER r r r

EXAMPLE:      # 7 CENTER -1.234567E-10 0.001 666

              { Set center of element No. 7 to given x y z values. }

              # 128 CENTER [ |x * |f ] [ |y * |f ] [ |z * |f ]

HINT:         Put the center at the corner of an element if  you  want
              the element to turn on that point or if you want to make
              the  element  bigger or smaller but have the corner stay
              where it is.  If you do not know what values to use  for
              the  center  you  want,  try using the [D]rawing command
              from the main menu and zooming in on the point you want,
              then note the point from the cursor's x y  z  values  at
              the  top  of  the screen.  The center can be anywhere in
              the workspace.  You can  use  the  defined  center  with
              MAGNIFY  to place the origin for explosion or implosion,
              and with ROTATE to place the point about which something
              will  orbit.   Changing  the  element's  center   during
              animation  can produce compound motions.  Be sure to use
              the select element number,  i.e.  #,  command before the
              CENTER command to select the element desired.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CHECK_SUM

PURPOSE:      CHECK_SUM allows a macro to check a file for  variations
              in  its  binary data,  when compared to the value given.
              No action is taken if the file checks OK,  otherwise the
              macro is stopped with an error.  New for v2.7A.

MAIN MENU:    [F] [U] [H] [C]

KEYWORD:      CHECK_SUM

PARAMETERS:   3 (for compare mode)

TYPE:         w......... mode = C or COMPARE.
              f......... filename of file to check.
              r......... value to check for from file.

FORMAT:       CHECK_SUM w f r

EXAMPLE:      CHECK_SUM COMPARE D:\PATH\FILENAME.MAC |VALUE
              CHECK_SUM C SOMEFILE.BIN 35682

NOTE:         CHECK_SUM  compares the scanned value for the filename's
              check  sum  with  value  entered  in the macro,  if they
              compare nothing happens, if they do not compare an error
              message is displayed and the macro stops.

HINT:         To  find the right check sum value you can use the Files
              Utilities Hex-Binary Find  check  sum  command.  If  the
              automatic  output macro is on the Find check sum command
              will code into the  macro  command  and  values  to  the
              bottom of the current output macro file.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CLEAN

PURPOSE:      To  remove  fractional  part,  or  round off x y z point
              values.  The CLEAN command has been changed in v2.7A, in
              both  the  [N]umerical  sub-menu  and the new version in
              drawing [J]ockey sub-menu have been updated.  CLEAN  has
              some  uses in removing hole position errors when working
              with scanned or imported  elements,  particularly  those
              for drilling PCB holes.

MAIN MENU:    [N] [C]  or  [D] [?...] [J] [C]

KEYWORD:      CLEAN

PARAMETERS:   3

TYPE:         r......... x_round_value, 1e-18 to 1e18.
              r......... y_round_value, 1e-18 to 1e18.
              r......... z_round_value, 1e-18 to 1e18.

FORMAT:       CLEAN r r r

EXAMPLE:      # 0 CLEAN 1 1 1 ; Round all points like past versions.

              # 1 CLEAN 0.05 0.05 1 ; Round different on Z axis.

HINT:         Use clean to round off the character drawings before you
              make  a  font  file  so  you can use the drawing command
              [P]ull-point in the lines sub-menu to compensate for the
              conversion from real coordinates to integers.  CLEAN can
              also remove rounding errors introduced when an object is
              rotated 90 degrees (providing that the points originally
              fell on regular points of the same  spacing.)  See  also
              the  JET  TRACE  and DRILL_POINTS macro commands.  CLEAN
              may be useful to make drill points from scanned patterns
              "snap" to exact grid points within the  rounding  value,
              the  OFFSET macro command can later be used to shift the
              point pattern to be centered on given center lines.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CONVERT

PURPOSE:      The new macro command CONVERT can be used to  convert  a
              "Line Art" 1 bpp BMP file  into  a  JET  page  file,  or
              convert  a JET page file into a BMP graphics file.  This
              command differs from the LOAD BMP  and  SAVE  BMP  macro
              commands  since  the image goes between the BMP file and
              the JET page  file  rather  than  the  graphics  screen,
              therefore  the  maximum resolution can be higher and the
              image size can be adjusted with the settings in the  JET
              driver file.  BMP is a standard graphics file format, so
              by  saving  your  drawing  in BMP file format you may be
              able to load your drawing  into  the  graphics  software
              that  came  with  your  scanner and convert the BMP file
              into JPG or GIF for display on the  internet.  In  order
              to  load scanned drawings into the drawing workspace you
              need to use the JET TRACE macro command to  convert  the
              JET  page  file  the scanned image was converted over to
              into an *.ASC drawing file,  then  use  the  LOAD  ASCII
              macro  command  to  load the *.ASC drawing file into the
              drawing workspace. New for v2.7A.

MAIN MENU:    [F] [L] [I] [B]  or  [F] [S] [I] [B]
              [F] [U] [B] [B]  or  [F] [U] [B] [J]
              [F] [H] [O]

KEYWORD:      CONVERT

PARAMETERS:   5

TYPE:         The format for making a 1 bpp "Line Art" *.BMP file is:

              w......... source type mode = PAGE.

              w......... result type mode = BMP

              f......... source filename, is  the name of the JET page
                                          file that has the  image  in
                                          it,  you would have used the
                                          JET ADD command to  put  the
                                          image in this JET page file.
                                          Remember  that  a  JET  page
                                          file file name can have only
                                          a  maximum  of  six  letters
                                          since  the  last two letters
                                          are used for  the  count  of
                                          the  strip  in the page file
                                          set i.e. up to strip 99.

              f......... result filename, is  the filename for the new
                                          BMP file you  are  going  to
                                          make,  it must be a filename
                                          that   has   the   extension
                                          *.BMP,    or    your   other
                                          graphics programs  will  not
                                          recognize it as a BMP file.

              f......... driver filename, is one of the JET drivers in
                                          the  DRIVERS\  sub-directory
                                          that you have installed with
                                          the   main   menu   [C]hange
                                          command  as  the default JET
                                          driver and you used to  make
                                          and edit the JET page with.

              The format for converting a 1 bpp "Line Art" BMP file to
              a JET page file is:

              w......... source type mode = BMP.

              w......... result type mode = PAGE.

              f......... source filename, is  the  filename  of  a BMP
                                          file that has been edited to
                                          be  of  the  right  type and
                                          size to match the  JET  page
                                          file  that  you have made to
                                          receive the image.  You  can
                                          use   the  [H]ardcopy  [J]et
                                          [I]nstall command to look at
                                          the dimension values used in
                                          the JET driver that was used
                                          to make the  JET  page  file
                                          that  you  want  to  put the
                                          image in from the BMP file.

              f......... result filename, is the filename of JET  page
                                          file set that has been  made
                                          before  hand  to receive the
                                          converted image, use the JET
                                          MAKE macro command  to  make
                                          the page file before you use
                                          CONVERT.   Remember  that  a
                                          JET page file file name  can
                                          have  only  a maximum of six
                                          letters since the  last  two
                                          letters  are  used  for  the
                                          count of the  strip  in  the
                                          page  file  set  i.e.  up to
                                          strip 99.

              f......... driver filename, is one of the JET drivers in
                                          the  DRIVERS\  sub-directory
                                          that you have installed with
                                          the   main   menu   [C]hange
                                          command as the  default  JET
                                          driver  and you used to make
                                          the JET page with.

FORMAT:       CONVERT w w f f f

EXAMPLE:      CONVERT PAGE BMP MYPAGE.JET RESULT.BMP DRIVERS\300D8X11.JET
              CONVERT BMP PAGE MYSCAN.BMP RESULT.JET DRIVERS\300D8X11.JET
              ; Below is a more complete example of saving and
              ; loading BMP files to and from the workspace.


              VERSION v2.7A
              ; Here is an example macro file that makes  a  BMP  file  then
              ; loads that file into the workspace,  the original element is
              ; in color 1 (blue when  default  colors  are  used)  and  the
              ; outline  of it from the BMP file is in color 14 (yellow when
              ; default colors are used),  set the background color to black
              ; and zoom in using the drawing editor to see this.

              ; Start make a element.
              INITIALIZE
              POLYGON 360 360 3.5 1 1 0 0
              LETTERING
              TEST
              0 0 0   0 0 0    2 2
              1 1 0 0    0 1 0.5 8
              C J DANCAD3D.FON
              #    2 MAGNIFY C 0.8 1 1
              JOIN 0
              ; End make a element.

              ; Start save element as a BMP file.
              JET MAKE BMPS1.JET DRIVERS\300D8X11.JET
              # 0 JET ADD 0 0 0 -1.0000E+18 240 10 0 0 BMPS1.JET DRIVERS\300D8X11.JET
              CONVERT PAGE BMP BMPS1.JET BMPTEST1.BMP DRIVERS\300D8X11.JET
              ; End save element as a BMP file.

              ; Start load BMP file into workspace as drawing lines.
              JET MAKE BMPL1.JET DRIVERS\300D8X11.JET
              JET MAKE BMPL2.JET DRIVERS\300D8X11.JET
              CONVERT BMP PAGE BMPTEST1.BMP BMPL1.JET DRIVERS\300D8X11.JET
              JET FATTEN D 0 BMPL1.JET DRIVERS\300D8X11.JET
              JET COMBINE BMPL1.JET BMPL2.JET BMPL2.JET O DRIVERS\300D8X11.JET
              JET FATTEN I 1 BMPL2.JET DRIVERS\300D8X11.JET
              JET COMBINE BMPL1.JET BMPL2.JET BMPL2.JET M DRIVERS\300D8X11.JET
              JET TRACE 1 240 BMPL1.ASC BMPL2.JET DRIVERS\300D8X11.JET
              LOAD ASCII BMPL1.ASC { Element 2 }
              # 2 MEDIAN Z F
              # 2 CENTER 0 0 0
              ; End load BMP file into workspace as drawing lines.

              # 2 LINETYPE 14 1 0 0 ; set line color for traced element.

              ; See also BMPTEST1.MAC if it is in DANCAD3D.ZIP (tm)


NOTE:         Once a BMP file is loaded into a JET PAGE file  the  JET
              TRACE command can be used to convert the  raster  pixels
              into  line  segments  that  can  be  used in the drawing
              workspace, edited,  and saved for use as tool path file.
              Thereby you can convert scanned images into objects made
              on a CAM machine.

              The  size  of the BMP file in pixels must match the size
              selected in the JET driver you will  be  using,  so  try
              making a BMP file from a JET page file first,  load that
              BMP file into your graphics  program,  check  the  image
              size,  then  make  or  edit  your  scanned  images to be
              exactly that same size, i.e.  use crop or resize in your
              image editing software that came with your scanner.

              When you save scanned artwork as a BMP file you need  to
              save  it as 1 bpp or "Line Art" black and white type BMP
              file.  To do this you may need to use  the  commands  in
              the software that came with your scanner to "convert to"
              the  two  color  mode from 16 or 256 palette modes.  The
              macro command LOAD BMP can load 256 palette  mode  color
              or  gray  BMP files,  so for that use your image editing
              software to convert 2 color (1 bpp) or 16 color (4  bpp)
              BMP files into 256 color (8 bpp) files.

              The macro command UTILITY BMP256_TO_ASCII can be used to
              convert  BMP  256  palette mode color or gray tone files
              into an ASCII file that can  then  be  loaded  into  the
              drawing  workspace  as line segments.  The macro command
              UTILITY BMP256_TO_ASCII can make  conversions  from  BMP
              into  two  or  three  dimensional  elements,  the  third
              dimension being taken from the brightness values on  the
              BMP  file.  The UTILITY BMP256_TO_ASCII command can also
              be used to make triangle elements so that  data  from  a
              BMP file can be used with the hidden line display modes.
              The   3D   data   conversion   of   modes   of   UTILITY
              BMP256_TO_ASCII might be useful in making tool paths for
              matching 3D parts or  engraving  from  scanned  artwork.
              The  UTILITY  BMP256_TO_ASCII  has  the advantage of not
              requiring conversion to the  fixed  size  of  the  video
              screen, or JET page file.

              This  CONVERT  BMP  PAGE macro command is mostly for use
              with the JET TRACE command for CAM  work  with  specific
              kinds of "Line Art" such as PCB traces, or various kinds
              of engraving.

              The  JET  driver  files  are  edited with the [H]ardcopy
              [J]et [I]nstall command.  You can change the  resolution
              between  150  dpi and 300 dpi,  and edit other values to
              change the size of the image to be saved or loaded.  You
              can use the JET driver to control the size  of  the  BMP
              file made, so that the image will not be too big.

              If  lines  appear to be missing when you look at the BMP
              file in your graphics editing  program  that  came  with
              your scanner,  especially when the BMP file is displayed
              so that  it  fits  in  the  editing  screen  area,  your
              graphics  program  is probably not displaying all pixels
              when images are reduced in  size,  change  the  view  to
              "actual,"  "1:1,"  "full  size," or whatever the mode is
              that shows one pixel in the file to be one pixel on  the
              screen.

              If  you  try  to  reduce  BMP  files,  in  your graphics
              software that came with your scanner, to a smaller size,
              the software may drop out some thin lines because of the
              method it uses to shrink drawings,  so it may be  better
              to  use the scale command in DANCAD3D.COM (tm)'s JET ADD
              command to make the element look smaller,  then use  the
              crop command in your scanner's image editing software to
              "cut  out"  or  "crop"  the  portion of the BMP file you
              want, thereby making a smaller graphics file by cropping
              rather than resizing.

HINT:         There are several ways that BMP files might be saved and
              loaded with macro commands:

              UTILITY  BMP256_TO_ASCII,  can  be  used to load a 8 bpp
              (256 palette mode color or gray tone) *.BMP  image  file
              and  convert  it  into  an ASCII file that can be loaded
              into the drawing workspace using the LOAD ASCII command.
              Various modes can convert the BMP image into  2D  or  3D
              lines  or triangles for use with different display modes
              or for use as a tool path for use with the CAM programs.
              In BMP files saved from some graphics programs it may be
              best to crop the image in the BMP file to have a  number
              of horizontal pixels that is an even multiple of 8,  and
              total pixels that are an even multiple of 32.

              UTILITY BMP256OIL,  works  a  little  like  the  UTILITY
              BMP256_TO_ASCII  and  also converts BMP 8 bpp file to an
              ASCII file,  but has the ability to select just  one  of
              the  256  palette  mode's  colors  or  gray  tones.   By
              selecting just one of the colors or gray tones  you  may
              be able to make a tool path file to apply just one color
              of paint or the equivalent at a time.  UTILITY BMP256OIL
              can  add the motions to move the brush in and out of the
              "paint pot" so that the  brush  picks  up  paint  before
              drawing  each pixel,  or stroke of pixels.  In BMP files
              saved from some graphics programs it may be best to crop
              the image in the BMP file to have a number of horizontal
              pixels that is an even multiple of 8,  and total  pixels
              that are an even multiple of 32.

              CONVERT  can  convert a 1 bpp "Line Art" BMP file into a
              JET page file,  or convert a JET page file into a 1  bpp
              "Line Art" BMP file.  To make your BMP file this way you
              first  make  a  JET page file,  then use JET ADD to copy
              your drawing lines from the workspace into the JET  page
              file, then CONVERT can read the JET page file and save a
              *.BMP  file  of the JET page.  To load a BMP 1 bpp "Line
              Art" file into the workspace you  would  first  use  JET
              MAKE  to make a JET page file,  then use CONVERT to copy
              the BMP image into that JET page file,  then use the JET
              TRACE  and  possibly  some  of the other JET commands to
              make an ASCII trace of the image in the JET  page  file,
              then  use  the LOAD ASCII file to load the drawing lines
              in the ASCII file into the drawing  workspace.  The  BMP
              file to be loaded must match the pixel size given in the
              JET driver file used to make the JET page file exactly.

              The SAVE BMP command can save the graphics screen as a 8
              bpp  or 24 bpp BMP file.  How many colors or gray tones,
              the BMP file type i.e.  8 bpp or 24 bpp,  and the  image
              size  saved  depends  on the graphics mode set when SAVE
              BMP is called.  Color images made using the hidden  line
              modes  can be saved using SAVE BMP,  and possibly loaded
              into other  graphics  programs  for  printing  on  color
              printers.  In  order  to save the higher resolution SVGA
              color  graphics  modes  your  computer   must   have   a
              compatible SVGA video card with enough memory to display
              those  modes.  On  computers  with  or  without SVGA the
              GRAPH_MODE BMP mode can be used with the DISPLAY command
              to save 24 bpp BMP files in color and of larger sizes if
              needed.

              The LOAD BMP command can load an 8 bpp  or  24  bpp  BMP
              file  into  the  graphics  screen.   Because  the  color
              palette used for the DISPLAY command  can  be  different
              from  the palette in the BMP file,  files not saved from
              DANCAD3D.COM  (tm)   will   probably   require   palette
              conversion  when  being  loaded.  Because of mismatch in
              the colors after palette conversion, better results will
              probably be obtained converting  gray  scale  monochrome
              images  from  BMP  files.   Color  images  that  undergo
              palette  conversion  may  look   somewhat   "posterized"
              depending on the color content in the original BMP file.
              The  BMP  file to be loaded must match the pixel size of
              the graphics mode selected exactly.  24  bpp  BMP  files
              that load into 24 or 32 bpp video screens do not require
              palette  conversion,  and so look about the same as when
              displayed elsewhere.

              FILES  CONVERT can be used to convert a NOR file made by
              using DANPLOT.EXE (tm)'s scanning probe mode into a  BMP
              file.  This  could make a BMP 256 palette mode gray tone
              file,  but you may be able to convert that to "Line Art"
              with  some  other  graphics program you probably have on
              your computer.  It may  be  best  to  select  the  image
              scanning  dimensions  that  have  a number of horizontal
              pixels that is an even multiple of 8,  and total  pixels
              that  are  an even multiple of 32 for compatibility with
              some programs.

              You  can  try  to  use  the software that came with your
              scanner to edit the BMP files,  and  crop  them  to  the
              right size.  Some programs have problems actually making
              the image the correct number of horizontal and  vertical
              pixels,  you  may  need  to enter a number one larger or
              smaller to actually get the size you want.  You may also
              be able to use the software that came with your  scanner
              to  convert images from 8 bpp (256 palette mode color or
              gray) to  1  bpp  "Line  Art"  for  conversion  into  my
              programs.  You may also be able to use the software that
              came  with your scanner to convert files saved as 1 bpp,
              8 bpp, or 24 bpp BMP from my programs into 24 bpp JPG or
              GIF for  other  applications  such  as  display  on  the
              internet.

              See also the [F]iles [L]oad [I]ndustry [B]MP and [F]iles
              [L]oad [I]ndustry  [B]MP  menu  commands,  and  use  the
              automatic  output  macro feature to code the loading and
              saving of "Line Art" BMP type files.  See also the  LOAD
              BMP  and  SAVE  BMP  commands to work with color or gray
              scale images.  See also JET TRACE and LOAD ASCII to  get
              the  scanned image into the drawing workspace.  See also
              the UTILITY BMP256_TO_ASCII macro  command  for  various
              conversion  modes  of BMP 8 bpp files into ASCII drawing
              files.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

COPY

PURPOSE:      To make a copy of an element in the workspace.  The copy
              of the selected element will become the highest  element
              number  and be a separate new element.  The copy is made
              of the currently selected element,  and so COPY must  be
              used with the #, select element, macro command.

MAIN MENU:    [D] [?...] [E] [C]

KEYWORD:      COPY

PARAMETERS:   None (Uses selected element as source.)

TYPE:         NA

FORMAT:       COPY

EXAMPLE:      INIT
              LOAD 3D CUBE.3D
              # 1 COPY           ; # 2 is a copy of CUBE.3D.
              # 2 OFFSET C -2 0 0
              ; See also FILES COPY f f command to copy disk files.

              ; Start COPYLAST.SUB
              LET |LAST -> ELEMENTS
              # |LAST COPY
              RELEASE |LAST
              ; End COPYLAST.SUB


HINT:         After  using  the  COPY  command  you  can  use the JOIN
              command  to  group  the copied elements into a mass that
              can be manipulated as a whole.

NOTE:         The copied element will occupy the same position in  the
              drawing workspace as the source element unless  you  use
              the  OFFSET  command  to  move  the  copy  to some other
              position.  The copied element has its center  point  set
              to  the  same  value  as  the  center point value of the
              source element when the copy is made.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CORRECT

PURPOSE:      To correct or adjust the normal or triangle so that  the
              hidden line display modes will show the  right  side  of
              the triangles,  and to check for some errors in elements
              with or without triangles.  See also  the  REVERT  macro
              command  since  triangles drawn backwards sometimes need
              that command to make needed changes.  Revised in v2.7F.

MAIN MENU:    [D] [?...] [H] [C]

KEYWORD:      CORRECT

PARAMETERS:   1 for G T N L modes, 2 for modes V, S, and F

TYPE:         w......... mode = G, generate normals using triangle direction.
                                T, correct triangle direction match normals.
                                N, correct normals to match triangle direction.
                                L, generate normal only for last triangle in element.
                                V, verify element's lines or triangles mode.
                                S, set normal length in selected element.
                                F, filter element to be only "good" triangles or lines.

              w......... V option only = T, verify triangles in element.
                                         L, verify "free" lines in element.
                                         A, set verify mode to scan all
                                         lines or triangles in element.
                                         Q, set verify mode to quick scan of first
                                         and last lines or triangles in element.

              r......... S option only = normal length for selected element.

              w......... F option only =  L, filters out dots and triangles,
                                             keeps free lines.
                                          T, filters out lines and "bad" triangles,
                                             keeps "good" triangles.

FORMAT:       CORRECT w  or  CORRECT V w  or CORRECT S r or CORRECT F w

EXAMPLE:      # 1 CORRECT G
              # 2 CORRECT T
              # 3 CORRECT N
              # 4 CORRECT L
              # 1 CORRECT V T
              # 2 CORRECT V L
              # 3 CORRECT V A
              # 4 CORRECT V Q
              # 1 CORRECT S 0.5
              # 1 CORRECT F L ; filter to keep free lines
              # 2 CORRECT F T ; filter to keep good triangles

NOTE:         The  #  n  before  CORRECT  below is the  select element
              command, to select the element to act on, or scan.

              The CORRECT command has several  modes  that  relate  to
              various issues involving elements made of triangles.  If
              you  create  triangle  data  directly  using the [W]rite
              command or by some other method figuring out the correct
              coordinates for the p4  values,  i.e.  normals,  can  be
              ignored, and then later you can use the CORRECT option G
              to generate new normals.

              CORRECT modes T and N are only used when the normals and
              the  triangles  directions  are  independently reversed,
              something that does  not  normally  happen  in  elements
              drawn properly, but can be corrected with these options.
              When  both the triangles and normals are going the wrong
              way use the REVERT command to correct that problem.

              CORRECT mode L generates a normal just for the last  two
              line  segments in the selected element,  and is used for
              appending line data by the program,  normally you  would
              use mode G to correct the whole element.

              # n CORRECT G { generate normals using triangle direction }
              # n CORRECT T { correct triangle direction match normals }
              # n CORRECT N { correct normals to match triangle direction }
              # n CORRECT L { generate normal only for last triangle in element }

              CORRECT  can  also be used to check an element to see if
              the triangle data has been corrupted,  or if a  triangle
              accidentally  got  integrated into a line element.  Some
              problems may not show up on the Verify,  but  it  should
              catch  some  of  the  major  problems  if the Verify All
              option is active.  The Verify Quick mode lets you  speed
              up the program if you are sure that all the elements are
              made  of  good triangles.  Normally the program uses the
              Verify before some of the other  commands  that  require
              good  triangle  or  line  data  in  order  to screen out
              elements that are not  valid  for  that  command,  so  I
              recommend  leaving  Verify  set to the All mode to catch
              the greater number of mistakes.

              # n CORRECT V T  { verify triangles in element }
              # n CORRECT V L  { verify "free" lines in element }
              # n CORRECT V A  { set verify mode to scan all
                                 lines or triangles in element }
              # n CORRECT V Q  { set verify mode to quick scan of first
                                 and last lines or triangles in element }

              In  the  drawing  editor and preview or DISPLAY commands
              you can display the triangle normals as  lines  "poking"
              out of your triangle elements,  so that you can visually
              confirm that the triangles have  been  drawn  correctly.
              The  generated  length of the normal relates to the size
              of the triangle,  so small triangles get small  normals,
              big  triangles  get big normals.  If you have a curve or
              other shape with short line segments the default  length
              of the normals might be too short to see which direction
              they  are  going in when you are zoomed out,  so you can
              use the CORRECT S option to Set the normal length  to  a
              longer  particular  value  to  make  the  display of the
              normals direction more obvious.

              # n CORRECT S r  { set normal length in selected element }

              The "r" is a positive real number for the length of  the
              normals in the selected element.

              # n CORRECT F L { filter lines mode }
              # n CORRECT F T { filter triangles mode }

              The "F" stands for Filter mode,  the "L" stands for Line
              mode,  and  the  "T"  stands for triangle mode.  The "L"
              filter is used internally by the program to "prep"  line
              elements  before  some of the commands that convert line
              elements into triangles,  so as to remove line  segments
              that  are very short or have no length,  since it is not
              allowed that the resulting triangles made  from  a  line
              source  element  would  have no length on one side.  The
              "T" filter is used to  remove  triangles  that  have  no
              length  on  one  side,  and might also be able to remove
              free lines from a triangle element.  If a free  line  is
              stuck  between  the first and second lines in a triangle
              the free line and the first  and  second  lines  of  the
              corrupted  triangle  will probably get deleted since the
              program has no way of associating parts  of  a  triangle
              that  are  not  made of consecutive line segments in the
              workspace.  Since  both  filters  delete  line  segments
              these  commands  tend  to  work  faster when the element
              being filtered is the element with the  highest  element
              number,  rather  than an element somewhere in the middle
              because when an line segment gets  deleted  all  of  the
              line  segments  with  a  higher  line  number need to be
              shuffled down by one line number,  so  the  fewer  lines
              above the one getting deleted the better.  These filters
              are  also accessible through the drawing editor's Hidden
              Correct command.

HINT:         See also the REVERT macro command.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CRT

PURPOSE:      The CRT command has been  added  to  allow  some  direct
              operations on the Video CRT without  having  to  display
              elements  stored  in  the drawing workspace.  Revised in
              v2.7G.

MAIN MENU:    [F] [U] [V] [N]  or  [F] [U] [V] [B]

KEYWORD:      CRT

PARAMETERS:   6 for modes LINE, BOX, RECTANGLE
              5 for mode BACKGROUND
              2 for mode NEGATIVE

TYPE:         For modes LINE, BOX, RECTANGLE:

              w......... mode, LINE makes a line on the screen.
                               BOX makes a filled rectangle.
                               RECTANGLE makes a rectangle.
              r......... x1 point for drawing to screen r = 0 to x_pixels-1.
              r......... y1 point for drawing to screen r = 0 to y_pixels-1.
              r......... x2 point for drawing to screen r = 0 to x_pixels-1.
              r......... y2 point for drawing to screen r = 0 to y_pixels-1.
              i......... color for drawing to screen, 0 to 15.

              For BACKGROUND mode:

              w......... mode BACKGROUND.
              i......... background pattern mode code number.
              r......... brightness value, 1.0 normally.
              i......... color one 0 to 15.
              i......... color two 0 to 15, can be same as color one.

              For NEGATIVE mode:

              w......... mode NEGATIVE.
              i......... negative modes:
                         In all video modes:
                         1 = negative colors or inverse tones.

                         Just in VESA 15, 16, 24, and 32 bpp modes:
                         101 = red negative separation,
                         102 = green negative separation,
                         103 = blue negative separation,
                         104 = red positive separation,
                         105 = green positive separation,
                         106 = blue positive separation,
                         107 = monochrome negative of the luma, i.e. W =
                               0.3R+0.59G+0.11B.
                         108 = monochrome positive of the luma.

FORMAT:       CRT w r r r r i  { for LINE, BOX, RECTANGLE modes }
              CRT w i i i      { for BACKGROUND mode }
              CRT w i          { for NEGATIVE mode }

EXAMPLE:      CRT LINE 0 0 639 479 14
              CRT BOX 0 0 639 479 6
              CRT RECTANGLE 100 50 200 250 3
              CRT BACKGROUND 41 1.0 1 2
              CRT NEGATIVE 1
              CRT NEGATIVE 108 ; only in VESA 15, 16, 24, or 32 bpp modes.

NOTE:         In LINE BOX and RECTANGLE the x  and  y  values  are  in
              absolute screen coordinates, and change depending on the
              video mode selected.  If you  want  to  use  coordinates
              independent  of  the  video  mode,  you  should  use the
              DISPLAY command on lines drawn  in  an  element  in  the
              workspace.

              Mode codes for CRT BACKGROUND are:

               0 solid color of brightness set, can be two colors mixed or two same solid.

              21 light at center, dark at top and bottom, colors mixed.
              22 light at center, dark at left and right, colors mixed.

              31 dark at center, light at top and bottom, colors mixed.
              32 dark at center, light at left and right, colors mixed.

              41 light at center, dark at top and bottom, color one top, color two bottom.
              42 light at center, dark at left and right, color one left, color two right.

              51 dark at center, light at top and bottom, color one top, color two bottom.
              52 dark at center, light at left and right, color one left, color two right.

              61 color one at center, color two at top and bottom.
              62 color one at center, color two at left and right.

              You  can  save  the   background   using   the   [F]iles
              [U]tilities  [V]ideo  [B]ackground  command,  or use the
              SAVE PIXEL command after the CRT BACKGROUND command in a
              macro.  Be sure to use the CRT BACKGROUND command  AFTER
              the GRAPH video_mode command, and not before setting the
              video graphic mode.  Solid background colors can also be
              set  with  the macro command PALETTE setting for entry 0
              since 0 is the default background color  in  modes  that
              support  colors or gray tones.  In graphics mode F0B24 a
              24 bit BMP file is made in place of the display  of  the
              background  on  the screen.  Also in graphics mode F0B24
              the Z-Buffer setup variables need to be  saved  to  disk
              before the graphics mode is set to F0B24, such as:

              LET  B24OVER_.VAR = 2          ; oversample value
              LET  B24UNDER.VAR = 1          ; undersample value
              LET  B24XPIX_.VAR = 200        ; x pixels value
              LET  B24YPIX_.VAR = 150        ; y pixels value
              LET  B24DITHE.VAR = 4          ; tone dithering value
              LET$ B24BACK_.VAR = ""         ; no background when making one
              LET$ B24NAME_.VAR = "NAME.BMP" ; name for 24 bit BMP file
              GRAPH_MODE BMP                 ; set video mode
              CRT BACKGROUND 21 1 2 4        ; make background file
              TEXT                           ; reset video to text

              When making a background file for use with the VESA  15,
              16,  24,  or 32 bpp video modes you should use the video
              mode BMP, with CRT BACKGROUND,  and not the VESA,  SEEK,
              or  LIST video modes with GRAPH,  since BMP mode saves a
              BMP file,  and the VESA modes save  a  PIXEL  file.  The
              DISPLAY  command  needs a BMP file for the background in
              VESA 15, 16, 24, and 32 bpp modes,  not a Pixel file.  A
              VESA 15, 16, 24, or 32 bpp Pixel file might be converted
              into a BMP file, for use as a background image, by using
              the   LOAD  PIXEL  command  followed  by  the  SAVE  BMP
              command.  It is best to use the BMP video mode or one of
              the 24  bpp  or  32  bpp  VESA  modes  when  saving  the
              background  image  since when the image is loaded the 24
              bpp image data may give better results than  having  had
              the  image  converted from 15 bpp or 16 bpp before being
              saved to the 24 bpp BMP file.

              GRAPH_MODE SEEK 0 640 480 24   ; set 24 bpp video mode
              CRT BACKGROUND 21 1 2 4        ; make background file
              SAVE PIXEL BACKFILE.PIX        ; save as pixel image
              SAVE BMP 24 BACKFILE.BMP       ; save BMP background image
              TEXT                           ; reset video to text

              CRT NEGATIVE makes the  graphics  screen into a negative
              image.  In  M256  and  C256  palette modes NEGATIVE only
              changes the video palette and not the pixel  values,  so
              SAVE  PIXEL will only save the original pixel values and
              not the negative ones.  You can use CRT  NEGATIVE  after
              LOAD  PIXEL  to  change  the loaded file into a negative
              image for photography on Color or B&W  "positive"  film.
              When  photographing in negative the camera's view should
              crop the screen image to avoid a  clear  border  on  the
              positive  after  processing.  Be  sure to use correcting
              filters over the camera,  yellow  or  orange  types  for
              color positive, in order to get gray to come out gray in
              the  positive.   Adjust  the  monitor  brightness,   and
              exposure time to get the right  center  density,  rather
              than  using  the  program's  display  command's lighting
              variables.

              TEXT
              LOAD PIXEL SOMEFILE.PIX
              CRT NEGATIVE 1
              SAVE PIXEL SOMEFILE.PIX
              TEXT

              The CRT NEGATIVE command was expanded to work  with  the
              15, 16, 24, and 32 bpp Pixel files.  CRT NEGATIVE mode 1
              makes  a  color  negative  image  that  can  be saved to
              another Pixel file since the color data is  absolute  in
              these  video  modes,  unlike  the 8 bpp video modes that
              depend on a palette to define the color of  the  pixels.
              Some additional processing modes have been added for the
              15, 16, 24, and 32 bpp Pixel files, mode 101 makes a red
              negative  separation,   102  makes  a   green   negative
              separation,  103  makes a blue negative separation,  104
              makes a red  positive  separation,  105  makes  a  green
              positive   separation,   106   makes   a  blue  positive
              separation, 107 makes a monochrome negative of the luma,
              i.e.  W = 0.3R+0.59G+0.11B,  and 108 makes a  monochrome
              positive  of the luma.  The separations can be used in a
              pin registered optical or contact printer to make  color
              release  prints,  perhaps  without  some  of  the  color
              saturation loss that might come  from  printing  from  a
              color negative.

HINT:         See  also  the  menu  command  Files   Utilities   Video
              Negative.  See also the GRAPH, DISPLAY,  APPEND,  ENTER,
              SAVE  PIXEL,   LOAD  PIXEL,   TEXT,  and  ANIMATE  macro
              commands.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CURVE_FIT

PURPOSE:      To make a new element from the selected element that  is
              a smooth curved line through the selected elements  line
              segment's  end  points.  The selected element to fit the
              curve to should contain  one  or  more  series  of  line
              segments  drawn  such  that  the  end point of the first
              segment is the same as the start  point  of  the  second
              segment   and   so   on.   The   CURVE_FIT  command  was
              substantially  changed  in  v2.7A,   careful  read   the
              information  below.  Macros  written for versions before
              v2.7A that used the CURVE_FIT command will  need  to  be
              edited and revised

MAIN MENU:    [D] [?...] [3] [F]

KEYWORD:      CURVE_FIT

PARAMETERS:   4 (for mode O i.e. One chain source element)
              5 (for mode S i.e. Set of elements for chains source)
              6 (for mode P i.e. Partition chains from one source element)

TYPE:         For mode O:

              w......... source_mode, O = Mode "O" is for curve fit of
                                          just One single chain element.

              w......... erase_source = Y, Yes will erase the
                                           source element set.
                                        N, No will leave it in
                                           the workspace.

              i......... Iteration, 1 to 9, try 3 or 4.
                         (The number of lines in the element "double"
                         with each iteration i.e. n = (n*2)-1.)

              r......... Damping, 0 to 1E18, 0.2 is normal.
                         (The  higher  the  damping  the shallower the
                         curve that will be made.)

              For mode S:

              w......... source_mode, S = Mode "S" for curve fit a set
                                          of chain elements numbered
                                          starting with the element selected
                                          with the # command.

              w......... join_mode = Y, yes will make just one
                                        new element.
                                     N, no will make a set of
                                        chain elements.

              w......... erase_source = Y, Yes will erase the
                                           source element set.
                                        N, No will leave it in
                                           the workspace.

              i......... Iteration, 1 to 9, try 3 or 4.
                         (The number of lines in the element "double"
                         with each iteration i.e. n = (n*2)-1.)

              r......... Damping, 0 to 1E18, 0.2 is normal.
                         (The  higher  the  damping  the shallower the
                         curve that will be made.)

              For mode P:

              w......... source_mode, P =  Mode "P" for curve fit a set
                                           of chain elements to partition
                                           from the single selected
                                           element.

              w......... join_mode = Y, yes will make just one
                                        new element.
                                     N, no will make a set of
                                        chain elements.

              w......... erase_source = Y, Yes will erase the
                                           source element set.
                                        N, No will leave it in
                                           the workspace.

              i......... Iteration, 1 to 9, try 3 or 4.
                         (The number of lines in the element "double"
                         with each iteration i.e. n = (n*2)-1.)

              r......... Damping, 0 to 1E18, 0.2 is normal.
                         (The  higher  the  damping  the shallower the
                         curve that will be made.)

              r......... Tolerance, is for the partition part of
                         this mode so that the program can tolerate
                         small gaps when finding the ends  of  the
                         chains  of  line segments in the source
                         element.

FORMAT:       CURVE_FIT O w i r
              CURVE_FIT S w w i r
              CURVE_FIT P w w i r r

EXAMPLE:      # 1 CURVE_FIT O Y 3 0.2
              # 2 CURVE_FIT S Y Y 4 0.2
              # 3 CURVE_FIT P Y Y 5 0.2 0.1

              SAVE ELEMENTS IN.3DE ; Save elements to curve fit.
              FILES CONVERT ELEMENTS IN.3DE ASCII OUTASC
              NAME 1 = OUTASC 0
              LET |ECOUNT -> COUNT NAME 1 HERE
              :LABEL
              INIT
              LOAD ASCII NAME 1 NEXT
              # 1 CURVE_FIT O Y 3 0.2
              # 1 SAVE ASCII NAME 1 HERE
              LOOP :LABEL  [ |ECOUNT - 1 ]
              FILES CONVERT ASCII NAME 1 HERE ELEMENTS OUT.3DE
              INIT
              LOAD ELEMENTS OUT.3DE ; Load curve fitted elements.

NOTE:         The  selected  element  to  fit the curve to cannot have
              more  than  one  third the number of lines that will fit
              into the drawing workspace since  the  number  of  lines
              used  will  "double"  with each iteration and the source
              element can remain in the workspace.  The source element
              must have at least two lines (three different points.)

              Some new modes were added to the  CURVE_FIT  command  in
              v2.7A,  these  related  to  elements made of chains like
              those chains used with the WEAVE command.

              Note that the number  of  elements  in  the  result  set
              cannot  be  grater  than  the maximum number of elements
              that the workspace can hold at one time.  Also note that
              the last element in the workspace when  the  command  is
              selected  must  be one of the elements in the source set
              since the set extends from the selected element  to  the
              last element in the workspace,  however many that number
              of elements is at the time.

              In mode  O  the  element  selected  with  #  before  the
              CURVE_FIT  command  is  an  element  containing a single
              chain of line segments, like in v2.6 and prior.

              In mode  S  the  element  selected  with  #  before  the
              CURVE_FIT  command  is  an  element  containing a single
              chain  of  line  segments,   but  the  elements  in  the
              workspace  with  numbers above the selected element must
              all also contain a single chain of  line  segments  that
              have the same number of line segments.  For example,  if
              element # 8 is selected and it has 15 line segments, and
              there are 12 elements total,  then elements # 10,  # 11,
              and  #  12  must  also  have 15 line segments.  In other
              words the selected element is the first element in a set
              of elements that are all in the workspace, with the last
              element in  the  set  being  the  last  element  in  the
              workspace.

              In  mode  P  the  element  selected  with  #  before the
              CURVE_FIT command is an element  that  contains  several
              chains  joined  into  a single element that all have the
              same number of line segments, the CURVE_FIT command will
              use the tolerance value given to  partition  the  chains
              from  the  selected  element  so  that  each  one can be
              CURVE_FIT.

              Chains are groups of line segments drawn end to end  one
              after another such that the last point of the first line
              is  the  first  point of the second line and so on.  The
              end of the chain is  considered  where  the  next  first
              point  is apart from the last point of the previous line
              by more than the partitioning tolerance,  i.e.  where  a
              gap  is  found.  So  gaps  must  all come after the same
              number of line  segments  in  the  chains.  All  of  the
              chains  should  go  in  the  same  general  "direction,"
              particularly if WEAVE or BETWEENS are going to  also  be
              used.

HINT:         If you want to use the BETWEENS macro command to make an
              animated  sequence  and  CURVE_FIT the elements as well,
              use  the  BETWEENS  command  first  since  in  that  way
              BETWEENS  will have fewer vectors to interpolate.  Since
              the CURVE_FIT command works in all three dimensions  you
              can  use  CURVE_FIT  to  make  a  helix  or other spring
              shapes.  See also the  BETWEENS  macro  command  to  fit
              shapes  in  the dimension of time,  or space.  The macro
              EXPAND command works like the CURVE_FIT  command  except
              that variables values are fit rather than points of line
              segments in the workspace.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

CYCLIZE

PURPOSE:      To load a drawing symbol or tool cycle at points  marked
              by lines drawn in another element.  It is a way to speed
              up  some  kinds of drawing where the same drawing symbol
              or tool cycle is to be loaded at points several times in
              a pattern or marked array.  In the drawing  editor  this
              is  the  [D]ot  cyclize command in the [N]C sub-menu.  A
              "dot" drawn in the workspace is actually a line with the
              first and second points at the same place,  CYCLIZE will
              work with dots or lines,  the mode is to pick the start,
              middle, or end of a line to use as the "dot" point where
              the "cycle" file will be loaded.  New for v2.7A.

MAIN MENU:    [D] [?...] [N] [D]

KEYWORD:      CYCLIZE

PARAMETERS:   5

TYPE:         i........ mode: 1=first point of lines in selected element.
                              2=second point of lines in selected element.
                              3=mid-point of lines in selected element.
              r........ x_tool_offset = load position adjustment i.e. 0.
              r........ y_tool_offset = load position adjustment i.e. 0.
              r........ z_tool_offset = load position adjustment i.e. 0.
              f........ cycle_file_name = name of ASCII element file to
                                          load at points from selected element.

FORMAT:       CYCLIZE i r r r f

EXAMPLE:      # 1 CYCLIZE 1 0 0 0 MYCYCLE.ASC
              # 2 CYCLIZE 2 0 -0.1875 0 SYMBOL.ASC
              # 3 CYCLIZE 3 -1.0 3.333 0.005 C12345.ASC

NOTE:         The CYCLIZE command is mostly for simplifying the making
              of tool paths,  but could have some other drawing  uses.
              The  CYCLIZE  command  loads  an  element from a file at
              points on lines in another element,  for instance if you
              draw  a  square  and then CYCLIZE it with a drawing of a
              bolt head you will get four bold  heads  arranged  in  a
              square.  The  mode  lets  you  pick the points where the
              file element will load,  i.e.  the first point  of  each
              line in the selected element, the last point, or a point
              at  mid-point  between the first and last points of each
              line.  The tool offsets would normally be 0,  but can be
              used  to  adjust  the load point of the tool cycle being
              loaded to compensate for tool length and  such.  If  the
              source  element is made of dots the mode will not change
              the result much.

              The number of times that the  "cycle"  element  will  be
              loaded  depends  on  the  number of line segments in the
              source element selected for CYCLIZE to use a a template.
              The order of placement that the "cycle" elements will be
              entered into the workspace  depends  on  the  order  the
              lines  where  drawn in the elements selected for CYCLIZE
              to follow.  Be sure to  select  the  source  element  to
              follow before the CYCLIZE command in your macro by using
              the # symbol.

HINT:         CYCLIZE  can  be used to load a drilling tool path cycle
              that  was  saved in a file at points on the corners of a
              polygon,  i.e.  a hexagon and be used as a  template  to
              make  a  drill cycle for a bolt hole circle on a flange,
              and such.  See also the DRILL_POINTS macro command.

Click here to go to the Macro Keywords A to Z list.
Click here for more information about Appendix B.
Click here for more information about Appendix C: Macro Math and Strings.
Click here for more information about Writing macro code.
Click here to go back to the top of this page.

TERMS OF USE, HOME, INDEX, SHORTCUT, WHAT'S NEW, DOWNLOADS, GET MAIN ZIP, DOCUMENTATION, VIDEO, HOOKUP#1, #2, #3, KEYWORDS

WWW.DANCAD3D.COM (sm): THE OFFICIAL DANCAD3D (tm) "BETA TEST" WEB SITE.

This copy of this page was compiled on or around: Y2009.M01.D14, you might check the "On-Line" version, or come back later, to see if there is a newer compile.