home *** CD-ROM | disk | FTP | other *** search
/ Amiga MA Magazine 1998 #6 / amigamamagazinepolishissue1998.iso / coders / example_c_dt / readme next >
Text File  |  1997-06-29  |  7KB  |  170 lines

  1.  
  2.   samplePNM.datatype and source-code V43.9 (29.6.97)
  3.   (C) 1996-97 by Andreas R. Kleinert. All rights reserved.
  4.  
  5.   ---
  6.   This small sample datatype source code demonstrates, how to completely
  7.   write an Amiga OS 3 datatype (V40/V43) without any assembler stubs
  8.   or compiler/linker tricks in PURE C source code (currently SAS/C-based:
  9.   see Aminet:dev/c/CLib37x.LHA on how to adjust for some other compilers).
  10.  
  11.   You may e.g. use this example source code to write more portable
  12.   Amiga OS 3 datatypes to allow easier porting of these
  13.   to other Amiga OS-derived operating systems, or the native
  14.   OS of an upcoming PowerPC Amiga.
  15.  
  16.   Translate your 68k-assembler datatype startup-codes smartly
  17.   to C by simply using this source-code as an advice how to do it.
  18.  
  19.  
  20.   As a common case, a datatype of class picture, supporting
  21.   PNM-PGM (P5) and PNM-PPM (P6) has been used as an example.
  22.  
  23.   With picture.datatype V40-42 only PGM is supported,
  24.   and with picture.datatype V43 reading of PPM is offered as well,
  25.   while encountering an PGM file under V43 causes a fallback to V40
  26.   routines (could have been done differently, but was not necessary
  27.   here just for demonstration).
  28.  
  29.   For testing this datatype, simply use a tool from the NetPBM package
  30.   (or maybe for example a tool supporting superview.library) and save
  31.   a graphics in the binary PGM or PPM format (P5/P6 of the PNM series).
  32.  
  33.   Then install this datatype and try loading the file via MultiView.
  34.   Should work fine.
  35.  
  36.   ---
  37.   Feel free to use this source for own projects.
  38.  
  39.   It is allowed to be spread and distributed anywhere, as far
  40.   as my consent is concerned.
  41.  
  42.   Amiga Technologies, or the current owner of the technologie,
  43.   is allowed to always put this source on their newest
  44.   Developer CD-ROM.
  45.  
  46.   Thanks and credits will always be appreciated - for example,
  47.   you MAY, but NEED NOT:
  48.   give me credits in your program's docs, send me keyfiles for
  49.   your programs using the library, and so on.
  50.   But that's simply voluntarily.
  51.  
  52.   This work was only roughly inspired by David Junod's original
  53.   example source codes for datatypes.
  54.  
  55.    _________________________________________________________
  56.   |      You may reach me the following way.                |
  57.   |    Send bug-reports, money or whatever to:              |
  58.   |---------------------------------------------------------|
  59.   |        * SuperView Development & Registration *         |
  60.   |          * DRAFU Development & Registration *           |
  61.   |       * Image Engineer Registration Site Europe *       |
  62.   |                                                         |
  63.   |                                                         |
  64.   |                  PerSuaSiVe SoftWorX                    |
  65.   |                                                         |
  66.   |                  Andreas R. Kleinert                    |
  67.   |                  Sandstrasse 1                          |
  68.   |                  D-57072 Siegen                         |
  69.   |                  Germany, Europe                        |
  70.   |                                                         |
  71.   | Any snail mail to the old address will still be routed. |
  72.   |                                                         |
  73.   |                  Phone:  +49-271-22869 also FAX + AM    |
  74.   |                          +49-271-22838                  |
  75.   |                                                         |
  76.   |                  Weekdays after 17.00h.                 |
  77.   |                                                         |
  78.   |         When calling via phone you may leave a message, |
  79.   |         if I'm not available - but don't expect me      |
  80.   |         calling back to USA, Australia, ... since       |
  81.   |         german phone rates are HIGHLY expensive.        |
  82.   |_________________________________________________________|
  83.  
  84.     http://home.t-online.de/home/Andreas_Kleinert/
  85.  
  86.   eMail:
  87.  
  88.         Please send binaries via ARK@News.wwbnet.de, and keep
  89.         them smaller than 16 KB. Please think twice before
  90.         sending them - my postbox is not unlimited in size.
  91.  
  92.            - Fido    Andreas Kleinert 2:2457/350.18
  93.            - Usenet
  94.                      Andreas_Kleinert@superview.ftn.neckar-alb.de (Fido-Gate)
  95.                      Andreas_Kleinert@t-online.de                 (T-Online)
  96.                      ARK@News.wwbnet.de                           (Z-Netz)
  97.                      ARK@amigaworld.com                           (AmigaWorld)
  98.  
  99.            - If nothing else works, try one of these public
  100.              Fido-Usenet gateways:
  101.  
  102.                In Germany:
  103.                  Andreas_Kleinert@p18.f350.n2457.z2.fido.sub.org
  104.  
  105.                From USA or elsewhere:
  106.                  Andreas_Kleinert@p18.f350.n2457.z2.fidonet.org
  107.  
  108.         Please note, that the "superview.ftn.sub.org"
  109.         domain will perhaps be renamed soon
  110.  
  111.  
  112.  Known Bugs:        - some versions of DOpus and all Installer versions
  113.                       can't fetch the version information from the
  114.                       library binary due to some bugs in their code.
  115.                       Newer DOpus versions have this fixed and C:Version
  116.                       for example did that task always.
  117.  
  118.  
  119.  History:
  120.  
  121.  V43.9 (29.6.97) : - fixed memory bug-fix (argh)
  122.                      (-> Gunter Nikl)
  123.  
  124.  V43.8 (24.6.97) :  - again removed class dispatcher code (refresh bug)
  125.                     - added "known bugs" section
  126.                     - LibInit now delocates library base on error
  127.                       (NULL return)
  128.                       (-> Gunter Nikl)
  129.  
  130.  V43.7 (14.6.97) :  - fixed ftn-email address
  131.                     - updated class dispatcher
  132.                       (-> Roland Mainz)
  133.  
  134.  V43.6 (27.3.97) :  - did some finetuning
  135.                     - now can simply be turned into a V40 datatype
  136.                       by removing a #define (and/or the corresponding
  137.                       parts of the code)
  138.  
  139.  V43.5 (25.1.97) :  - now explicitely checks for DTA_SourceType == DTST_File
  140.                     - small changes
  141.                     - updated email information
  142.  
  143.  V43.4 (3.1.97) :   - fixed PRI entry in resident part
  144.                     - slightly changed SCOPTIONS
  145.                     - fixed some style things (APTR and library casts)
  146.                     - fixed a bug: bitmap would not have been freed
  147.                       on temporary-buffer allocation error
  148.                     - added note about library opening to L_OpenLibs()
  149.  
  150.  V43.3 (30.11.96) : - added SAS/C specific Ctrl-C disabling code
  151.                     - made some workarounds compiler sensitive
  152.                     - redone all with SAS/C V6.57
  153.  
  154.  V43.2 (3.11.96)  : - there was a FreeBitMap() call missing (oops)
  155.                     - it's samplePNM.dt, not samplePNG.dt ;-)
  156.  
  157.  V43.1 (25.10.96) : - added picture datatype V43 support
  158.                     - thus added support for 24 Bit PPM (P6),
  159.                       since PGM only has 256 grayscales
  160.                     - thus renamed to samplePNM.datatype
  161.  
  162.  V40.3 (13.9.96)  : - fixed more "style" things
  163.  
  164.  V40.2 (5.9.96)   : - fixed some "style" things
  165.  
  166.  V40.1 (2.9.96)   : - first release
  167.  
  168.  ---
  169.  All mentioned trademarks are subject to their owners.
  170.