home *** CD-ROM | disk | FTP | other *** search
- Album
- PRG formatted GEOS file V1.0
- CONVERTED WITH GEOSHELL V2.2
- Write Image V2.1
- geoWrite V2.1
- ;*************************************
- ; Album
- ; this is developed for use with
- ; GeoBasic. This routine may be
- ; loaded into memory at 30976 and
- ; then CALL 30978,a,x,y to display
- ; a photo scrap from an album.
- ; x and y should be loaded
- ; with the upper left corner location
- ; where the bitmap should be displayed.
- ; And .a should be loaded with the
- ; photo number in the album.
- ; The track and sector of the index
- ; block for the photo album should be
- ; poked to 30976 and 30977 prior to
- ; calling the routine.
- ;*************************************
- .if Pass1
- .noeqin
- .noglbl
- .include geosSym
- .include geosMac
- .glbl
- .eqin
- .endif
- .psect
- indexTrack:
- .block 1
- indexSector:
- .block 1
- indexTrack:
- .block 1
- indexSector:
- .block 1
- ;routine to display a PhotoScrap from an album using BitOtherClip.
- Album:
- asl a
- MoveB
- indexTrack
- MoveB
- indexSector
- LoadW r4,#indexBuffer
- jsr GetBlock
- PopB r1H
- PopB r1L
- lda indexBuffer+2,y
- beq 10$
- lda indexBuffer,y
- bne 15$
- sta saveR1L
- lda indexBuffer+1,y
- sta saveR1H
- LoadB saveR5+0,#0
- sta saveR5+1
- jsr GetNxtBitmapByte
- sta bitmapWidth
- jsr GetNxtBitmapByte
- sta bitmapHeight+0
- jsr GetNxtBitmapByte
- sta bitmapHeight+1
- lda #40
- sbc r1L
- sta r2L
- cmp bitmapWidth
- bcc 65$
- MoveB bitmapWidth,r2L
- LoadB r11H,#0
- beq 68$ ;branch always.
- lda bitmapWidth
- sbc r2L
- sta r11H
- lda bitmapHeight+1
- bne 70$
- lda #200
- sbc r1H
- cmp bitmapHeight+0
- bcc 70$
- lda bitmapHeight+0
- sta r2H
- jsr ReloadR0
- LoadB r11L,#0
- lda bitmapHeight+0
- sta r2H
- jsr ReloadR0
- LoadB r11L,#0
- sta r12L
- sta r12H
- LoadW r13,#GetBitmapByte
- LoadW r14,#ReloadR0
- jsr BitOtherClip
- ldx #0
- ReloadR0:
- LoadW r0,#bitmapBuffer
- GetBitmapByte:
- jsr GetNxtBitmapByte
- ldy #0
- sta (r0),y
- GetNxtBitmapByte:
- PushW r1
- PushW r4
- PushW r5
- MoveB saveR1L,r1L
- MoveB saveR1H,r1H
- LoadW r4,#diskBlkBuf
- MoveW saveR5,r5
- jsr ReadByte
- sta bitmapByte
- MoveB r1L,saveR1L
- MoveB r1H,saveR1H
- MoveW r5,saveR5
- PopW r5
- PopW r4
- PopW r1
- lda bitmapByte
- .ramsect
- saveR1L:
- .block 1
- saveR1H:
- .block 1
- saveR5:
- .block 2
- bitmapWidth:
- .block 1
- bitmapHeight:
- .block 2
- bitmapByte:
- .block 1
- bitmapBuffer:
- .block 134
- indexBuffer:
- .block 256
-