home *** CD-ROM | disk | FTP | other *** search
/ BCI NET 2 / BCI NET 2.iso / archives / grafix / boards / cybergfx4043.lha / cybershare / devdocs / autodoc / cybergraphics.doc < prev    next >
Encoding:
Text File  |  1995-02-07  |  25.6 KB  |  823 lines

  1. TABLE OF CONTENTS
  2.  
  3. cybergraphics.library/AllocCModeListTagList
  4. cybergraphics.library/BestCModeIDTagList
  5. cybergraphics.library/CModeRequestTagList
  6. cybergraphics.library/DoCDrawMethodTagList
  7. cybergraphics.library/FillPixelArray
  8. cybergraphics.library/FreeCModeList
  9. cybergraphics.library/GetCyberMapAttr
  10. cybergraphics.library/GetCyberIDAttr
  11. cybergraphics.library/IsCyberModeID
  12. cybergraphics.library/MovePixelArray
  13. cybergraphics.library/ReadPixelArray
  14. cybergraphics.library/ReadRGBPixel
  15. cybergraphics.library/ScalePixelArray
  16. cybergraphics.library/SwapPixelArray
  17. cybergraphics.library/WritePixelArray
  18. cybergraphics.library/WriteRGBPixel
  19. cybergraphics.lib/AllocCModeListTagList cybergraphics.lib/AllocCModeListTagList
  20.  
  21.  
  22.    NAME
  23.     AllocCModeListTagList -- get an exec list with requested modes.
  24.  
  25.    SYNOPSIS
  26.     result = CModeRequestTagList(ModeListTags);
  27.     D0                                A1
  28.  
  29.     APTR AllocCModeListTagList(struct TagItem *);
  30.  
  31.    FUNCTION
  32.     Allocates a list structure which contains all requested modes (All nodes
  33.     are of type CyberModeNode). See defines for more information about the
  34.     structure of this nodes.
  35.  
  36.    INPUTS
  37.     tags - pointer to an optional tag list which may be used to
  38.            control the number of returned modes.
  39.  
  40.    TAGS
  41.  
  42.     Tags available are:
  43.  
  44.     CYBRMREQ_MinWidth (ULONG) - The minimum display width to let the user
  45.             choose. Default is 320.
  46.  
  47.     CYBRMREQ_MaxWidth (ULONG) - The maximum display width to let the user
  48.             choose. Default is 1600.
  49.  
  50.     CYBRMREQ_MinHeight (ULONG) - The minimum display height to let the user
  51.             choose. Default is 240.
  52.  
  53.     CYBRMREQ_MaxHeight (ULONG) - The maximum display height to let the user
  54.             choose. Default is 1200.
  55.  
  56.     CYBRMREQ_MinDepth (UWORD) - The minimum display depth to let the user
  57.             choose. Default is 8.
  58.  
  59.     CYBRMREQ_MaxDepth (UWORD) - The maximum display depth to let the user
  60.             choose. Default is 32.
  61.  
  62.     CYBRMREQ_CModelArray (UWORD *) - Array of color models which should be
  63.             available for screenmode selection. Currently supported
  64.             colormodels are:
  65.  
  66.             PIXFMT_LUT8
  67.             PIXFMT_RGB15
  68.             PIXFMT_BGR15
  69.             PIXFMT_RGB15PC
  70.             PIXFMT_BGR15PC
  71.             PIXFMT_RGB16
  72.             PIXFMT_BGR16
  73.             PIXFMT_RGB16PC
  74.             PIXFMT_BGR16PC
  75.             PIXFMT_RGB24
  76.             PIXFMT_BGR24
  77.             PIXFMT_ARGB32
  78.             PIXFMT_BGRA32
  79.  
  80.             default is all colormodels available, nothing filtered
  81.  
  82.    RESULT
  83.     result - 0 if no modes are available, a pointer to a exec list if there
  84.          are modes which fit your needs.
  85. cybergraphics.library/BestCModeIDTagList   cybergraphics.library/BestCModeIDTagList
  86.  
  87.  
  88.    NAME
  89.     BestCModeIDTagList  -- calculate the best ModeID with given parameters
  90.  
  91.    SYNOPSIS
  92.     ID = BestCModeIDTagList(TagItems)
  93.     d0                     a0
  94.  
  95.     ID = BestCModeIDTags(Tag1, ...)
  96.  
  97.    FUNCTION
  98.     To determine the best cybergraphics ModeID to fit the parameters set
  99.     in the TagList.
  100.  
  101.    INPUTS
  102.     TagItems - A pointer to an array of TagItems.
  103.  
  104.    TAGS
  105.  
  106.         CYBRBIDTG_Depth (ULONG) - depth the returned ModeID must support
  107.                                   Default is 8
  108.  
  109.         CYBRBIDTG_NominalWidth (UWORD),
  110.         CYBRBIDTAG_NominalHeight (UWORD) - desired width and height the ModeID
  111.                                            should have
  112.  
  113.         CYBRBIDTG_MonitorID (ULONG) - if multiple graphics boards are
  114.                                       installed in the system, you can choose
  115.                                       the desired one with this tag
  116.  
  117.    RESULT
  118.     ID      - ID of the best mode to use, or INVALID_ID if a match could
  119.               not be found.
  120.  
  121. cybergraphics.lib/CModeRequestTagList    cybergraphics.lib/CModeRequestTagList
  122.  
  123.  
  124.    NAME
  125.     CModeRequestTagList -- get screenmode from user using a requester.
  126.  
  127.    SYNOPSIS
  128.     result = CModeRequestTagList(requester,tags);
  129.     D0                            A0        A1
  130.  
  131.     LONG CModeRequestTagList(APTR,struct TagItem *);
  132.  
  133.    FUNCTION
  134.     Prompts the user for input by showing all available cybergraphics
  135.     screenmodes in a requester.
  136.     If the user cancels or the system aborts the request, FALSE is returned,
  137.     otherwise the displaymode id of the selected screenmode.
  138.  
  139.    INPUTS
  140.     requester - not used currently. you have to set it to 0 !
  141.     tags - pointer to an optional tag list which may be used to
  142.            control features of the requester.
  143.  
  144.    TAGS
  145.  
  146.     Tags used for the screen mode requester
  147.  
  148.     CYBRMREQ_Screen (struct Screen *) - Screen on which to open the requester.
  149.             default locale will be used.
  150.  
  151.     CYBRMREQ_WinTitle (STRPTR) - Title to use for the requesting window.
  152.  
  153.     CYBRMREQ_OKText (STRPTR) - Label of the positive gadget in the
  154.             requester. English default is "OK".
  155.  
  156.     CYBRMREQ_CancelText (STRPTR) - Label of the negative gadget in the
  157.             requester. English default is "Cancel".
  158.  
  159.     CYBRMREQ_MinWidth (ULONG) - The minimum display width to let the user
  160.             choose. Default is 320.
  161.  
  162.     CYBRMREQ_MaxWidth (ULONG) - The maximum display width to let the user
  163.             choose. Default is 1600.
  164.  
  165.     CYBRMREQ_MinHeight (ULONG) - The minimum display height to let the user
  166.             choose. Default is 240.
  167.  
  168.     CYBRMREQ_MaxHeight (ULONG) - The maximum display height to let the user
  169.             choose. Default is 1200.
  170.  
  171.     CYBRMREQ_MinDepth (UWORD) - The minimum display depth to let the user
  172.             choose. Default is 8.
  173.  
  174.     CYBRMREQ_MaxDepth (UWORD) - The maximum display depth to let the user
  175.             choose. Default is 32.
  176.  
  177.     CYBRMREQ_CModelArray (UWORD *) - Array of color models which should be
  178.             available for screenmode selection. Currently supported
  179.             colormodels are:
  180.  
  181.             PIXFMT_LUT8
  182.             PIXFMT_RGB15
  183.             PIXFMT_BGR15
  184.             PIXFMT_RGB15PC
  185.             PIXFMT_BGR15PC
  186.             PIXFMT_RGB16
  187.             PIXFMT_BGR16
  188.             PIXFMT_RGB16PC
  189.             PIXFMT_BGR16PC
  190.             PIXFMT_RGB24
  191.             PIXFMT_BGR24
  192.             PIXFMT_ARGB32
  193.             PIXFMT_BGRA32
  194.  
  195.             default is all colormodels available, nothing filtered
  196.  
  197.    RESULT
  198.     result - 0 if the user cancelled the requester or if something
  199.          prevented the requester from opening. If != 0 the displaymode
  200.          id of the selected screenmode is returned.
  201.  
  202.    BUGS
  203.     The requester structure is not supported in (v40)
  204. cybergraphics.lib/DoCDrawMethodTagList cybergraphics.lib/DoCDrawMethodTagList
  205.  
  206.  
  207.    NAME
  208.     DoCDrawMethodTagList - Do the given hook for the supplied rastport
  209.  
  210.    SYNOPSIS
  211.     DoCDrawMethodTagList(hook,rport,taglist)
  212.                           a0   a1    a2
  213.  
  214.     void DoCDrawMethodTagList(struct Hook *,struct RastPort *,
  215.                 struct TagItem *)
  216.  
  217.    FUNCTION
  218.     This function will call the given hook for the given rastport. Is is
  219.     mainly used to do direct bitmap modifications in a locked graphics
  220.     environment. You have to support ALL known color models, so only use
  221.     this call if you really need it !!
  222.     
  223.  
  224.    INPUTS
  225.  
  226.     hook - pointer to callback hook which will be called
  227.            with object == (struct RastPort *)
  228.            and message == [ (APTR) memptr,
  229.                             (ULONG) offsetx, (ULONG) offsety,
  230.                 (ULONG) xsize, (ULONG) ysize,
  231.                 (ULONG) bytesperrow, (UWORD) bytesperpix,
  232.                 (UWORD) colormodel]
  233.  
  234.            Where colormodel is one of the following:
  235.  
  236.             PIXFMT_LUT8
  237.             PIXFMT_RGB15
  238.             PIXFMT_BGR15
  239.             PIXFMT_RGB15PC
  240.             PIXFMT_BGR15PC
  241.             PIXFMT_RGB16
  242.             PIXFMT_BGR16
  243.             PIXFMT_RGB16PC
  244.             PIXFMT_BGR16PC
  245.             PIXFMT_RGB24
  246.             PIXFMT_BGR24
  247.             PIXFMT_ARGB32
  248.             PIXFMT_BGRA32
  249.  
  250.     rport- A pointer to a cybergraphics RastPort
  251.  
  252.     tags - optional taglist, currently not used. Set it to NULL
  253.  
  254.     NOTES
  255.     Use this call only if you want high speed. Remember that you have to
  256.     handle all color models ! Do not use ANY os functions in your hook.
  257.     They would cause unpredictable results.
  258.  
  259.  
  260.     BUGS
  261.     In the current release this function only works on screen rastports.
  262.     Because of this limitation clipping is not supported.
  263.  
  264.  
  265. cybergraphics.lib/FreeCModeList                cybergraphics.lib/FreeCModeList
  266.  
  267.  
  268.    NAME
  269.     FreeCModeList -- frees a previously allocated ModeList
  270.                          (AllocCModeListTagList)
  271.  
  272.    SYNOPSIS
  273.     FreeCModeList(ModeListTags);
  274.                       A0
  275.  
  276.     void FreeCModeList(struct List *);
  277.  
  278.    FUNCTION
  279.     Frees all data which was previously allocated by AllocCModeListTagList
  280.  
  281.    INPUTS
  282.     ModeListTags - a list structure which contains all the mode data.
  283.  
  284.    RESULT
  285.     none
  286.  
  287. cybergraphics.library/GetCyberMapAttr    cybergraphics.library/GetCyberMapAttr
  288.  
  289.  
  290.    NAME
  291.     GetCyberMapAttr -- Returns information about a cybergraphics bitmap
  292.  
  293.    SYNOPSIS
  294.      value=GetCyberMapAttr(bitmap,attribute_number);
  295.     d0                     a0       d1
  296.  
  297.     ULONG GetCyberMapAttr(struct BitMap *,ULONG);
  298.  
  299.    FUNCTION
  300.         Determines information about a extended cybergraphics bitmap.
  301.     This function should be used instead of making any assumptions about
  302.     fields in the bitmap. This will    provide future compatibility.
  303.  
  304.    INPUTS
  305.     bitmap - pointer to a cybergraphics bitmap structure
  306.  
  307.     attribute_number - A number telling cybergraphics which attribute
  308.                of the bitmap should be returned:
  309.  
  310.         CYBRMATTR_XMOD returns BytesPerRow of the supplied bitmap
  311.  
  312.         CYBRMATTR_BPPIX returns number of bytes per pixel
  313.  
  314.         CYBRMATTR_PIXFMT return the pixel format of the bitmap
  315.  
  316.         CYBRMATTR_WIDTH return width of the bitmap in pixels
  317.  
  318.         CYBRMATTR_HEIGHT return the height in lines
  319.  
  320.         CYBRMATTR_DEPTH returns bits per pixel
  321.  
  322.    BUGS
  323.  
  324.    NOTES
  325.  
  326.     Unknown attributes are reserved for future use, and return (-1L).
  327.  
  328.     You should know what you are doing if you call this function !
  329.     Don't apply it on a non cybergraphics bitmap !
  330.  
  331. cybergraphics.library/GetCyberIDAttr    cybergraphics.library/GetCyberIDAttr
  332.  
  333.  
  334.    NAME
  335.     GetCyberIDAttr -- Returns information about a cybergraphics id
  336.  
  337.    SYNOPSIS
  338.      value=GetCyberIDAttr(CyberIDAttr,CyberDisplayModeID);
  339.     d0                     d0           d1
  340.  
  341.     ULONG GetCyberIDAttr(ULONG,ULONG);
  342.  
  343.    FUNCTION
  344.         Determines information about a specified displaymode id.
  345.  
  346.    INPUTS
  347.     CyberDisplayModeID - cybergraphics mode id
  348.  
  349.     attribute_number - A number telling cybergraphics which attribute
  350.                of the displaymode id should be returned:
  351.  
  352.         CYBRIDATTR_PIXFMT return the pixel format of the supplied
  353.                 screenmode id
  354.  
  355.         CYBRIDATTR_WIDTH returns visible width in pixels
  356.         CYBRIDATTR_HEIGHT returns visible height in lines
  357.         CYBRIDATTR_DEPTH returns bits per pixel
  358.         CYBRIDATTR_BPPIX should return BytesPerPixel
  359.  
  360.    BUGS
  361.  
  362.    NOTES
  363.  
  364.     Unknown attributes are reserved for future use, and return (-1L).
  365.  
  366.     You should know what you are doing if you call this function !
  367.     Don't apply it on a non cybergraphics displaymode !
  368.  
  369.  
  370. cybergraphics.library/IsCyberModeID       cybergraphics.library/IsCyberModeID
  371.  
  372.  
  373.    NAME
  374.     IsCyberModeID -- returns whether supplied ModeID is a cybergraphics id
  375.  
  376.    SYNOPSIS
  377.     result = IsCyberModeID(modeID)
  378.     D0                       D0
  379.  
  380.     BOOL IsCyberModeID(ULONG)
  381.  
  382.    FUNCTION
  383.     Returns whether the supplied ModeID is a cybergraphics.library mode
  384.     identifier.
  385.  
  386.    INPUTS
  387.     modeID -- a 32 bit display identifier.
  388.  
  389.    RESULT
  390.     result - Flag to indicate if modeID is a cybergraphics ID
  391.  
  392. cybergraphics.library/FillPixelArray     cybergraphics.library/FillPixelArray
  393.  
  394.  
  395.    NAME
  396.         FillPixelArray -- fill a rectangular area with the supplied ARGB value
  397.     starting at a specified x,y location and continuing through to another
  398.     x,y location within a certain RastPort
  399.  
  400.    SYNOPSIS
  401.     count = FillPixelArray(RastPort,DestX, DestY,SizeX,SizeY,ARGB)
  402.     D0             A1     D0:16  D1:16 D2:16 D3:16 D4:32
  403.             
  404.  
  405.     LONG FillPixelArray(struct RastPort *,UWORD,UWORD,UWORD,UWORD,ULONG)
  406.  
  407.    FUNCTION
  408.     For each pixel in a rectangular region, write the supplied color value
  409.     into the bitmap used to describe a particular rastport.
  410.  
  411.    INPUTS
  412.     RastPort -  pointer to a RastPort structure
  413.     (DestX,DestY) - starting point in the RastPort
  414.     (SizeX,SizeY) - size of the rectangle that should be transfered
  415.         ARGB  - the desired color in AARRGGBB format. Every component
  416.         allocates 8 bits of the returned longword. The coding is as
  417.         follows:
  418.  
  419.                  AA - 8-bit alpha channel component
  420.               (set it to 00 if you do not use it !)
  421.                  RR - 8-bit red component of the pixel
  422.                  GG - 8-bit green component
  423.                  BB - 8-bit blue component
  424.  
  425.    RESULT
  426.     count will be set to the number of pixels plotted
  427.  
  428.    NOTES
  429.     This function should only be used on screens depths > 8 bits.
  430.  
  431.    BUGS
  432.     In the current release this function only works on screen rastports.
  433.     Because of this limitation clipping is not supported.
  434.  
  435.  
  436. cybergraphics.library/InvertPixelArray     cybergraphics.library/InvertPixelArray
  437.  
  438.  
  439.    NAME
  440.         InvertPixelArray -- invert a rectangular area tarting at a specified x,y
  441.     location and continuing through to another x,y location within a certain
  442.     RastPort
  443.  
  444.    SYNOPSIS
  445.     count = InvertPixelArray(RastPort,DestX, DestY,SizeX,SizeY)
  446.     D0               A1     D0:16  D1:16 D2:16 D3:16
  447.             
  448.  
  449.     LONG InvertPixelArray(struct RastPort *,UWORD,UWORD,UWORD,UWORD)
  450.  
  451.    FUNCTION
  452.     Invert each pixel in a rectangular region.
  453.  
  454.    INPUTS
  455.     RastPort -  pointer to a RastPort structure
  456.     (DestX,DestY) - starting point in the RastPort
  457.     (SizeX,SizeY) - size of the rectangle that should be transfered
  458.  
  459.    RESULT
  460.     count will be set to the number of pixels plotted
  461.  
  462.    NOTES
  463.     This function should only be used on screens depths > 8 bits.
  464.  
  465.    BUGS
  466.     In the current release this function only works on screen rastports.
  467.     Because of this limitation clipping is not supported.
  468.  
  469. cybergraphics.library/MovePixelArray     cybergraphics.library/MovePixelArray
  470.  
  471.  
  472.    NAME
  473.         MovePixelArray -- move the color values of a rectangular area of
  474.     pixels starting at a specified x,y location and continuing through
  475.     to another x,y location within a certain RastPort
  476.  
  477.    SYNOPSIS
  478.     count = MovePixelArray(SrcX, SrcY, RastPort,SrcX , SrcY ,SizeX, SizeY)
  479.     D0               D0:16 D1:16  A1      D2:16  D3:16 D4:16  D5:16
  480.  
  481.     LONG MovePixelArray(UWORD,UWORD,struct RastPort *,UWORD,UWORD,UWORD,
  482.                 UWORD)
  483.  
  484.    FUNCTION
  485.     For each pixel in a rectangular region, move the pixel value from a
  486.     specified source to a specified destination
  487.  
  488.    INPUTS
  489.     (SrcX,SrcY) - starting point in the destination rectangle
  490.     RastPort -  pointer to a RastPort structure
  491.     (DestX,DestY) - starting point in the destination rectangle
  492.     (SizeX,SizeY) - size of the rectangle that should be transfered
  493.  
  494.    RESULT
  495.     count will be set to the number of pixels moved
  496.  
  497.    NOTES
  498.     This function should only be used on screens depths > 8 bits.
  499.     The blitter can be used to move the data if the bitmap is in display
  500.     memory. This is way you should use this call.
  501.  
  502.    BUGS
  503.     In the current release this function only works on screen rastports.
  504.     Because of that limitation clipping is not supported.
  505.  
  506. cybergraphics.library/ReadPixelArray     cybergraphics.library/ReadPixelArray
  507.  
  508.  
  509.    NAME
  510.         ReadPixelArray -- Read the color values of a rectangular array of
  511.     pixels starting at a specified x,y location and continuing through
  512.     to another x,y location within a certain RastPort
  513.  
  514.    SYNOPSIS
  515.     count = ReadPixelArray(destRect,DestX,DestY,DestMod,RastPort,SrcX ,
  516.     D0              A0    D0:16 D1:16 D2:16     A1     D3:16
  517.                 SrcY ,SizeX,SizeY,DestFormat)
  518.                 D4:16 D5:16 D6:16    D7
  519.  
  520.     LONG ReadPixelArray(APTR,UWORD,UWORD,UWORD,struct RastPort *,UWORD,
  521.                 UWORD,UWORD,UWORD,UBYTE)
  522.  
  523.    FUNCTION
  524.     For each pixel in a rectangular region, write the color value to a
  525.     linear array of color values from the bitmap used to describe a
  526.     particular rastport.
  527.  
  528.    INPUTS
  529.     destRect - pointer to an array of pixels where to write the pixel
  530.                data to. The pixel format is specified in DestFormat
  531.     (DestX,DestY) - starting point in the destination rectangle
  532.     DestMod - The number of bytes per row in the destination rectangle.
  533.     RastPort -  pointer to a RastPort structure
  534.     (SrcX,SrcY) - starting point in the RastPort
  535.     (SizeX,SizeY) - size of the rectangle that should be transfered
  536.     DestFormat - pixel format in the destination rectangle
  537.                 Currently supported formats are:
  538.  
  539.                 RECTFMT_RGB  3 bytes per pixel, one byte red, one blue
  540.                              and one byte green component
  541.  
  542.                 RECTFMT_RGBA 4 bytes per pixel, one byte red, one blue,
  543.                              one byte green component and the last
  544.                                  byte is alpha channel information which
  545.                          is 0 if the board does not support alpha
  546.                                  channel
  547.  
  548.                 RECTFMT_ARGB 4 bytes per pixel, one byte red, one blue,
  549.                              one byte green component and the first
  550.                                  byte is alpha channel information. If the
  551.                                  board does not support alpha channel a 
  552.                          0 is returned for alpha channel information
  553.  
  554.    RESULT
  555.     count will be set to the number of pixels read
  556.  
  557.    NOTES
  558.     This function should only be used on screens depths > 8 bits.
  559.  
  560.    BUGS
  561.     In the current release this function only works on screen rastports.
  562.     Because of that limitation clipping is not supported.
  563.  
  564. cybergraphics.library/ReadRGBPixel          cybergraphics.library/ReadRGBPixel
  565.  
  566.  
  567.    NAME
  568.         ReadRGBPixel -- Reads a pixel from a specified location
  569.  
  570.    SYNOPSIS
  571.         color = ReadRGBPixel(RastPort,x ,y )
  572.         D0                     A0     D0 D1
  573.  
  574.         ULONG ReadRGBPixel(struct RastPort *,UWORD,UWORD);
  575.  
  576.    FUNCTION
  577.     Read the Alpha,Red,Green & Blue 8-bit color value of the pixel at a
  578.     specified x,y location within a certain RastPort
  579.  
  580.    INPUTS
  581.     rp -  pointer to a RastPort structure
  582.         x,y    - the coordinates of the pixel
  583.  
  584.    RESULT
  585.         color  - the desired color in AARRGGBB format. Every component
  586.          allocates 8 bits of the returned longword. The coding is as
  587.          follows:
  588.  
  589.                  AA - 8-bit alpha channel component
  590.               (boards which do not have an alpha channel return 00)
  591.                  RR - 8-bit red component of the pixel
  592.                  GG - 8-bit green component
  593.                  BB - 8-bit blue component
  594.  
  595.   NOTES
  596.     This function should only be used on screens depths > 8 bits. Use
  597.     ReadPixel() on 8 bit screens !
  598.  
  599.   BUGS
  600.     In the current release this function only works on screen rastports.
  601.     Because of that limitation clipping is not supported.
  602.  
  603. cybergraphics.library/ScalePixelArray   cybergraphics.library/ScalePixelArray
  604.  
  605.  
  606.    NAME
  607.        ScalePixelArray -- Scale the colors values of a rectangular array of
  608.     pixels starting at a specified x,y location and continuing through
  609.     to another x,y location within a certain RastPort (V41)
  610.  
  611.    SYNOPSIS
  612.     count = ScalePixelArray(srcRect,SrcW,SrcH ,SrcMod,RastPort,DestX,
  613.     D0               A0   D0:16 D1:16 D2:16     A1    D3:16
  614.                 DestY,DestW,DestH,SrcFormat)
  615.                 D4:16 D5:16 D6:16    D7
  616.  
  617.     LONG ScalePixelArray(APTR,UWORD,UWORD,UWORD,struct RastPort *,UWORD,
  618.                  UWORD,UWORD,UWORD,UBYTE)
  619.  
  620.    FUNCTION
  621.     For each pixel in a rectangular region, scale the color values from a
  622.     linear array of color values into the bitmap used to describe a
  623.     particular rastport.
  624.  
  625.    INPUTS
  626.     srcRect - pointer to an array of pixels from which to fetch the
  627.               pixel data. The pixel format is specified in SrcFormat
  628.     (SrcW,SrcH) - Width and Height of the source rectangle
  629.     SrcMod - The n umber of bytes per row in the source rectangle.
  630.     RastPort -  pointer to a RastPort structure
  631.     (DestX,DestY) - starting point in the RastPort
  632.     (DestW,DestH) - size of the destination area
  633.     SrcFormat - pixel format in the source rectangle
  634.                 Currently supported formats are:
  635.  
  636.                 RECTFMT_RGB  3 bytes per pixel, one byte red, one blue
  637.                              and one byte green component
  638.  
  639.                 RECTFMT_RGBA 4 bytes per pixel, one byte red, one blue,
  640.                              one byte green component and the last
  641.                                  byte is alpha channel information. If you
  642.                                  do not use alpha channel set this byte to
  643.                          0 !!!
  644.  
  645.                 RECTFMT_ARGB 4 bytes per pixel, one byte red, one blue,
  646.                              one byte green component and the first
  647.                                  byte is alpha channel information. If you
  648.                                  do not use alpha channel set this byte to
  649.                          0 !!!
  650.  
  651.    RESULT
  652.     count will be set to the number of pixels plotted
  653.  
  654.    NOTES
  655.     This function should only be used on screens depths > 8 bits.
  656.  
  657.    BUGS
  658.     In the V40 release this function only works on screen rastports.
  659.     Because of that limitation clipping was not supported.
  660.         This is fixed in V41
  661. cybergraphics.library/SwapPixelArray     cybergraphics.library/SwapPixelArray
  662.  
  663.  
  664.    NAME
  665.         SwapPixelArray -- Swap the color values of a rectangular array of
  666.     pixels starting at a specified x,y location and continuing through
  667.     to another x,y location within a certain RastPort
  668.  
  669.    SYNOPSIS
  670.     count = SwapPixelArray(MemRect,MemX  ,MemY,MemMod,RastPort, RastX ,
  671.     D0              A0   D0:16 D1:16 D2:16     A1     D3:16
  672.                 RastY ,SizeX,SizeY,MemFormat)
  673.                 D4:16 D5:16 D6:16    D7
  674.  
  675.     LONG SwapPixelArray(APTR,UWORD,UWORD,UWORD,struct RastPort *,UWORD,
  676.                 UWORD,UWORD,UWORD,UBYTE)
  677.  
  678.    FUNCTION
  679.     For each pixel in a rectangular region, swap the color values of a
  680.     linear array of color values and a bitmap used to describe a
  681.     particular rastport.
  682.  
  683.    INPUTS
  684.     MemRect - pointer to an array of pixels where to write the pixel
  685.               data of the bitmapto. The pixel format is specified in
  686.           MemFormat
  687.     (MemX,MemY) - starting point in the memory rectangle
  688.     MemMod - The number of bytes per row in the memory rectangle.
  689.     RastPort -  pointer to a RastPort structure
  690.     (RastX,RastY) - starting point in the RastPort rectangle
  691.     (SizeX,SizeY) - size of the rectangle that should be transfered
  692.     MemFormat - pixel format in the memory rectangle
  693.                 Currently supported formats are:
  694.  
  695.                 RECTFMT_RGB  3 bytes per pixel, one byte red, one blue
  696.                              and one byte green component
  697.  
  698.                 RECTFMT_RGBA 4 bytes per pixel, one byte red, one blue,
  699.                              one byte green component and the last
  700.                                  byte is alpha channel information which
  701.                          is 0 if the board does not support alpha
  702.                                  channel
  703.  
  704.                 RECTFMT_ARGB 4 bytes per pixel, one byte red, one blue,
  705.                              one byte green component and the first
  706.                                  byte is alpha channel information. If the
  707.                                  board does not support alpha channel a 
  708.                          0 is returned for alpha channel information
  709.  
  710.    RESULT
  711.     count will be set to the number of pixels swapped
  712.  
  713.    NOTES
  714.     This function should only be used on screens depths > 8 bits.
  715.     DON'T USE THIS FUNCTION WITH V40 OF CYBERGRAPHICS
  716.  
  717.    BUGS
  718.     In the current release this function only works on screen rastports.
  719.     Because of that limitation clipping is not supported.
  720.     THIS FUNCTION IS BROKEN IN V40 ... DON'T USE IT
  721.  
  722. cybergraphics.library/WritePixelArray   cybergraphics.library/WritePixelArray
  723.  
  724.  
  725.    NAME
  726.         WritePixelArray -- write the color value of a rectangular array of
  727.     pixels starting at a specified x,y location and continuing through
  728.     to another x,y location within a certain RastPort
  729.  
  730.    SYNOPSIS
  731.     count = WritePixelArray(srcRect,SrcX ,SrcY ,SrcMod,RastPort,DestX,
  732.     D0               A0   D0:16 D1:16 D2:16     A1    D3:16
  733.                 DestY,SizeX,SizeY,SrcFormat)
  734.                 D4:16 D5:16 D6:16    D7
  735.  
  736.     LONG WritePixelArray(APTR,UWORD,UWORD,UWORD,struct RastPort *,UWORD,
  737.                  UWORD,UWORD,UWORD,UBYTE)
  738.  
  739.    FUNCTION
  740.     For each pixel in a rectangular region, write the color value from a
  741.     linear array of color values into the bitmap used to describe a
  742.     particular rastport.
  743.  
  744.    INPUTS
  745.     srcRect - pointer to an array of pixels from which to fetch the
  746.               pixel data. The pixel format is specified in SrcFormat
  747.     (SrcX,SrcY) - starting point in the source rectangle
  748.     SrcMod - The number of bytes per row in the source rectangle.
  749.     RastPort -  pointer to a RastPort structure
  750.     (DestX,DestY) - starting point in the RastPort
  751.     (SizeX,SizeY) - size of the rectangle that should be transfered
  752.     SrcFormat - pixel format in the source rectangle
  753.                 Currently supported formats are:
  754.  
  755.                 RECTFMT_RGB  3 bytes per pixel, one byte red, one blue
  756.                              and one byte green component
  757.  
  758.                 RECTFMT_RGBA 4 bytes per pixel, one byte red, one blue,
  759.                              one byte green component and the last
  760.                                  byte is alpha channel information. If you
  761.                                  do not use alpha channel set this byte to
  762.                          0 !!!
  763.  
  764.                 RECTFMT_ARGB 4 bytes per pixel, one byte red, one blue,
  765.                              one byte green component and the first
  766.                                  byte is alpha channel information. If you
  767.                                  do not use alpha channel set this byte to
  768.                          0 !!!
  769.  
  770.    RESULT
  771.     count will be set to the number of pixels plotted
  772.  
  773.    NOTES
  774.     This function should only be used on screens depths > 8 bits. Use
  775.     WritePixelArray8() on 8 bit screens !
  776.  
  777.    BUGS
  778.     In the current release this function only works on screen rastports.
  779.     Because of that limitation clipping is not supported.
  780.  
  781.  
  782. cybergraphics.library/WriteRGBPixel        cybergraphics.library/WriteRGBPixel
  783.  
  784.  
  785.    NAME
  786.         WriteRGBPixel -- Writes a pixel to a specified location
  787.  
  788.    SYNOPSIS
  789.         error = WriteRGBPixel(RastPort,x ,y ,color)
  790.         D0                      A0     D0 D1 d2
  791.  
  792.         ULONG WriteRGBPixel(struct RastPort *,UWORD,UWORD,ULONG);
  793.  
  794.    FUNCTION
  795.     Write the Alpha,Red,Green & Blue 8-bit color value of the given color
  796.     to a specified x,y location within a certain RastPort
  797.  
  798.    INPUTS
  799.     rp     - pointer to a RastPort structure
  800.         x,y    - the coordinates of the pixel
  801.         color  - the desired color in AARRGGBB format. Every component
  802.          allocates 8 bits of the returned longword. The coding is as
  803.          follows:
  804.  
  805.                  AA - 8-bit alpha channel component
  806.               (set it to 00 if you dont want to use it !)
  807.                  RR - 8-bit red component of the pixel
  808.                  GG - 8-bit green component
  809.                  BB - 8-bit blue component
  810.  
  811.    RESULT
  812.     error = 0 if pixel succesfully changed
  813.           = -1 if (x,y) is outside the rastport
  814.  
  815.    NOTES
  816.     This function should only be used on screens depths > 8 bits. Use
  817.     WritePixel() on 8 bit screens !
  818.  
  819.    BUGS
  820.     In the current release this function only works on screen rastports.
  821.     Because of that limitation clipping is not supported.
  822.  
  823.