home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Professional / OS2PRO194.ISO / os2 / prgramer / fort_lib / wbtpln.asm < prev    next >
Assembly Source File  |  1991-01-17  |  1KB  |  36 lines

  1. ;
  2. ;----------------------------------------------------------------------
  3. ; write to the bitplane defined with WColor()
  4. ;----------------------------------------------------------------------
  5. ;
  6. ;FORTRAN calling sequence
  7. ;       INTERFACE TO SUBROUTINE WBtPln(VGASeg,BtPlnD)
  8. ;       INTEGER*4  VGASeg [NEAR,VALUE]
  9. ;       INTEGER*1  BtPlnD(38400)   ! VGA
  10. ;       INTEGER*1  BtPlnD(28000)   ! EGA
  11. ;       END
  12. ;       ...
  13. ;       CALL WBtPln(VGASeg,BtPlnD)
  14. ;
  15.         .286p
  16.         .MODEL large,fortran
  17.         .CODE
  18.  
  19. WBtPln  PROC    USES cx ds es si di, VGASeg: DWORD, BtPlnD: PTR BYTE
  20.  
  21.         les     di,VGASeg               ; ES = VGABase
  22.  
  23.         lds     si,BtPlnD               ; DS = SEGMENT(BtPlnD)
  24.                                         ; SI = OFFSET(BtPlnD)
  25.         cld                             ; clear direction flag
  26.         mov     cx,38400/2              ; number of words in one
  27.                                         ; VGA bitplane
  28. ;       mov     cx,28000/2              ; number of words in one
  29.                                         ; EGA bitplane
  30.         rep     movsw                   ; copy
  31.  
  32.         ret
  33.  
  34. WBtPln  ENDP
  35.         END
  36.