Jump to content
IGNORED

Rescue - 3D engine demo


R0ger

Recommended Posts

My only thought is that as its scripted what would a game run like under the engine in real time.

 

I do realise that its released as a proof of concept and NOT a game but how would it perform in real time?

 

Don't get me wrong, I love new releases be they state of the art, BASIC or other, for me it just proves that there's life in the old dog yet ...But lets remember its released purely under the 'demo' category in every sense..

Link to comment
Share on other sites

 

No reason to speculate when you can measure it directly in Altirra:

 

attachicon.gifdma.png

 

Looks pretty optimal to me. PMG DMA is disabled. Only two LMS are used. Using narrow mode could save a good chunk of cycles but is it worth it?

 

Hi Xuel, could you explain how and what the picture means apart from the brief text you added...And how you made that image..

 

Sorry, trying to learn for m the pro's...

Link to comment
Share on other sites

Looks pretty optimal to me. PMG DMA is disabled. Only two LMS are used. Using narrow mode could save a good chunk of cycles but is it worth it?

In the text region, it could save some cycles, to reduce the size to the needed information.

I wonder how fast it is with the one bit mode.

Link to comment
Share on other sites

 

Hi Xuel, could you explain how and what the picture means apart from the brief text you added...And how you made that image..

 

Sorry, trying to learn for m the pro's...

 

You can enable DMA analysis mode by hitting Shift-F8. This brings up an overlay that shows you every cycle that SALLY (the 6502 CPU) is blocked by ANTIC DMA. The strip down the left shows you where ANTIC fetches its next instruction. It's also where the operand to that instruction will be fetched. Those are the three longer dots just to the right of the strip. This area will also show PMG DMA if enabled. In the main display area, ANTIC fetches the graphics data. For mode D, as used for the upper display, ANTIC reuses the line buffer every other line, so you get DMA-free lines every other line. For character modes, like the mode 2 text on the lower display, ANTIC has to fetch the symbols and graphics data on "bad lines". You can see those as solid lines every 8 scan lines.

 

EDIT: Oh yeah, and the 9 vertical lines that extend the full height of the screen are where ANTIC does RAM refresh. These cannot be disabled except on bad lines.

Edited by Xuel
  • Like 1
Link to comment
Share on other sites

Thre is no real reason, because, as I said, it is a bug (which on 6502 turns out to be harmless because of the address space wrapping).

Why are you calling it a bug? It's normal use of instruction. It's not the programmer's fault that someone modified original HW on which it runs flawlessly.

Link to comment
Share on other sites

Why are you calling it a bug? It's normal use of instruction. It's not the programmer's fault that someone modified original HW on which it runs flawlessly.

At some other occasion I looked at the source code of the replayer (it was RMT replay routine IIRC), and yes, with the given compile-time parameters the assembler output which generates the negative address is unexpected and certainly unintended (remember that it only occurs when one locates replayer variables at a lower point than certain place at page 0, and IIRC it was "lower than adr $08"). So it works by accident and therefore I call it a bug. Such hidden bugs usually show when the running environment is somewhat different than author's machine and this is the case IMHO.

  • Like 1
Link to comment
Share on other sites

My only thought is that as its scripted what would a game run like under the engine in real time.

 

I do realise that its released as a proof of concept and NOT a game but how would it perform in real time?

 

Don't get me wrong, I love new releases be they state of the art, BASIC or other, for me it just proves that there's life in the old dog yet ...But lets remember its released purely under the 'demo' category in every sense..

 

Well it is all realtime, drawing and animation. Object have preset speed or rotation speed, and their position is computed (and it is actually slightly different every time, it can be seen in the ending scene where the ship turns back toward the planet - it ends up bellow or above the planet depending on exact timing).

 

Sure .. it's far from a game. There is no AI, no physics, no collisions, no scene streaming (managing of object appearing and disappearing as you move through the world). All these are usually quite cheap though, that is if you do them in simple ways usual on 8 bits. Also most of these is done once per frame, or once per object. So it does not really impact speed that much. Everything which is done once per pixel or once per vertex is final.

  • Like 1
Link to comment
Share on other sites

As for the DMA, there is over 20% speedup possible. Except it requires turning the image completely off, which slightly degrades visual quality :D .

 

Anyway .. I didn't understand half of the things you guys are talking about, as I'm quite new to Atari programming. I don't even know 800 well, much less other hardware. So please, if you really want something specific from me to try, make it more clear. For example I didn't know until this weekend how you boot real 800 with basic off. Never needed it with emulator.

 

Even after googling I have no idea what XL14 is, so I just can't react.

 

Anyway, my goal for the demo and the game is so it runs on real Atari. At the moment it doesnt even require any hardware modification. No stereo, no extended memory, nothing.

As for the game, I might go for more memory, or at least disc to download stuff during gameplay. In other words .. things which most people have these days.

Also I have to run it on my Atari, which is totally vanilla XE at the moment, with SDrive. I plan memory extension though, even if with cardridge only at the moment.

 

I'm not interested in any special and rare hardware at the moment. I think I could modify the demo and the game for cartridge, if there is demand for it. But it's not priority, and as for the game, it's pretty far in the future.

  • Like 3
Link to comment
Share on other sites

Some profiling from the most complex scene (ship destruction):

 

Roughly 7-8 frames per second. There are 4 objects, average 68 vertices, 24 lines, 594 mults, 67 divs per frame. That makes on average bellow 9 mults per vertex, which is some measuring error, it's always at least 9. Also this is only for mults done for vertices, not including mults done per object, but those are lot less important (and I've just closed the damn window).

As for divisions, if the objects is visible, there are always at least 2 per vertex, and some more when clipping, but when it's not visible, there is none, so I guess the average of 1 per vertex is just about right in this scene.

 

Time is mostly consumed in:

Mul: 24.5%

CLS: 11.6%

Div: 9%

Line: 6%

 

In scenes with less vertices and more lines the times are shifted toward drawing lines.

Edited by Dr.Sid
  • Like 1
Link to comment
Share on other sites

 

 

Anyway .. I didn't understand half of the things you guys are talking about, as I'm quite new to Atari programming. I don't even know 800 well, much less other hardware. So please, if you really want something specific from me to try, make it more clear. For example I didn't know until this weekend how you boot real 800 with basic off. Never needed it with emulator.

 

Even after googling I have no idea what XL14 is, so I just can't react.

 

 

 

 

Sorry... you're new to this Atari stuff?

 

The XL14 is a hardware accelerator that plugs internally into a 600XL/800XL/1200XL. It runs the system clock at 1.79Mhz (normal Atari), 7.16Mhz, or 14.32Mhz. It also has 256K of RAMBO-style (or, 128K of XE memory) and 512K of linear memory.

 

It is not yet widely available.

 

Your demo runs pretty well at 14Mhz with no changes. Pretty cool.

 

Bob

Link to comment
Share on other sites

The divs for transformations are of course factor muls?

No, they are not. So far I could make any 'trick' working. It's 16/16 to get 8 bits of result. Only trick I do is that I know the result will be less then 1. So the second number will be same or bigger then the first. I roll both numbers so I have top bit used on the bigger number. After that I only taky top bytes and I do 8 step 8/8 division. I only need 8 bits of result, and this gives just that with very small error. The division itself is then the common division with expanded loop.

 

I tried logaritmic division, and it works, but with bigger error. It's not that much faster though, as I also use rolling the words up into bytes.

 

I tried to make factors work, but so far I just didn't find any system to put it all into tables.

  • Like 2
Link to comment
Share on other sites

As for the DMA, there is over 20% speedup possible. Except it requires turning the image completely off, which slightly degrades visual quality :D .

A real Atarian feels the fps even without any display ;)

 

Anyway, my goal for the demo and the game is so it runs on real Atari. At the moment it doesnt even require any hardware modification. No stereo, no extended memory, nothing.

As for the game, I might go for more memory, or at least disc to download stuff during gameplay. In other words .. things which most people have these days.

Also I have to run it on my Atari, which is totally vanilla XE at the moment, with SDrive. I plan memory extension though, even if with cardridge only at the moment.

 

I'm not interested in any special and rare hardware at the moment.

Nice to read.

Link to comment
Share on other sites

Anyway, my goal for the demo and the game is so it runs on real Atari. At the moment it doesnt even require any hardware modification. No stereo, no extended memory, nothing.

As for the game, I might go for more memory, or at least disc to download stuff during gameplay. In other words .. things which most people have these days.

Also I have to run it on my Atari, which is totally vanilla XE at the moment, with SDrive.

 

 

nice to hear that's for Atari computers not for computers in Atari shells :) keep it up!
Link to comment
Share on other sites

Why are you calling it a bug? It's normal use of instruction. It's not the programmer's fault that someone modified original HW on which it runs flawlessly.

In the 21st Century, no programmer should intentionally write code that runs only on the 6502 and not the 65c816. The 816 is a great improvement, it opens up a new world of possibilities, and it certainly does NOT make your computer any "less Atari".

 

I understand that in the case of this program that the bug was not intentional, therefore, it is definitely a bug.

Link to comment
Share on other sites

In the 21st Century, no programmer should intentionally write code that runs only on the 6502 and not the 65c816. The 816 is a great improvement, it opens up a new world of possibilities, and it certainly does NOT make your computer any "less Atari".

Well, it's the 21st Century. So why is one writing code on a 6502 ?

The Atari is based on the 6502 with 1.79MHz , ANTIC, GTIA, POKEY. If you want to have something running on that hardware, you have to accept the limits, that have been given back in the days. Otherwise, it is not the Atari of that time, which blows the cause for doing stuff on that machine. 2 factors have been allowed to add:

1. more RAM, as the A8 is build for Cartridges

2. a second POKEY could fit into any Cartridge

 

 

So what's the cause for doing stuff on a Machine that is not "in the line" of Atari?

Actually, we have the year 2015. 64 Bit computers, 128GB of RAM, giant graphics cards... Sound without limits...

You could add such Hardware into an 800 case... it may look 100% Atari...

Edited by emkay
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...