Omnimaga

Omnimaga => News => Topic started by: DJ Omnimaga on March 28, 2013, 10:37:17 pm

Title: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on March 28, 2013, 10:37:17 pm
Just now, tr1p1ea has posted the following video on Youtube and OmnomIRC:



This video shows a TI-84 Plus C Silver Edition tile-mapper, featuring scrolling, in the 160x240 resolution mode that Calc84maniac recently discovered (http://ourl.ca/18523). The speed result is very promising! The sprites used in the video are 8x8, with their height scaled up to 16 pixels, but since the calculator is set to 160x240 instead of 320x240, the sprites looks as large as their height.

Hopefully an ASM library that allows TI-BASIC programmers to change the horizontal screen resolution and the display starting position (z-adress) will also be released in the near future, so that those programmers can take advantage of that Atari/Commodore-like mode too!
(http://img.removedfromgame.com/imgs/160pscreentest.png)

This means that fast-paced side scrollers should be very easy to create on Texas Instruments' newly released color calculator.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Sorunome on March 28, 2013, 10:45:47 pm
/me feels honord by being mentioned in that screenie
/me lost
/me thinks it is awesome and this little feature may get him to buy a CSE after all as it s so quick O.o
/me notices that his message only consists out of /me messagges
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: calc84maniac on March 28, 2013, 10:51:54 pm
Note that the scrolling in that video doesn't involve drawing any pixels, by the way. It'll be a bit slower if you want to have a play area wider than two screen widths, since you'll have to actually draw in the new tiles. Should still be relatively fast, though.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: tr1p1ea on March 28, 2013, 11:37:21 pm
The test doesn't do any drawing but it also only processes every 16th frame so there is room to play possibly.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: calc84maniac on March 29, 2013, 12:05:12 am
The test doesn't do any drawing but it also only processes every 16th frame so there is room to play possibly.
I keep wondering, what exactly is a "frame" here. I mean, if all you're doing is changing the scroll registers you can probably get over 9000 FPS, but that doesn't really affect the display which has its own frame rate.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: tr1p1ea on March 29, 2013, 12:14:38 am
Lol I was reluctant to use the word frame because it isn't really correct. Basically instead of scrolling every loop I only change x every 16 loops. The registers are still written to every iteration tho ... just wanted a quick delay *hides*
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on March 29, 2013, 01:33:55 am
Do you think you could do a video showing scrolling where an entire column of tiles is updated every frame? I am curious about how fast it would be. TO make it more accurate, add a Mario sprite, along with 3 enemies and a shroom in the mix, using masking for all.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Ti-Programmer on March 29, 2013, 01:49:21 am
Nice job with the tests.

So does that mean that the 84 CSE games will have levels that are just super-sized images that are zoomed in and scrolled, and the sprites are moved on them?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Streetwalrus on March 29, 2013, 04:21:38 am
That's very nice !
So that's basically GBA resolution. Not bad at all ! I hope we can write fast enough tile map renderers. :)
Do we have that extra space on the vertical axis (for RPGs) ?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: TIfanx1999 on March 29, 2013, 05:14:01 am
you should be able to make arbitrary sized buffers regardless, but the hardware doesnt support vertical scrolling the same way it does horizontal scrolling shown in the video. Vertical scrolling will be slower.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Streetwalrus on March 29, 2013, 08:28:29 am
Arf that's too bad I got oversized hope. :(
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Juju on March 29, 2013, 11:54:24 am
That's pretty cool. Hope lots of GBA-like games gets developed :P
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Keoni29 on March 29, 2013, 12:16:56 pm
Can it also repeat the image and stitch the ends together?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: calc84maniac on March 29, 2013, 12:24:58 pm
Can it also repeat the image and stitch the ends together?
Yep, that's exactly what happens. If you draw tiles offscreen before you reach them, you can pretty much scroll infinitely in the horizontal direction.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Keoni29 on March 29, 2013, 12:26:48 pm
It doesnt look like it though. You see that it's just one image, but it's stretched out to fill multiple screens. You can only scroll within the boundaries of the image in this demo.
Title: Re: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on March 29, 2013, 01:13:39 pm
He probably did that on purpose to avoid scrolling too far in the video.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Augs on March 29, 2013, 01:51:02 pm
Will there be any on calculator programming for this?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: TIfanx1999 on March 29, 2013, 01:56:54 pm
Well, you have BASIC right out of the box.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Augs on March 29, 2013, 02:13:11 pm
And Basic can do this?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: TravisE on March 29, 2013, 03:30:03 pm
Pretty cool. The “half horizontal resolution” mode doesn't look bad at all.

This reminds me that the classic consoles such as the NES actually were quite limited on how many tiles could be updated per frame. They took advantage of having an extra screen-sized buffer, just as in this example (some games didn't even use that) to update rows or columns of tiles off-screen just before they scrolled into view. In this case, there is no direct hardware support for sprites; those would still need to be directly drawn, but if that can be done fast enough, this certainly does look promising, framerate wise. The biggest key here will be how many pixels can be updated per frame, and how much CPU time will be needed by AI and logic.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: TIfanx1999 on March 30, 2013, 12:17:58 am
@Augs:No. That demo is written in asm on a pc.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on March 30, 2013, 12:24:50 am
And Basic can do this?

Since the calc is as fast for math calculations as the 84+SE (only graphics/drawing are slower), I wouldn't be surprised if such speed could be rivaled using ASM libs in a BASIC program (such as xLIB 2?). It wouldn't be as fast with collision detection, of course, but it could be a good alternative to just updating the entire screen every frame.

But yeah, the calc isn't locked down in any way in terms of programming. Of course now you're stuck with a Mathprint OS, but otherwise for programming this calc is an huge contrast with the stance TI took against Ndless on the TI-Nspire.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: Hot_Dog on March 30, 2013, 11:25:32 pm
It's sad how long it takes to actually draw everything before the scrolling :(  Still, great discovery!  If only the vertical part could be cut in half as well!

By the way, what are scrolling registers?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on March 30, 2013, 11:59:10 pm
To be honest I am surprised that the drawing before scrolling is that slow. It seems to me that it's not super optimized or it runs at 6 MHz. Kerm made a demo program once that could redraw the entire screen 4 times a second.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on April 02, 2013, 01:22:34 am
Tr1p1ea made a larger map video now:



Notice how the speed barely changes, except some minor stuttering when it reaches the edge of the screen. Delay had to be removed but speed still looks good. :D

I would like to see a video using 8x16 tiles instead, though, so that it shows its full possible 160x240 res rather than 160x120.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: tr1p1ea on April 02, 2013, 09:01:09 pm
Oops i updated the link to the video to remove the screen artifacts. It can be seen here:

Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on April 02, 2013, 09:44:03 pm
Looks very nice :)
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: chickendude on April 03, 2013, 12:18:43 am
That does look really nice! How much space does all the data take up?

EDIT: Or is the source posted anywhere?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: tr1p1ea on April 03, 2013, 02:04:36 am
The data takes up a bit of space. The map is 168x15 = 2520 bytes. There are 71 8x8 tiles that use 4-bit palette indices packed into nibbles, so its 32 bytes per tile = 2272 bytes.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on April 03, 2013, 02:28:25 am
Is it archived while read?
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: tr1p1ea on April 03, 2013, 02:32:43 am
Since this is only a test it isnt archived, however i have made an image viewer that can read puCrunched 16-colour images from archive.
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DJ Omnimaga on April 03, 2013, 02:41:28 am
Since this is only a test it isnt archived, however i have made an image viewer that can read puCrunched 16-colour images from archive.

Pr0n? O.O

Just kidding, but I remember that Final Fantasy girl pic on calc you posted back in the days :P
Title: Re: 160x240 CSE scrolling speed test gives promising results
Post by: DrDnar on April 03, 2013, 02:44:29 am
I suspect JPEG image decompression is do-able, although it wouldn't be fast, of course.