The Port
category: code [glöplog]
At http://pouet.net/prod.php?which=63 elend suggested making an Amiga port.
I guess that would be more a rewrite than a port.
Quote:
I guess that would be more a rewrite than a port.
It would be no matter what, since the source contains large amounts of real-mode x86 assembly. Sure, you could port it by including an x86 emulator in the new version of the demo, but meh... :P
I was thinking more of a PC port.
Github says the entire source is made by 86,2% of C++ code.
It doesn't recognize Pascal, though. Strange.
If by "PC port" you mean x86 desktop versions of Windows or Linux, then you'd still have to rewrite all of the assembly code since it wouldn't work as-is on either of those targets. And the C code does all sorts of things that wouldn't be allowed either, like writing directly to the VGA ports.
What would be the point anyway?
The demo runs fine in Dosbox, so it already works on many platforms.
Rewriting all the hand-optimized parts and special hardware-specific routines with new routines that merely emulate the original effects seems to defy the point of the demo.
The demo runs fine in Dosbox, so it already works on many platforms.
Rewriting all the hand-optimized parts and special hardware-specific routines with new routines that merely emulate the original effects seems to defy the point of the demo.
So in your opinion, what would be the point of releasing the sourcecode, then?
Best news ever! Even as a curiosity, to have a look at the most classic demo code!
I looked through the code (very cursory) and while yeah there's a lot of inline nastiness, it didn't seem particularly improbable to do it. Just a LOT of work. Essentially, if I were to do it, I'd prolly just end up copying out the effect code instead of trying to compile it as is.
I'll prolly give it a shot or two if some russian haxor doesn't do it within a few days :D
I'll prolly give it a shot or two if some russian haxor doesn't do it within a few days :D
I guess what I'm trying to say is that since the parts are relatively self-contained you can port them independently, which is less work then trying to get a whole demo to work all at once. Of course linking will be a pain, but it's still entirely possible.
And my guess is Sol is already working on it :D
Quote:
So in your opinion, what would be the point of releasing the sourcecode, then?
It's still much, much easier to port something if you've got the source code, even if you have to rewrite parts of it.
And you could also see the source code as an artifact of the demoscene. It doesn't _have_ to have a practical purpose.
Quote:
So in your opinion, what would be the point of releasing the sourcecode, then?
So people can study and see how they did it. It's a piece of history, releasing the sourcecode will preserve the technology for future generations.
I think it's pretty strange that 'port' is the first thing that comes to your mind when you see sourcecode.
Quote:
elend suggested making an Amiga port.
That would be impressive, because... Correct me if I'm wrong, the PCs you ran Second Reality on were at least twice as fast as an Amiga, nope ? That is, if you consider, and correct me again if needed, that an Amiga's CPU ran at 7.14 MHz and had the same clock speed dedicated to Agnus, Denise and Paula. I feel the explanation would be a bit more complex, but you've got the idea.
So, on one hand, a PC clocked at, at least, 33 MHz (would rather be 50 or 66 MHz I guess), and on the other hand an Amiga clocked at 7.14/14.28 MHz. It would be much more than a simple rewrite, and I think I would be astounded to see this demo run on an Amiga. It would be really amazing!
To see how they did a starfield 20 years ago on a 486???
Come on, the "artifact of the demoscene" theory is more plausible :)
Come on, the "artifact of the demoscene" theory is more plausible :)
Quote:
if you consider, and correct me again if needed, that an Amiga's CPU ran at 7.14 MHz
You can't port this on a standard Amiga. You'd need at least an AGA chipset (since the VGA has 256 colors, opposed to the 32 colors of an OCS chipset).
A *dithered* "rewrite" on a standard Amiga would impress me (even if I don't think a 7mhz Amiga could handle the final 3d part - feel free to prove me wrong).
Quote:
Github says the entire source is made by 86,2% of C++ code.
There are a lot of inline assembly blocks, I'm rather sure they just look if the file looks like a certain programming language, and don't evaluate the language line per line. :)
That said, I think Sol already ported Death Rally to Win32/SDL, how about Second Reality next? *g*
First, a masterpiece called Desert Dream was released on Amiga.
Then, Future Crew tried to do something similar for PC.
The result was called Second Reality.
Then, Future Crew tried to do something similar for PC.
The result was called Second Reality.
Quote:
To see how they did a starfield 20 years ago on a 486???
I bet that most coders today actually have no idea how some of the effects were done in Second Reality.
Things like making use of planar EGA modes and such.
This is the domain of 'retroprogramming'.
Most coders today would only know about linear framebuffers with truecolour, and have little idea of the tricks with palettes and bitplanes you could pull on old hardware (because you simply can't do those things anymore).
Coding the effects in Second Reality on modern hardware is one thing.
Coding them in 16-bit mode on an actual 386 or 486 (and no FPU) with standard VGA is something completely different.
Quote:
even if I don't think a 7mhz Amiga could handle the final 3d part - feel free to prove me wrong
Hmm don't like half of 90's Amiga demos have a similar VIRTUAL REALITY part? A 7MHz 68k might not be much but that's why you summon the powers of the blitter.
ham: after 20 years still bitter about that? :P
Quote:
Hmm don't like half of 90's Amiga demos have a similar VIRTUAL REALITY part? A 7MHz 68k might not be much but that's why you summon the powers of the blitter.
Look at the source tree, they even call that part Amiga City:
https://github.com/mtuomi/SecondReality/blob/master/VISU/C/AMIGACIT
:)
Having said that, a stock Amiga wouldn't be able to pull off a city scene like that as well.
Maali: LOL! Bitter about what? :D
Besides, the "port" was done for C64 a few years ago.
Don't remember? -> Second Reality 64
;]
Besides, the "port" was done for C64 a few years ago.
Don't remember? -> Second Reality 64
;]