| View previous topic :: View next topic |
| Author |
Message |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
|
| Back to top |
|
 |
Chilly Willy Very interested
Joined: 17 Aug 2007 Posts: 1956
|
Posted: Sat Aug 18, 2012 7:50 pm Post subject: Re: BadApple... again :) |
|
|
Uhhhh - no, we can't.  |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Sat Aug 18, 2012 7:53 pm Post subject: |
|
|
err :-/ stupid french share stuff
I'll try to find another one. |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Sat Aug 18, 2012 7:57 pm Post subject: |
|
|
| Dropbox link... far better. |
|
| Back to top |
|
 |
Chilly Willy Very interested
Joined: 17 Aug 2007 Posts: 1956
|
Posted: Sat Aug 18, 2012 8:23 pm Post subject: |
|
|
That's better!
Well, it's looking good - now you just have to get the speed up a bit. nice job on the compression - getting it to look decent and fit in 4M is no easy task. |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Sat Aug 18, 2012 10:32 pm Post subject: |
|
|
Yeah as you said, getting that fit in 4 MB was a hard task
But now it need more speed, hopefully there is room for that ! |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Sun Aug 19, 2012 7:59 pm Post subject: |
|
|
New version :
https://dl.dropbox.com/u/93332624/dev/megadrive/demo/BadApple2.bin
Speed is a bit better (not that much) but at least i fixed last bugs. The video is not anymore choppy and buggy in some place
I am still in C but even with ASM i will need very important optimizations to get things at correct speed. |
|
| Back to top |
|
 |
Chilly Willy Very interested
Joined: 17 Aug 2007 Posts: 1956
|
Posted: Mon Aug 20, 2012 12:11 am Post subject: |
|
|
It's definitely better. It's usually best to work out the bugs, THEN work on the speed.  |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Mon Aug 20, 2012 7:42 am Post subject: |
|
|
Yep, now i can work at 100% on optimizations  |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Sat Sep 01, 2012 11:12 pm Post subject: |
|
|
Again a new version :
https://dl.dropbox.com/u/93332624/dev/megadrive/demo/BadApple4.bin
I passed almost all the tile unpack algo to ASM code.
Unfortunately that is still too slow :-/
I do not see much more room for big improvements now...
~600000 tiles on the total 850000 tiles are packed with dictionary method.
Unfortunately the dictionary unpack code is the more complex and slowest one : i believe that i have 20% to 70% of CPU time (depending the frame complexity) eat in that code.
I profiled time to unpack a single 2bpp tile with dictionary method : 5 to 16 scanlines (close to 8000 cycles in worst case) ! And we can have 250 tiles to unpack per frame. I think i should find a simpler unpacking method :p |
|
| Back to top |
|
 |
Chilly Willy Very interested
Joined: 17 Aug 2007 Posts: 1956
|
Posted: Sat Sep 01, 2012 11:23 pm Post subject: |
|
|
| The speed on the latest is actually rather good. While it's still slow on large changes, it's not THAT slow - just not real-time. There are packing schemes that are very fast depacking... of course, the tradeoff is usually space. You won't know until you try. |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Sun Sep 02, 2012 12:11 am Post subject: |
|
|
Yeah speed is much better in the last version, basically because i moved to ASM all "bitstream" code (read a buffer bit per bit) which is used everywhere as well as the tile unpack code. Some others parts can be ported to ASM but there are not the bottleneck so i don't bother with them...
As you said all the problem is to find the good trade off between speed and space. I will try to find how i can simplify compression code without sacrificing too much space... There are always ways to do better :p |
|
| Back to top |
|
 |
ammianus Very interested
Joined: 29 Jan 2012 Posts: 120 Location: North America
|
Posted: Sun Sep 02, 2012 1:13 pm Post subject: |
|
|
| Wow that is awesome stuff. Hats off to you. |
|
| Back to top |
|
 |
Stef Very interested

Joined: 30 Nov 2006 Posts: 1257 Location: France - Sevres
|
Posted: Sun Sep 02, 2012 7:08 pm Post subject: |
|
|
Hehe thanks
I have to admit that i already spent many time in that small demo, i really hope to get it up to the end  |
|
| Back to top |
|
 |
|