Search found 15 matches

by TapamN
Tue Sep 15, 2015 7:56 pm
Forum: Megadrive/Genesis
Topic: Tile streaming engines in games with large tile counts
Replies: 9
Views: 2990

Re: Tile streaming engines in games with large tile counts

Bonus question: If you take a look at tile debug view in Regen whilst the intro FMV is playing, it's empty. Is that a Regen bug or are they doing something particularly clever to draw the FMV? Regen defaults to displaying the tiles using palette 0 (which is all black), but the FMV uses palette 2. C...
by TapamN
Fri Dec 19, 2014 11:20 pm
Forum: Demos
Topic: Mode 7 demo for Genesis/MD
Replies: 56
Views: 40798

Mipmapping is a LOD system for textures. It's primary use is to increase rendering speed (by reducing page breaks in improving cache coherency) and reduces aliasing (by prefiltering the downsamples) on minified texture samples. (This wouldn't help speed up the 68K since it doesn't have a cache, but ...
by TapamN
Fri Dec 19, 2014 6:52 pm
Forum: Demos
Topic: Mode 7 demo for Genesis/MD
Replies: 56
Views: 40798

Maybe some kind of mipmapping-like technique could be used to reduce the memory usage? Instead of having the large range, full detail 256*256 map, you can have one small range, full detail 128*128 texture for the area near the camera, and one large range, reduced detail 128*128 texture for the area ...
by TapamN
Fri Dec 19, 2014 1:02 am
Forum: Demos
Topic: Mode 7 demo for Genesis/MD
Replies: 56
Views: 40798

So you're using 64KB of external RAM when there's 64KB of internal RAM? Would it be possible to instead keep the Z80 stopped and store game state in Z80 RAM? With few macros to replace stack operations/subroutine calls/returns with MOVEP-based emulations, it shouldn't be too much of a pain to progra...
by TapamN
Tue Sep 02, 2014 3:52 am
Forum: Demos
Topic: wolfenstein demo for sega genesis
Replies: 361
Views: 178634

Up: Forward
Down: Backwards
Left: Turn left
Right: Turn right
B: Strafe left
C: Strafe right
X: Toggle run
Y: Switch weapon
Z: Open door
Mode: Shoot

Possibly switch turn and strafe.
by TapamN
Fri Jul 05, 2013 1:12 am
Forum: Super 32X
Topic: 68K to SH2 DMA FIFO
Replies: 10
Views: 8951

Saw this and had some free time, so I put my Dreamcast skills to use. Here is a rather direct pseudo-C translation of the SH2 code: void sub_6001334() { static int dword_600137C = 1; //might be externally modified? or written funny for debugging volatile char *r1a = 0xFFFFFE10; r1a[7] = r1a[7] ^ 2; ...
by TapamN
Fri Mar 01, 2013 11:17 pm
Forum: Megadrive/Genesis
Topic: Genny and 3D
Replies: 138
Views: 46724

If the lines in-between visible columns are transparent, you could display the framebuffer on both layers, with one layer shifted to the left one pixel. That would fill up the space between columns and make it just look like it was stretched horizontally.

http://imgur.com/gNXZpe5
by TapamN
Wed Jul 04, 2012 2:58 pm
Forum: Super 32X
Topic: SuperH Registers Calling Convention
Replies: 4
Views: 6350

Here's a minor thing I've seen missing on all SuperH calling convention docs I've seen. How functions that return a struct work, in something like this: struct thingy { int a,b,c; }; struct thingy InitThingy(int val) { struct thingy newthing = { val, 0, val*2 }; return newthing; } int main() { struc...
by TapamN
Fri Jun 29, 2012 7:22 pm
Forum: Video Display Processor
Topic: show a 256 colors picture in MD
Replies: 21
Views: 16319

On the Beyond3D forums , there was a post by a guy who did late commercial development for the Genesis, and one trick he did research into was turning the screen off, and DMAing onto the background color to get a 9 bit color linear frame buffer. Has anyone tried this? He said that not all pixels we...
by TapamN
Sun Jun 10, 2012 5:53 pm
Forum: Super 32X
Topic: Optimizing background tiles drawn to framebuffer
Replies: 23
Views: 16942

Is the only reason you copy the pixels to a temporary buffer to do clipping? You set the pixels to transparent to prevent them from from appearing on the other side of the screen? You can probably just copy straight to the framebuffer. For the parts that need clipping, adjust the source, destination...
by TapamN
Sun Jun 10, 2012 5:41 pm
Forum: Super 32X
Topic: Notice on differences between emulator colors for 32x
Replies: 4
Views: 5536

Doing unaligned accesses would have crashed on real hardware. The fact that both got to displaying anything means neither are accurate.

It would probably be a good idea for someone to make a version of Gens for development that traps unaligned accesses.
by TapamN
Mon Jun 04, 2012 6:48 pm
Forum: Super 32X
Topic: Optimizing background tiles drawn to framebuffer
Replies: 23
Views: 16942

Mirroring should have negligible overhead. Here's are versions of the copy function that writes the data in reverse order. Use the first one if you're using 16 bit color, and the second one if you're using 8 bit color. ! void _word_8byte_copy_wordreverse(short *dst, short *src, int count) .align 4 ....
by TapamN
Tue May 29, 2012 4:56 pm
Forum: Super 32X
Topic: Optimizing background tiles drawn to framebuffer
Replies: 23
Views: 16942

Oops, I wasn't paying attention to what I had said earlier about aligning memory accesses to long aligned addresses. A slight modification: ! void word_8byte_copy(short *dst, short *src, int count) .align 4 .global _word_8byte_copy _word_8byte_copy: mov.w @r5+,r0 dt r6 mov.w @r5+,r1 !wasted cycle he...
by TapamN
Tue May 29, 2012 2:57 am
Forum: Megadrive/Genesis
Topic: fast way to compute distance between two points?
Replies: 13
Views: 6592

I guess it's a bit late for this, then, but here is an interesting way of calculating approximate distances when you can't use the squared distance (mention by Nemesis): http://www.flipcode.com/archives/Fast_Approximate_Distance_Functions.shtml The example code uses 32-bit operations, but if the dis...
by TapamN
Tue May 29, 2012 2:48 am
Forum: Super 32X
Topic: Optimizing background tiles drawn to framebuffer
Replies: 23
Views: 16942

! Fast wmemcpy function - copies words, runs from sdram for speed ! On entry: r4 = dst, r5 = src, r6 = len (in words) .align 4 .global _fast_wmemcpy _fast_wmemcpy: mov.w @r5+,r3 mov.w r3,@r4 dt r6 bf/s _fast_wmemcpy add #2,r4 rts nop You could make that faster if you swap the DT and second MOV.W in...