home *** CD-ROM | disk | FTP | other *** search
/ ticalc.org / ticalc_org_rev_b.iso / archives / mac / quicksprite.hqx / SpriteBlitt.asm < prev   
MacBinary  |  1998-04-10  |  1.9 KB  |  [TEXT/ttxt]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, inited, Thu Apr 9 23:52:26 1998, modified Thu Apr 9 23:52:26 1998, creator SimpleText, type ASCII, 1379 bytes "SpriteBlitt.asm" , at 0x5e3 332 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[ttxt]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0f 53 70 72 69 74 65 | 42 6c 69 74 74 2e 61 73 |..Sprite|Blitt.as|
|00000010| 6d 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |m.......|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 74 74 78 | 74 01 00 00 00 00 00 00 |.TEXTttx|t.......|
|00000050| 00 00 00 00 00 05 63 00 | 00 01 4c b1 53 47 fa b1 |......c.|..L.SG..|
|00000060| 53 47 fa 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |SG......|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 ad 2d 00 00 |........|.....-..|
|00000080| 3b 20 53 70 72 69 74 65 | 42 6c 69 74 74 20 62 79 |; Sprite|Blitt by|
|00000090| 20 45 72 69 6b 20 48 75 | 69 7a 69 6e 67 20 28 65 | Erik Hu|izing (e|
|000000a0| 68 75 69 7a 69 6e 67 40 | 61 63 73 2e 75 63 61 6c |huizing@|acs.ucal|
|000000b0| 67 61 72 79 2e 63 61 29 | 20 28 4e 6f 76 20 31 38 |gary.ca)| (Nov 18|
|000000c0| 2f 39 37 29 0d 3b 20 70 | 6c 6f 74 73 20 73 70 72 |/97).; p|lots spr|
|000000d0| 69 74 65 73 20 6c 61 72 | 67 65 72 20 74 68 61 6e |ites lar|ger than|
|000000e0| 20 38 78 38 0d 3b 20 63 | 6f 64 65 20 73 69 7a 65 | 8x8.; c|ode size|
|000000f0| 20 3d 20 38 37 20 62 79 | 74 65 73 28 3f 29 0d 3b | = 87 by|tes(?).;|
|00000100| 0d 3b 20 69 6e 70 75 74 | 73 3a 0d 3b 20 68 6c 20 |.; input|s:.; hl |
|00000110| 3d 20 73 70 72 69 74 65 | 20 64 61 74 61 20 20 20 |= sprite| data |
|00000120| 20 20 20 62 63 20 3d 20 | 63 6f 6f 72 64 73 0d 3b | bc = |coords.;|
|00000130| 20 6f 75 74 70 75 74 73 | 3a 0d 3b 20 61 66 2c 20 | outputs|:.; af, |
|00000140| 62 63 2c 20 64 65 2c 20 | 68 6c 2c 20 69 78 20 64 |bc, de, |hl, ix d|
|00000150| 65 73 74 6f 72 79 65 64 | 0d 3b 20 73 70 72 69 74 |estoryed|.; sprit|
|00000160| 65 20 70 6c 6f 74 74 65 | 64 20 6f 6e 20 73 63 72 |e plotte|d on scr|
|00000170| 65 65 6e 0d 3b 0d 3b 20 | 73 70 72 69 74 65 20 66 |een.;.; |sprite f|
|00000180| 6f 72 6d 61 74 3a 0d 3b | 20 2e 64 62 20 78 53 69 |ormat:.;| .db xSi|
|00000190| 7a 65 2c 20 79 53 69 7a | 65 0d 3b 20 2e 64 62 20 |ze, ySiz|e.; .db |
|000001a0| 73 70 72 69 74 65 20 64 | 61 74 61 0d 3b 20 31 20 |sprite d|ata.; 1 |
|000001b0| 62 69 74 73 20 61 72 65 | 20 62 6c 61 63 6b 20 70 |bits are| black p|
|000001c0| 69 78 65 6c 73 2c 20 30 | 20 62 69 74 73 20 61 72 |ixels, 0| bits ar|
|000001d0| 65 20 77 68 69 74 65 0d | 3b 20 73 6f 20 25 31 31 |e white.|; so %11|
|000001e0| 31 31 30 30 30 30 20 69 | 73 20 34 20 62 6c 61 63 |110000 i|s 4 blac|
|000001f0| 6b 20 70 69 78 65 6c 73 | 2c 20 74 68 65 6e 20 34 |k pixels|, then 4|
|00000200| 20 77 68 69 74 65 0d 3b | 0d 3b 20 6d 61 73 6b 20 | white.;|.; mask |
|00000210| 61 6e 64 20 64 61 74 61 | 20 61 72 65 20 73 61 6d |and data| are sam|
|00000220| 65 20 73 69 7a 65 0d 3b | 20 78 53 69 7a 65 20 69 |e size.;| xSize i|
|00000230| 73 20 74 68 65 20 6e 75 | 6d 62 65 72 20 6f 66 20 |s the nu|mber of |
|00000240| 62 79 74 65 73 20 77 69 | 64 65 20 79 6f 75 72 20 |bytes wi|de your |
|00000250| 73 70 72 69 74 65 20 69 | 73 0d 3b 20 79 53 69 7a |sprite i|s.; ySiz|
|00000260| 65 20 69 73 20 74 68 65 | 20 68 65 69 67 68 74 0d |e is the| height.|
|00000270| 3b 0d 3b 20 4f 70 74 69 | 6d 69 7a 61 74 69 6f 6e |;.; Opti|mization|
|00000280| 73 3a 0d 3b 20 69 66 20 | 61 20 7a 65 72 6f 20 62 |s:.; if |a zero b|
|00000290| 79 74 65 20 69 73 20 65 | 6e 63 6f 75 6e 74 65 72 |yte is e|ncounter|
|000002a0| 65 64 2c 20 69 74 20 69 | 73 20 73 6b 69 70 70 65 |ed, it i|s skippe|
|000002b0| 64 20 28 69 65 20 2e 64 | 62 20 25 30 30 30 30 30 |d (ie .d|b %00000|
|000002c0| 30 30 30 29 0d 3b 0d 3b | 20 4f 74 68 65 72 20 6e |000).;.;| Other n|
|000002d0| 6f 74 65 73 3a 20 63 61 | 7a 20 77 69 6c 6c 20 63 |otes: ca|z will c|
|000002e0| 6f 6d 70 69 6c 65 20 74 | 68 69 73 20 77 69 74 68 |ompile t|his with|
|000002f0| 20 6e 6f 20 63 6f 6d 70 | 6c 61 69 6e 74 73 0d 3b | no comp|laints.;|
|00000300| 20 56 65 72 73 69 6f 6e | 20 68 69 73 74 6f 72 79 | Version| history|
|00000310| 3a 0d 3b 20 2d 20 4e 6f | 76 20 31 38 2f 39 37 20 |:.; - No|v 18/97 |
|00000320| 76 65 72 73 2e 20 31 3a | 20 69 6e 69 74 69 61 6c |vers. 1:| initial|
|00000330| 20 72 65 6c 61 73 65 0d | 3b 0d 3b 20 49 66 20 79 | relase.|;.; If y|
|00000340| 6f 75 20 75 73 65 20 74 | 68 69 73 2c 20 67 69 6d |ou use t|his, gim|
|00000350| 6d 65 20 63 72 65 64 69 | 74 20 73 6f 6d 65 77 68 |me credi|t somewh|
|00000360| 65 72 65 0d 3b 0d 0d 53 | 70 72 69 74 65 42 6c 69 |ere.;..S|priteBli|
|00000370| 74 74 3a 0d 20 6c 64 20 | 61 2c 20 36 33 0d 20 73 |tt:. ld |a, 63. s|
|00000380| 75 62 20 63 0d 20 6c 64 | 20 63 2c 20 61 0d 20 70 |ub c. ld| c, a. p|
|00000390| 75 73 68 20 68 6c 0d 20 | 43 41 4c 4c 20 52 4f 4d |ush hl. |CALL ROM|
|000003a0| 5f 43 41 4c 4c 0d 20 2e | 64 77 20 46 49 4e 44 5f |_CALL. .|dw FIND_|
|000003b0| 50 49 58 45 4c 0d 20 6c | 64 20 64 65 2c 20 56 49 |PIXEL. l|d de, VI|
|000003c0| 44 45 4f 5f 4d 45 4d 0d | 20 61 64 64 20 68 6c 2c |DEO_MEM.| add hl,|
|000003d0| 20 64 65 0d 20 70 6f 70 | 20 64 65 0d 20 65 78 20 | de. pop| de. ex |
|000003e0| 64 65 2c 20 68 6c 0d 20 | 6c 64 20 62 2c 20 28 68 |de, hl. |ld b, (h|
|000003f0| 6c 29 0d 20 69 6e 63 20 | 68 6c 0d 20 6c 64 20 63 |l). inc |hl. ld c|
|00000400| 2c 20 28 68 6c 29 0d 20 | 69 6e 63 20 68 6c 0d 20 |, (hl). |inc hl. |
|00000410| 70 75 73 68 20 68 6c 0d | 20 70 6f 70 20 69 78 0d |push hl.| pop ix.|
|00000420| 20 65 78 20 64 65 2c 20 | 68 6c 0d 76 4c 6f 6f 70 | ex de, |hl.vLoop|
|00000430| 3a 0d 20 70 75 73 68 20 | 62 63 0d 20 70 75 73 68 |:. push |bc. push|
|00000440| 20 68 6c 0d 68 4c 6f 6f | 70 3a 0d 20 70 75 73 68 | hl.hLoo|p:. push|
|00000450| 20 62 63 0d 20 6c 64 20 | 62 2c 20 38 0d 20 6c 64 | bc. ld |b, 8. ld|
|00000460| 20 63 2c 20 61 0d 20 6c | 64 20 61 2c 20 28 69 78 | c, a. l|d a, (ix|
|00000470| 2b 30 29 0d 20 6f 72 20 | 61 0d 20 6a 72 20 6e 7a |+0). or |a. jr nz|
|00000480| 2c 20 62 69 74 4c 6f 6f | 70 0d 20 69 6e 63 20 68 |, bitLoo|p. inc h|
|00000490| 6c 0d 20 6a 72 20 6e 6f | 44 61 74 61 0d 62 69 74 |l. jr no|Data.bit|
|000004a0| 4c 6f 6f 70 3a 0d 20 62 | 69 74 20 37 2c 20 61 0d |Loop:. b|it 7, a.|
|000004b0| 20 70 75 73 68 20 61 66 | 0d 20 6c 64 20 61 2c 20 | push af|. ld a, |
|000004c0| 63 0d 20 6a 72 20 7a 2c | 20 77 68 69 74 65 0d 20 |c. jr z,| white. |
|000004d0| 6f 72 20 28 68 6c 29 0d | 20 6a 72 20 73 65 74 50 |or (hl).| jr setP|
|000004e0| 69 78 65 6c 0d 77 68 69 | 74 65 3a 0d 20 78 6f 72 |ixel.whi|te:. xor|
|000004f0| 20 30 78 46 46 0d 20 61 | 6e 64 20 28 68 6c 29 0d | 0xFF. a|nd (hl).|
|00000500| 73 65 74 50 69 78 65 6c | 3a 0d 20 6c 64 20 28 68 |setPixel|:. ld (h|
|00000510| 6c 29 2c 20 61 0d 20 70 | 6f 70 20 61 66 0d 20 73 |l), a. p|op af. s|
|00000520| 72 6c 20 63 0d 20 6a 72 | 20 6e 63 2c 20 6e 6f 52 |rl c. jr| nc, noR|
|00000530| 65 73 65 74 0d 20 6c 64 | 20 63 2c 20 25 31 30 30 |eset. ld| c, %100|
|00000540| 30 30 30 30 30 0d 20 69 | 6e 63 20 68 6c 0d 6e 6f |00000. i|nc hl.no|
|00000550| 52 65 73 65 74 3a 0d 20 | 72 6c 20 61 0d 64 6a 6e |Reset:. |rl a.djn|
|00000560| 7a 20 62 69 74 4c 6f 6f | 70 0d 6e 6f 44 61 74 61 |z bitLoo|p.noData|
|00000570| 3a 0d 6c 64 20 61 2c 20 | 63 0d 70 6f 70 20 62 63 |:.ld a, |c.pop bc|
|00000580| 0d 69 6e 63 20 64 65 0d | 69 6e 63 20 69 78 0d 64 |.inc de.|inc ix.d|
|00000590| 6a 6e 7a 20 68 4c 6f 6f | 70 0d 70 6f 70 20 68 6c |jnz hLoo|p.pop hl|
|000005a0| 0d 70 75 73 68 20 64 65 | 0d 6c 64 20 64 65 2c 20 |.push de|.ld de, |
|000005b0| 31 36 0d 61 64 64 20 68 | 6c 2c 20 64 65 0d 70 6f |16.add h|l, de.po|
|000005c0| 70 20 64 65 0d 70 6f 70 | 20 62 63 0d 64 65 63 20 |p de.pop| bc.dec |
|000005d0| 63 0d 6a 72 20 6e 7a 2c | 20 76 4c 6f 6f 70 0d 72 |c.jr nz,| vLoop.r|
|000005e0| 65 74 0d 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |et......|........|
|000005f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000600| 00 00 01 00 00 00 01 1a | 00 00 00 1a 00 00 00 32 |........|.......2|
|00000610| 3d 7c f0 60 ff b2 70 ff | b0 78 0b ac 56 c3 44 03 |=|.`..p.|.x..V.D.|
|00000620| 1d 43 ff b4 30 38 0b ac | 1d 40 ff b5 42 6e ff b8 |.C..08..|.@..Bn..|
|00000630| 0f 53 70 72 69 74 65 42 | 6c 69 74 74 2e 61 73 6d |.SpriteB|litt.asm|
|00000640| 02 00 02 00 54 45 58 54 | 74 74 78 74 01 00 00 a2 |....TEXT|ttxt....|
|00000650| 02 00 54 45 58 54 74 74 | 78 74 01 00 00 a2 00 57 |..TEXTtt|xt.....W|
|00000660| 00 00 00 00 00 00 00 00 | 00 00 80 00 00 00 00 00 |........|........|
|00000670| 00 00 b1 52 ff 68 00 00 | 05 63 00 00 01 4c 00 04 |...R.h..|.c...L..|
|00000680| 70 00 2f 00 2f 00 2f 0c | 70 31 ab fc 20 54 70 00 |p./././.|p1.. Tp.|
|00000690| 10 10 0c 00 00 3f 54 4f | 63 06 20 54 10 bc 00 3f |.....?TO|c. T...?|
|000006a0| 20 54 43 ee ff c0 24 48 | 10 12 48 80 52 40 48 c0 | TC...$H|..H.R@H.|
|000006b0| a0 2e 20 4c a0 23 48 6e | ff 9a 70 00 3f 00 55 8f |.. L.#Hn|..p.?.U.|
|000006c0| 70 01 3f 00 3f 3c 7f ff | 20 6e 00 08 2f 28 01 0a |p.?.?<..| n../(..|
|000006d0| 3f 3c 00 08 a9 e7 a8 80 | 48 6e ff 9e 70 62 3f 00 |?<......|Hn..pb?.|
|000006e0| 2f 2e ff 9a 20 6e 00 08 | 2f 28 01 0a 3f 3c 00 58 |/... n..|/(..?<.X|
|000006f0| a9 e7 20 6e 00 08 4a 28 | 00 b4 67 3e 20 0b 67 3a |.. n..J(|..g> .g:|
|00000700| 00 00 00 16 00 01 00 00 | 00 00 00 0b 00 09 00 04 |........|........|
|00000710| 00 00 00 09 00 00 00 00 | 00 00 00 00 01 00 00 00 |........|........|
|00000720| 01 1a 00 00 00 1a 00 00 | 00 32 00 ad d1 d0 21 6c |........|.2....!l|
|00000730| 00 00 00 1c 00 32 00 00 | 73 74 79 6c 00 00 00 0a |.....2..|styl....|
|00000740| 00 80 ff ff 00 00 00 00 | 00 ad d3 a8 00 00 00 00 |........|........|
|00000750| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000760| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000770| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+