home *** CD-ROM | disk | FTP | other *** search
/ Fish 'n' More 1 / FishNMoreVol1.bin / more / graphics / applications / qrtv1.5 / docs / addend15.doc < prev    next >
Text File  |  1989-03-18  |  9KB  |  265 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.         
  8.         
  9.         
  10.                            Addendum to QRT Version 1.5
  11.         
  12.         
  13.         
  14.         The following are changes to QRT made since version 1.4
  15.         
  16.         
  17.         Additions and Enhancements
  18.         
  19.            Non-Hardcoded Resolution and Aspect Ratio
  20.            
  21.                This release of QRT has  additional  support for non-Amiga
  22.                platforms.  The QRT input  language  has  been extended to
  23.                allow the x  and  y  resolution  and  aspect  ratio  to be
  24.                changed.   The   additional   keywords  are  part  of  the
  25.                DEFAULT() command, as in this example:
  26.                
  27.                     DEFAULT (
  28.                          x_res  = 1280,  { ** BIG image ** }
  29.                          y_res  = 1024,
  30.                          aspect = .89
  31.                     );
  32.                
  33.                
  34.                QRT can generate images  in  any  practical  resolution (I
  35.                have tested it up to 1280  x  1024;  the  current limit is
  36.                2500  x  anything)  but  the   image  generation  time  is
  37.                proportional to the image size.   The aspect ratio for any
  38.                monitor can be determined as follows:
  39.                
  40.                     aspect ratio = (XR/XD)/(YR/YD)
  41.                
  42.                where:
  43.                
  44.                     XR = X resolution of monitor
  45.                     XD = width of monitor in arbitrary units
  46.                
  47.                     YR = Y resolution of monitor
  48.                     YD = height length of monitor in arbitrary units
  49.                
  50.                There  are  #ifdefs  in  the  code  which  should  provide
  51.                reasonable defaults for UNIX  and  AMIGA machines.  Images
  52.                can now be generated quickly in  low resolutions, and once
  53.                the desired image is found,  it  can be generated the full
  54.                displayable resolution.
  55.                
  56.  
  57.  
  58.  
  59.  
  60.         QRT Ray Tracer               Page 1               Addendum to 1.5
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72.  
  73.            Command Line Arguments
  74.                
  75.                QRT  now  accepts  optional  command  line  arguments,  as
  76.                follows:
  77.                
  78.                     -xres   integer
  79.                     -yres   integer
  80.                     -aspect float
  81.                     -foclen float
  82.                
  83.                For example,  the  following  line  would  run  QRT in the
  84.                background with a resolution of 127 x 127:
  85.                
  86.                     run qrt <file.QRT >file.OUT -xres 127 -yres 127
  87.                
  88.                or, in UN*X,
  89.                
  90.                     qrt <file.QRT >file.OUT -xres 127 -yres 127 &
  91.                
  92.                These options are very  useful  for generating preliminary
  93.                images in a low resolution without changing the .QRT input
  94.                file.  Since it is possible to set these parameters from 3
  95.                places, QRT places them in order of increasing priority as
  96.                follows:
  97.                
  98.                     Built-in Defaults
  99.                     Parameters in .QRT file
  100.                     Command Line Arguments
  101.                
  102.                Thus, any command line  arguments  present  will supersede
  103.                parameters coded into the .QRT file, and parameters in the
  104.                QRT file, if present,  will  supersede  the  built  in QRT
  105.                defaults.
  106.                
  107.                
  108.            Bug Fixes
  109.                
  110.                Version 1.5 of QRT fixes these bugs:
  111.                
  112.                    1) Lexer malloc() bug -  the  lexer was not allocating
  113.                       enough memory for  some  symbols,  causing  QRT  to
  114.                       crash upon reading  certain  input files.  This has
  115.                       been fixed.
  116.                    
  117.                    2) toupper()  compatibility  bug  - apparently not all
  118.                       compilers treat  toupper()  the  same - some change
  119.                       only lower case letters,  as  seems  logical, while
  120.                       others change all characters.   This function is no
  121.                       longer used in QRT to decrease porting effort.
  122.                    
  123.                    3) Due to  a  really  stupid  error  on  my  part, the
  124.  
  125.  
  126.         QRT Ray Tracer               Page 2               Addendum to 1.5
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.                       DiffColor()  was  executing  a  pow() function call
  140.                       every time  though,  whether  it  needed to or not.
  141.                       Since this  pow()  function  is  slow, QRT now runs
  142.                       noticeably  faster  than  it  used  to.   I haven't
  143.                       quantified the results,  but  it seems to be around
  144.                       20 to 30 percent.  The  increase  in  speed will be
  145.                       most noticeable on machines  with no floating point
  146.                       co-processor.
  147.                    
  148.                    4) The  TRIANGLE()  command  now  works  correctly for
  149.                       non-right  triangles.   The  bug  fix for this also
  150.                       fixed a bug with non - rectangular parallelograms.
  151.                    
  152.                    5) Focal length is no longer resolution dependent.
  153.                    
  154.                    6) CINFO structures are now  always initialized before
  155.                       they are copied.  This  bug  fix  was sent to me by
  156.                       Paul Bayloz.
  157.                    
  158.                    
  159.            Enhancements
  160.                
  161.                Additional information about the  image is now sent to the
  162.                standard output.  Image X  and  Y  size, aspect ratio, and
  163.                focal length are printed.
  164.                
  165.                I have finally revisited the original  documentation files
  166.                to include some of  the  information  from  the addendums.
  167.                This will make it easier for new users of QRT to learn the
  168.                system.  I fixed a bunch of spelling errors, too.
  169.                
  170.                Tabs are now counted as  white  space; they will no longer
  171.                cause QRT to report an error message.
  172.                
  173.                
  174.            Deletions
  175.                
  176.                The  FIRST_SCAN  and   LAST_SCAN   parameters   have  been
  177.                obsoleted by the addition of the X_RES and Y_RES commands.
  178.                These  arguments   are   still   accepted   for   backward
  179.                compatibility of old QRT files, but they are ignored.
  180.                
  181.                In addition, since QRT has recently  seen a wider audience
  182.                in  the  non-Amiga   community,  I  have  removed  several
  183.                paragraphs  from  Addendum  1.4  which  were  strictly  my
  184.                personal opinions of some  other  computer  systems.  They
  185.                might have been OK for  the  Amiga  community,  but seemed
  186.                less than appropriate for wider circulation.
  187.                
  188.  
  189.  
  190.  
  191.  
  192.         QRT Ray Tracer               Page 3               Addendum to 1.5
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.  
  203.  
  204.  
  205.         Notes, etc.
  206.            
  207.            QRT has now been Un*xized -  it  will  compile correctly under
  208.            AmigaDos or UN*X.  I  have  added  #define's  for  most common
  209.            machine types at the beginning of  qrt.h, so these can be used
  210.            to add  machine  specific  necessary  compiler  stuff  for new
  211.            machines.
  212.            
  213.            I have compiled  QRT  on  an  HP  9000/835  (proprietary  RISC
  214.            architecture), and it *hauls*.    It will run all the supplied
  215.            demos in less than 3 and  a  half  minutes  at a resolution of
  216.            320x400, and some of the simpler ones, such as Wall_Sphere.QRT
  217.            in less than one and a  half  minutes!   I  may try to compile
  218.            benchmark times for QRT on  various  platforms  using standard
  219.            demos and standard  resolutions.   If anyone has any benchmark
  220.            times, I'd like to hear about them.
  221.            
  222.            I have supplied source code  for  a  QRT RAW to GIF converter,
  223.            written by David Rowley.  This  will  eliminate the problem of
  224.            finding a post processor for anyone  who has the capability of
  225.            displaying GIF images (this  should  be nearly everyone).  The
  226.            program, called QRT2GIF, seems  to  work well, except for very
  227.            large image sizes where it cannot  malloc() enough memory.  It
  228.            claims to write a temporary  file,  but  the final GIF file is
  229.            corrupt.  It is also limited to 256 colors.  I have used it up
  230.            to resolutions of 768 by 640, however,  with no trouble.  It's
  231.            a very useful tool.  Thanks, Dave!
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.         QRT Ray Tracer               Page 4               Addendum to 1.5
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.