PB 2.90 for Windows - Optimize InitSprite() ?

Everything else that doesn't fall into one of the other PB categories.
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by MrVainSCL.

Hi Fred!
I checked my executeable files with a hex editor and was a bit wondered, because i found in every file where i use "InitSprite()", a part seems to be a big data-table!? This table will follow after the text "DirectXClass" and sometime be followed by "DISPLAY" ...

Is there really a big (about 5kb) table included to the exe when using InitSprite()? For what kind is this big table? (Screen x,y handling like the table in DISPLAY lib on BlitzAmiga?) - Mhhhh... is there no way to precalc this big table when starting the program...? (just only a question) This would help to make mutch smaller files :wink:)

Btw. why is there sometimes 0-2 times the text "DISPLAY" after "DirectXClass" in the executeable? Is this correct or maybe a small hidden bug? :wink:


PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...

greetz
MrVainSCL! aka Thorsten
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by fred.

Stop to hack my libraries with an hex editor :). You're right, there is a lockuptable to speedup a lot all software blit routines (SpecialFX mode). I will change that.. Hehe.

Fred - AlphaSND
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by MrVainSCL.
Fred wrote:
Stop to hack my libraries with an hex editor :). You're right, there is a lockuptable to speedup a lot all software blit routines (SpecialFX mode). I will change that.. Hehe.
hehe, thanks

PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...

greetz
MrVainSCL! aka Thorsten
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by MrVainSCL.

Hi Fred!
Could you post the new SPRITE() Lib with a precalced table to this forum? I think when you using this methode, the new SPRITE() lib will be only 32 to max. 34kb instead of about 40kb !? Thanks in advance... Keep on ya work...


PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...

greetz
MrVainSCL! aka Thorsten
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by MrVainSCL.
Fred wrote:
Stop to hack my libraries with an hex editor :). You're right, there is a lockuptable to speedup a lot all software blit routines (SpecialFX mode). I will change that.. Hehe.
Hi Fred!
Seems you forgot to add the new changed SpriteLib for PB2.95!? But now after our small talk on IRC i was a bit wondered when you sayed, that you changed it but you dont have any stuff of it anymore... Mhhhh, i am a bit wondered why the table should now only DX based (included by the compiler) and not longer any own lockuptable to speedup the SpecialFX stuff... (maybe we have misunderstand us!? - i dont know)

Anyway it is really not hard to precalculate/generate a lookuptable in realtime... Ok, we have to allocate the size of our table in the file and so we will have no smaller file but somewhere inside the file we have a reserved section filled with $00... Maybe you would like to say that it dont save any memory... But when packing the file you will have a mutch better results... Because a section filled with $00 can be better packed as a big lookuptable... :wink:

Now i will give you a working example of my own precalutated lookuptable i coded/replaced for the original big table (DisplayLib BB Amiga) to get a better packresult... Maybe this will help you...!?
Here is the original table, used in DisplayLib BB Amiga:

Code: Select all

bp1:                                                      ; Label bp1
    Dc.w $FFFF,$EEFF,$DDFF,$CCFF,$FFEE,$EEEE,$DDEE,$CCEE  ; Evtl. Optimieren?
    Dc.w $FFDD,$EEDD,$DDDD,$CCDD,$FFCC,$EECC,$DDCC,$CCCC  ; Tabelle errechen
    Dc.w $FFBB,$EEBB,$DDBB,$CCBB,$FFAA,$EEAA,$DDAA,$CCAA  ; lassen 8^)
    Dc.w $FF99,$EE99,$DD99,$CC99,$FF88,$EE88,$DD88,$CC88
    Dc.w $FF77,$EE77,$DD77,$CC77,$FF66,$EE66,$DD66,$CC66
    Dc.w $FF55,$EE55,$DD55,$CC55,$FF44,$EE44,$DD44,$CC44
    Dc.w $FF33,$EE33,$DD33,$CC33,$FF22,$EE22,$DD22,$CC22
    Dc.w $FF11,$EE11,$DD11,$CC11,$FF00,$EE00,$DD00,$CC00
    Dc.w $BBFF,$AAFF,$99FF,$88FF,$BBEE,$AAEE,$99EE,$88EE
    Dc.w $BBDD,$AADD,$99DD,$88DD,$BBCC,$AACC,$99CC,$88CC
    Dc.w $BBBB,$AABB,$99BB,$88BB,$BBAA,$AAAA,$99AA,$88AA
    Dc.w $BB99,$AA99,$9999,$8899,$BB88,$AA88,$9988,$8888
    Dc.w $BB77,$AA77,$9977,$8877,$BB66,$AA66,$9966,$8866
    Dc.w $BB55,$AA55,$9955,$8855,$BB44,$AA44,$9944,$8844
    Dc.w $BB33,$AA33,$9933,$8833,$BB22,$AA22,$9922,$8822
    Dc.w $BB11,$AA11,$9911,$8811,$BB00,$AA00,$9900,$8800
    Dc.w $77FF,$66FF,$55FF,$44FF,$77EE,$66EE,$55EE,$44EE
    Dc.w $77DD,$66DD,$55DD,$44DD,$77CC,$66CC,$55CC,$44CC
    Dc.w $77BB,$66BB,$55BB,$44BB,$77AA,$66AA,$55AA,$44AA
    Dc.w $7799,$6699,$5599,$4499,$7788,$6688,$5588,$4488
    Dc.w $7777,$6677,$5577,$4477,$7766,$6666,$5566,$4466
    Dc.w $7755,$6655,$5555,$4455,$7744,$6644,$5544,$4444
    Dc.w $7733,$6633,$5533,$4433,$7722,$6622,$5522,$4422
    Dc.w $7711,$6611,$5511,$4411,$7700,$6600,$5500,$4400
    Dc.w $33FF,$22FF,$11FF,$00FF,$33EE,$22EE,$11EE,$00EE
    Dc.w $33DD,$22DD,$11DD,$00DD,$33CC,$22CC,$11CC,$00CC
    Dc.w $33BB,$22BB,$11BB,$00BB,$33AA,$22AA,$11AA,$00AA
    Dc.w $3399,$2299,$1199,$0099,$3388,$2288,$1188,$0088
    Dc.w $3377,$2277,$1177,$0077,$3366,$2266,$1166,$0066
    Dc.w $3355,$2255,$1155,$0055,$3344,$2244,$1144,$0044
    Dc.w $3333,$2233,$1133,$0033,$3322,$2222,$1122,$0022
    Dc.w $3311,$2211,$1111,$0011,$3300,$2200,$1100,$0000
Here is now my replacement to precalculate/generate the DisplayLib table:

Code: Select all

;
;----- Replacement by Mr.Vain - Optimized DisplayTable ----
;
calcTab:
    ;movem.l d0-d7,-(sp)              ; eventuell nicht nötig
    LEA bp1,a0
    MOVEQ #-1,d0
    MOVEQ #34,d6
    MOVEQ #-1,d4
    MOVEQ #16,d3                      ; 21.08.2000 changed
    MOVEQ #-18,d5
loop:
    MOVE.w  d0,d1
    MOVEQ #4-1,d7
loop2:
    MOVE.b  d4,d1
    MOVE.w  d1,(a0)+
    MOVE.b  d5,d1
    MOVE.w  d1,6(a0)
    BEQ.b ende
    SUB.w #$1100,d1
    DBRA  d7,loop2
    ADDQ.l  #8,a0 
    SUB.b d6,d4
    SUB.b d6,d5
    BCC.b d5ok
    ADD.b d3,d4
    ADD.b d3,d5
    SUB.w #$4400,d0
d5ok:
    BRA loop
ende:
    ;movem.l (sp)+,d0-d7  ;eventuell nicht nötig
    RTS
;
;  SECTION mrvainsTable,BSS
;
bp1:
  Ds.b  512                  ; Reserve the space for final precalced table
Now i changed just the InitDisplay() command, when executing this command... it will jump to my routine too and generate the table to bpl1... so it works very fine for me :wink:

Good luck...


PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...

greetz
MrVainSCL! aka Thorsten


Edited by - MrVainSCL on 28 February 2002 23:02:39
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by fred.


The actual tables are generated when the program starts, exactly like your examples. So all is fine. My first post was wrong, I tough the table was hardcoded, but it's not.

Fred - AlphaSND
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by Danilo.

>calcTab:
> ;movem.l d0-d7,-(sp)
> LEA bp1,a0
> MOVEQ #-1,d0

...i thought you write you 32k-game for Windows (x86),
not for Amiga (68k)??

Looks like you mix some things up here, MrVain... :)
Talking about "DirectXClass" and 68k-Assembly in
the same second.... no way.

cya,
...Danilo

(registered PureBasic user)
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by MrVainSCL.
Danilo wrote:
...i thought you write you 32k-game for Windows (x86),
not for Amiga (68k)??

Looks like you mix some things up here, MrVain... :)
Talking about "DirectXClass" and 68k-Assembly in
the same second.... no way.
Hi Danilo
Hehe... you are right... i try to code my first 32k-game for windows... I only explained Fred what i mean and how he could generate/precalc the table... So i send him just an old amiga asm source i coded some time ago to replace an original table that was build in the DisplayLib BB on amiga
Fred wrote:
The actual tables are generated when the program starts, exactly like your examples. So all is fine. My first post was wrong, I tough the table was hardcoded, but it's not.
Hi Fred
If so, it would be nice... but things seeme that not really all is fine I wrote, that the big table can be find after the "DISPLAY" string in an executeable and you wrote that would be your lookuptable... When genertating the tables at programstart, why is there still the big table after "DISPLAY"??

You wrote on the IRC that this table could be DX related, because of inclduding "ddraw.lib" and "dxguid.lib" while compiling... I checked this files and i think there are only some tables inside "dxguid.lib" - but i am not really sure, because i dont know this files/fileformat... I havent find any part of the tables i can find inside my created executeable on the "dxguid.lib"

So i really dont know where are this big (about 7.5 kb) table inside my program will come from and for what stuff/operations it will be there...!? And it dont look like a jumptable or something like this...

Please dont blame me, but i will add the first part of the table i will find everytime when using InitSprite()... There are some different tables build to one big table! The first part would be easy to precalc/generate but this first part need at all 4096 bytes

Here is a small snip of the table you can find in your programs when using InitSprite():
Please tell me, what is this for a table and where it come from? The first table part will be exactly 4k...

Code: Select all

;
;-------- Table Part 1 -------- 
;
    $30024500,$00000000,$0C000080,$00000000
    $30024500,$01000000,$0C010080,$00000000
    $30024500,$02000000,$0C020080,$00000000
    $30024500,$03000000,$0C030080,$00000000
    $30024500,$04000000,$0C040080,$00000000
    $30024500,$05000000,$0C050080,$00000000
    $30024500,$06000000,$0C060080,$00000000
    $30024500,$07000000,$0C070080,$00000000
    $30024500,$08000000,$0C080080,$00000000
    $30024500,$09000000,$0C090080,$00000000
    $30024500,$0A000000,$0C0A0080,$00000000
    $30024500,$0B000000,$0C0B0080,$00000000
    $30024500,$0C000000,$0C0C0080,$00000000
    $30024500,$0D000000,$0C0D0080,$00000000
    $30024500,$0E000000,$0C0E0080,$00000000
    $30024500,$0F000000,$0C0F0080,$00000000
    $30024500,$10000000,$0C100080,$00000000
    $30024500,$11000000,$0C110080,$00000000
    $30024500,$12000000,$0C120080,$00000000
    $30024500,$13000000,$0C130080,$00000000
    $30024500,$14000000,$0C140080,$00000000
    $30024500,$15000000,$0C150080,$00000000
    $30024500,$16000000,$0C160080,$00000000
    $30024500,$17000000,$0C170080,$00000000
    $30024500,$18000000,$0C180080,$00000000
    $30024500,$19000000,$0C190080,$00000000
    $30024500,$1A000000,$0C1A0080,$00000000
    $30024500,$1B000000,$0C1B0080,$00000000
    $30024500,$1C000000,$0C1C0080,$00000000
    $30024500,$1D000000,$0C1D0080,$00000000
    $30024500,$1E000000,$0C1E0080,$00000000
    $30024500,$1F000000,$0C1F0080,$00000000
    $30024500,$20000000,$0C200080,$00000000
    $30024500,$21000000,$0C210080,$00000000
    $30024500,$22000000,$0C220080,$00000000
    $30024500,$23000000,$0C230080,$00000000
    $30024500,$24000000,$0C240080,$00000000
    $30024500,$25000000,$0C250080,$00000000
    $30024500,$26000000,$0C260080,$00000000
    $30024500,$27000000,$0C270080,$00000000
    $30024500,$28000000,$0C280080,$00000000
    $30024500,$29000000,$0C290080,$00000000
    $30024500,$2A000000,$0C2A0080,$00000000
    $30024500,$2B000000,$0C2B0080,$00000000
    $30024500,$2C000000,$0C2C0080,$00000000
    $30024500,$2D000000,$0C2D0080,$00000000
    $30024500,$2E000000,$0C2E0080,$00000000
    $30024500,$2F000000,$0C2F0080,$00000000
    $30024500,$30000000,$0C300080,$00000000
    $30024500,$31000000,$0C310080,$00000000
    $30024500,$32000000,$0C320080,$00000000
    $30024500,$33000000,$0C330080,$00000000
    $30024500,$34000000,$0C340080,$00000000
    $30024500,$35000000,$0C350080,$00000000
    $30024500,$36000000,$0C360080,$00000000
    $30024500,$37000000,$0C370080,$00000000
    $30024500,$38000000,$0C380080,$00000000
    $30024500,$39000000,$0C390080,$00000000
    $30024500,$3A000000,$0C3A0080,$00000000
    $30024500,$3B000000,$0C3B0080,$00000000
    $30024500,$3C000000,$0C3C0080,$00000000
    $30024500,$3D000000,$0C3D0080,$00000000
    $30024500,$3E000000,$0C3E0080,$00000000
    $30024500,$3F000000,$0C3F0080,$00000000
    $30024500,$40000000,$0C400080,$00000000
    $30024500,$41000000,$0C410080,$00000000
    $30024500,$42000000,$0C420080,$00000000
    $30024500,$43000000,$0C430080,$00000000
    $30024500,$44000000,$0C440080,$00000000
    $30024500,$45000000,$0C450080,$00000000
    $30024500,$46000000,$0C460080,$00000000
    $30024500,$47000000,$0C470080,$00000000
    $30024500,$48000000,$0C480080,$00000000
    $30024500,$49000000,$0C490080,$00000000
    $30024500,$4A000000,$0C4A0080,$00000000
    $30024500,$4B000000,$0C4B0080,$00000000
    $30024500,$4C000000,$0C4C0080,$00000000
    $30024500,$4D000000,$0C4D0080,$00000000
    $30024500,$4E000000,$0C4E0080,$00000000
    $30024500,$4F000000,$0C4F0080,$00000000
    $30024500,$50000000,$0C500080,$00000000
    $30024500,$51000000,$0C510080,$00000000
    $30024500,$52000000,$0C520080,$00000000
    $30024500,$53000000,$0C530080,$00000000
    $30024500,$54000000,$0C540080,$00000000
    $30024500,$55000000,$0C550080,$00000000
    $30024500,$56000000,$0C560080,$00000000
    $30024500,$57000000,$0C570080,$00000000
    $30024500,$58000000,$0C580080,$00000000
    $30024500,$59000000,$0C590080,$00000000
    $30024500,$5A000000,$0C5A0080,$00000000
    $30024500,$5B000000,$0C5B0080,$00000000
    $30024500,$5C000000,$0C5C0080,$00000000
    $30024500,$5D000000,$0C5D0080,$00000000
    $30024500,$5E000000,$0C5E0080,$00000000
    $30024500,$5F000000,$0C5F0080,$00000000
    $30024500,$60000000,$0C600080,$00000000
    $30024500,$61000000,$0C610080,$00000000
    $30024500,$62000000,$0C620080,$00000000
    $30024500,$63000000,$0C630080,$00000000
    $30024500,$64000000,$0C640080,$00000000
    $30024500,$65000000,$0C650080,$00000000
    $30024500,$66000000,$0C660080,$00000000
    $30024500,$67000000,$0C670080,$00000000
    $30024500,$68000000,$0C680080,$00000000
    $30024500,$69000000,$0C690080,$00000000
    $30024500,$6A000000,$0C6A0080,$00000000
    $30024500,$6B000000,$0C6B0080,$00000000
    $30024500,$6C000000,$0C6C0080,$00000000
    $30024500,$6D000000,$0C6D0080,$00000000
    $30024500,$6E000000,$0C6E0080,$00000000
    $30024500,$6F000000,$0C6F0080,$00000000
    $30024500,$70000000,$0C700080,$00000000
    $30024500,$71000000,$0C710080,$00000000
    $30024500,$72000000,$0C720080,$00000000
    $30024500,$73000000,$0C730080,$00000000
    $30024500,$74000000,$0C740080,$00000000
    $30024500,$75000000,$0C750080,$00000000
    $30024500,$76000000,$0C760080,$00000000
    $30024500,$77000000,$0C770080,$00000000
    $30024500,$78000000,$0C780080,$00000000
    $30024500,$79000000,$0C790080,$00000000
    $30024500,$7A000000,$0C7A0080,$00000000
    $30024500,$7B000000,$0C7B0080,$00000000
    $30024500,$7C000000,$0C7C0080,$00000000
    $30024500,$7D000000,$0C7D0080,$00000000
    $30024500,$7E000000,$0C7E0080,$00000000
    $30024500,$7F000000,$0C7F0080,$00000000
    $30024500,$80000000,$0C800080,$00000000
    $30024500,$81000000,$0C810080,$00000000
    $30024500,$82000000,$0C820080,$00000000
    $30024500,$83000000,$0C830080,$00000000
    $30024500,$84000000,$0C840080,$00000000
    $30024500,$85000000,$0C850080,$00000000
    $30024500,$86000000,$0C860080,$00000000
    $30024500,$87000000,$0C870080,$00000000
    $30024500,$88000000,$0C880080,$00000000
    $30024500,$89000000,$0C890080,$00000000
    $30024500,$8A000000,$0C8A0080,$00000000
    $30024500,$8B000000,$0C8B0080,$00000000
    $30024500,$8C000000,$0C8C0080,$00000000
    $30024500,$8D000000,$0C8D0080,$00000000
    $30024500,$8E000000,$0C8E0080,$00000000
    $30024500,$8F000000,$0C8F0080,$00000000
    $30024500,$90000000,$0C900080,$00000000
    $30024500,$91000000,$0C910080,$00000000
    $30024500,$92000000,$0C920080,$00000000
    $30024500,$93000000,$0C930080,$00000000
    $30024500,$94000000,$0C940080,$00000000
    $30024500,$95000000,$0C950080,$00000000
    $30024500,$96000000,$0C960080,$00000000
    $30024500,$97000000,$0C970080,$00000000
    $30024500,$98000000,$0C980080,$00000000
    $30024500,$99000000,$0C990080,$00000000
    $30024500,$9A000000,$0C9A0080,$00000000
    $30024500,$9B000000,$0C9B0080,$00000000
    $30024500,$9C000000,$0C9C0080,$00000000
    $30024500,$9D000000,$0C9D0080,$00000000
    $30024500,$9E000000,$0C9E0080,$00000000
    $30024500,$9F000000,$0C9F0080,$00000000
    $30024500,$A0000000,$0CA00080,$00000000
    $30024500,$A1000000,$0CA10080,$00000000
    $30024500,$A2000000,$0CA20080,$00000000
    $30024500,$A3000000,$0CA30080,$00000000
    $30024500,$A4000000,$0CA40080,$00000000
    $30024500,$A5000000,$0CA50080,$00000000
    $30024500,$A6000000,$0CA60080,$00000000
    $30024500,$A7000000,$0CA70080,$00000000
    $30024500,$A8000000,$0CA80080,$00000000
    $30024500,$A9000000,$0CA90080,$00000000
    $30024500,$AA000000,$0CAA0080,$00000000
    $30024500,$AB000000,$0CAB0080,$00000000
    $30024500,$AC000000,$0CAC0080,$00000000
    $30024500,$AD000000,$0CAD0080,$00000000
    $30024500,$AE000000,$0CAE0080,$00000000
    $30024500,$AF000000,$0CAF0080,$00000000
    $30024500,$B0000000,$0CB00080,$00000000
    $30024500,$B1000000,$0CB10080,$00000000
    $30024500,$B2000000,$0CB20080,$00000000
    $30024500,$B3000000,$0CB30080,$00000000
    $30024500,$B4000000,$0CB40080,$00000000
    $30024500,$B5000000,$0CB50080,$00000000
    $30024500,$B6000000,$0CB60080,$00000000
    $30024500,$B7000000,$0CB70080,$00000000
    $30024500,$B8000000,$0CB80080,$00000000
    $30024500,$B9000000,$0CB90080,$00000000
    $30024500,$BA000000,$0CBA0080,$00000000
    $30024500,$BB000000,$0CBB0080,$00000000
    $30024500,$BC000000,$0CBC0080,$00000000
    $30024500,$BD000000,$0CBD0080,$00000000
    $30024500,$BE000000,$0CBE0080,$00000000
    $30024500,$BF000000,$0CBF0080,$00000000
    $30024500,$C0000000,$0CC00080,$00000000
    $30024500,$C1000000,$0CC10080,$00000000
    $30024500,$C2000000,$0CC20080,$00000000
    $30024500,$C3000000,$0CC30080,$00000000
    $30024500,$C4000000,$0CC40080,$00000000
    $30024500,$C5000000,$0CC50080,$00000000
    $30024500,$C6000000,$0CC60080,$00000000
    $30024500,$C7000000,$0CC70080,$00000000
    $30024500,$C8000000,$0CC80080,$00000000
    $30024500,$C9000000,$0CC90080,$00000000
    $30024500,$CA000000,$0CCA0080,$00000000
    $30024500,$CB000000,$0CCB0080,$00000000
    $30024500,$CC000000,$0CCC0080,$00000000
    $30024500,$CD000000,$0CCD0080,$00000000
    $30024500,$CE000000,$0CCE0080,$00000000
    $30024500,$CF000000,$0CCF0080,$00000000
    $30024500,$D0000000,$0CD00080,$00000000
    $30024500,$D1000000,$0CD10080,$00000000
    $30024500,$D2000000,$0CD20080,$00000000
    $30024500,$D3000000,$0CD30080,$00000000
    $30024500,$D4000000,$0CD40080,$00000000
    $30024500,$D5000000,$0CD50080,$00000000
    $30024500,$D6000000,$0CD60080,$00000000
    $30024500,$D7000000,$0CD70080,$00000000
    $30024500,$D8000000,$0CD80080,$00000000
    $30024500,$D9000000,$0CD90080,$00000000
    $30024500,$DA000000,$0CDA0080,$00000000
    $30024500,$DB000000,$0CDB0080,$00000000
    $30024500,$DC000000,$0CDC0080,$00000000
    $30024500,$DD000000,$0CDD0080,$00000000
    $30024500,$DE000000,$0CDE0080,$00000000
    $30024500,$DF000000,$0CDF0080,$00000000
    $30024500,$E0000000,$0CE00080,$00000000
    $30024500,$E1000000,$0CE10080,$00000000
    $30024500,$E2000000,$0CE20080,$00000000
    $30024500,$E3000000,$0CE30080,$00000000
    $30024500,$E4000000,$0CE40080,$00000000
    $30024500,$E5000000,$0CE50080,$00000000
    $30024500,$E6000000,$0CE60080,$00000000
    $30024500,$E7000000,$0CE70080,$00000000
    $30024500,$E8000000,$0CE80080,$00000000
    $30024500,$E9000000,$0CE90080,$00000000
    $30024500,$EA000000,$0CEA0080,$00000000
    $30024500,$EB000000,$0CEB0080,$00000000
    $30024500,$EC000000,$0CEC0080,$00000000
    $30024500,$ED000000,$0CED0080,$00000000
    $30024500,$EE000000,$0CEE0080,$00000000
    $30024500,$EF000000,$0CEF0080,$00000000
    $30024500,$F0000000,$0CF00080,$00000000
    $30024500,$F1000000,$0CF10080,$00000000
    $30024500,$F2000000,$0CF20080,$00000000
    $30024500,$F3000000,$0CF30080,$00000000
    $30024500,$F4000000,$0CF40080,$00000000
    $30024500,$F5000000,$0CF50080,$00000000
    $30024500,$F6000000,$0CF60080,$00000000
    $30024500,$F7000000,$0CF70080,$00000000
    $30024500,$F8000000,$0CF80080,$00000000
    $30024500,$F9000000,$0CF90080,$00000000
    $30024500,$FA000000,$0CFA0080,$00000000
    $30024500,$FB000000,$0CFB0080,$00000000
    $30024500,$FC000000,$0CFC0080,$00000000
    $30024500,$FD000000,$0CFD0080,$00000000
    $30024500,$FE000000,$0CFE0080,$00000000
    $30024500,$FF000000,$0CFF0080,$00000000
    ;
    ;-------- Continue with Table Part 2 --------
    ;
    $B0024500,$00000000,$03FFFF80,$00010000
    $A0024500,$04000000,$03FFFF80,$00010000
    $90024500,$08000000,$03FFFF80,$00010000
    $80024500,$0C000000,$03FFFF80,$00010000
    $70024500,$10000000,$03FFFF80,$00010000
    $60024500,$14000000,$03FFFF80,...
Ok, hope someone can find out what the hell is with this big table... Because it would not be hard to precalculate all this stuff... This way would save us a some us some space when packing the files...

bye... [sorry, but me is a bit fustrated and demotivated]


PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...

greetz
MrVainSCL! aka Thorsten
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by MrVainSCL.

Hi Fred and Danilo
I cant sleep and so i played a bit around with the big table in my game project... My game is nearly finished (only some small parts to add/fix) - At the moment, my game will be excatly 33.824 bytes! And here stops all my optimisations tricks to get the game in only 32k ;((

I tried just for fun to use a HexEditor and overwrite the complete table in my game with $00 - only to see what happen and what this would save (without this really big table) ... Seems that the exe need the table... because when i tried to start my hacked version, InitSprite() failed and my requester was shown and the prog ended without any problems... Mhhhh... Why failied InitSprite() when this table section is filled with $00 ???

When we could find where the table will come from and try to precalc this, it would make my 32k-game possible :wink: I packed the hacked version and the game was now only 32.288 bytes... *wow*

Only in fact of this table stuff, i cant continue/finish my game until eastern in just only 32 k ;-(

Please, if you know any idea how to replace this table... please help me... THANKS!
This would give me the full motivation back to bring you at eastern the complete game! :wink:

Many thanks for all, who want help me now... bye

PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...

greetz
MrVainSCL! aka Thorsten
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by blueb.

Thorsten,
Isn't 32k equal to 32768 bytes?
Seems like 32288 bytes fits inside 32k to me.

Regards,
--Bob
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by MrVainSCL.
blueb wrote:
Thorsten,
Isn't 32k equal to 32768 bytes?
Seems like 32288 bytes fits inside 32k to me.
Hi blueb
Yes, you are right... 32k are exactly 32768 bytes... Maybe you have read that i have a hacked version of my game and this hacked version (tables are just replaced by $00) does not work... So i still have a version smaller 32k but this dont work :wink:

The working version of my game (with all this big tables inside) is 33.824 bytes ;-( So i still need a way to remove this damn tables out of my game (precalculation would be so easy) Bye :wink:

PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...

greetz
MrVainSCL! aka Thorsten


Edited by - MrVainSCL on 01 March 2002 14:12:18
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by DarkUni.

Hey Fred ...

I was hacking on your car with a Hex Editor .... I found a couple things...

First, your air filter is dirty - change that bad boy ... We're talking 5% better fuel efficiency here...

I noticed some carbon buildup on cylinder 3. If you don't get that taken off soon, your walls are likely to crack.

Oh, and you must've dropped a piece of cheeseburger under the seat. You know that feeling of things crawling on you while you drive? Its not just a feeling. The ants have moved in.

heh ...

Shane R. Monroe, Dark Unicorn Productions
Pure Basic Basement
http://pb.darkunicornproductions.com
Post Reply