[futurebasic] [FB] Assembler

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : November 1998 : Group Archive : Group : All Groups

From: "William P. Riley-Land" <wrileyla@...>
Date: Fri, 27 Nov 1998 16:57:54 -0600 (CST)
Well, here is the rest of the code, i don't really know what to do (this
is my first time with assembly)  I hope someone can give me a clue.

LOCAL FN fastCB(tSourceRect,tDestRect)
  ` movem.l a0-a1/d0-d7, -(sp) 
  
  ` move.l  ^gWorldPixMapBase&, D0 
  ` move.w  ^tSourceRect.top, D1 
  ` ext.l   D1 
  ` mulu.l  ^gWorldRowByteCount&, D1 
  ` add.l   D1, D0 
  ` move.w  ^tSourceRect.left, D1 
  ` ext.l   D1 
  ` add.l   D1, D0 
  ` move.l  D0, A0 
  
  ` move.l  ^gScreenPixMapBase&, D0 
  ` move.w  ^tDestRect.top, D1 
  ` ext.l   D1 
  ` mulu.l  ^gScreenRowByteCount&, D1 
  ` add.l   D1, D0 
  ` move.w  ^tDestRect.left, D1 
  ` ext.l   D1 
  ` add.l   D1, D0 
  ` move.l  D0, A1 
  
  ` move.w  ^tSourceRect.right, D6 
  ` move.w  ^tSourceRect.left, D0 
  ` sub.w   D0, D6  
  ` ext.l   D6 
  
  ` move.l  ^gWorldRowByteCount&, D2 
  ` sub.l   D6, D2 
  
  ` move.l  ^gScreenRowByteCount&, D3 
  ` sub.l   D6, D3 
  
  ` move.w  ^tSourceRect.bottom, D4 
  ` move.w  ^tSourceRect.top, D0 
  ` sub.w   D0, D4 
  ` ext.l   D4 
  ` subq.l  #1, D4 
  
  ` moveq.l #4, D5 
  
  ` tst.l   D4 
  ` ble.s   @6 
  
  ` move.l D6, D0 
  ` divs.l D5, D0 
  ` move.l D5, D7 
  ` mulu.l D0, D7 
  ` move.l D6, D1 
  ` sub.l  D7, D1 
  ` subq.l #1, D0 
  ` subq.l #1, D1 
  ` move.l D0, D6 
  ` move.l D1, D7 
  
  `@1
  ` tst.l D0 
  ` blt.s @3 
  
  `@2
  ` move.l (a0)+,(a1)+
  ` dbra d0,@2
  
  `@3
  ` tst.l D1
  ` blt.s @5
  
  `@4 
  ` move.b (a0)+, (a1)+ 
  ` dbra d1,@4 
  
  `@5 
  ` adda.l D2, A0 
  ` adda.l D3, A1 
  ` move.l D6, D0 
  ` move.l D7, D1 
  ` dbra d4,@1 
  
  `@6 
  ` movem.l (sp)+, a0-a1/d0-d7
END FN

Thanks, William Riley-Land

"You won't see me using any of those horrible .sig files to place messages
at the end of mail!"