I remember a program...please help me find it?

Looking for a Dragon or CoCo game not already in the archive - Then request it here and hopefully it will either be uploaded to the archive or another member can upload it to this forum.
Post Reply
Cloete
Posts: 35
Joined: Mon Jan 16, 2012 6:49 am
Location: Pretoria, Gauteng Province, South Africa

I remember a program...please help me find it?

Post by Cloete »

I remember a program that was in a Draogn book (not a magazine) – I think it was a black cover with a multi-coloured Dragon logo – Now this program dealt with the calculations of 3D – not rotation 3D, but the effect of approaching an airfield landing strip from a pilot’s view. The program was part of a chapter that explained the formulae and calculations of disappearing view points and the like.
Can someone please help me with a copy of that chapter? Or a copy of the book :-)
Eventually I want to write my own 3D maze in high res graphics...

Thanks
Cloete
User avatar
snarkhunter
Posts: 241
Joined: Fri Apr 03, 2009 7:16 pm
Location: France

Re: I remember a program...please help me find it?

Post by snarkhunter »

This just does not ring any bell - but I only know a few books about programming the Dragon.

In the early 80's, I purchased a book (in French) about 3D "wireframe" rendering, which was providing routines written in Basic - and not specifically for the Dragon: I think it was more aimed at such computers as Apple 2, but was more focused on the technical principles of rendering, so it was quite possible to adapt its content to some other computer. I'm afraid I cannot remember any longer how well this was working. But it sure was slow!
Julian
Posts: 51
Joined: Mon Nov 21, 2011 1:06 pm

Re: I remember a program...please help me find it?

Post by Julian »

What do you actually want to work out? The formula are pretty much standard and there are literally hundreds of books covering the topic. If it is intended to be from a fixed viewpoint there are a few shortcuts you can take as looking up and down don't need to be catered for (try looking up and down in primitive 3D games like Doom and you'll notice a lot of distortion in perspective). Most games like this cheat a big deal in terms of the maths in order to achieve decent frame rates with the texture fills they perform.

If you're not using textures things get easier, much easier from a programming point of view and CPU loads. If you look at games like the ring of darkness or syzygy you'll see it is little more than simple line drawing to a hypothetical vanishing point but in most situations you can never see more than 2 or 3 steps. The moon stage of return of the ring cheats even further and just copies fixed (flat) bitmaps for the trees in different sizes for the effect of perspective or uses the rather handy (but slow) draw function for the rarer objects (creatures).

In terms of the basic calculations it is just crude trigonometry - the perspective scaling is approximately proportional to the inverse square of the distance. If you pick your vanishing "distance" it is just a bias weighting to the proportion.

If you simply want to achieve a single point perspective (i.e. compass points on a squared map) then it is pretty simple. If you want to achieve free rotation then you need a two point perspective that effectively becomes single point when aligned with the axis of your squared map. If you want to look up and down as well then you need three point perspective.

If you want to achieve something more than single point perspective then you need to handle all of your 3D rotation but since you've mentioned this is not your point of interest I will assume it is not needed.

The drawing of the lines is typically achieved through the use of matrices to transform a 3D scene into a flat 2D image. If it is just line drawing then you are working with a relatively small number of points but you also need to do some more complex calculations called shadow tracing to work out which points are visible and those that are blocked from view. Things get more complicated when you need to do hidden line removal. Traditionally this was a cheat on 3D games once the programmers started using blitted blocks of image by working from the furthest distance to the view point since the nearer objects simply overwrite the more distant ones but when you are doing line drawing you need to be a bit smarter especially when you have fairly limited processing available.

Getting back to the 3D stuff - performing the calculations for each point can be slow which is why the smarter programmers cheated by using lookup tables for the sin, cosin calculations. It uses up a bit more memory but the performance benefits are immense. Doing this in basic makes things worse (you can still achieve a fairly decent 3D show if you only have a single frame but once the vertices go beyond about 50 it just grinds to a snails pace)
admin
Site Admin
Posts: 410
Joined: Thu Jul 17, 2008 10:22 pm

Re: I remember a program...please help me find it?

Post by admin »

I think the book you are looking for its this one: http://archive.worldofdragon.org/index. ... _And_Sound
Simon Hardy
Cloete
Posts: 35
Joined: Mon Jan 16, 2012 6:49 am
Location: Pretoria, Gauteng Province, South Africa

Re: I remember a program...please help me find it?

Post by Cloete »

Dear Admin,
Yep, it is that book - thanks. But...
Is it downloadable from the archive? I can't get it to download.
Or can I find it somewhere else? Sorry for these silly 1st-timer-questions. :?:
User avatar
snarkhunter
Posts: 241
Joined: Fri Apr 03, 2009 7:16 pm
Location: France

Re: I remember a program...please help me find it?

Post by snarkhunter »

Hello,

As far as can be told, this book being listed in the "Book Not Online" category, it's likely you will not find it there - sorry ! Still, someone here might have a scanned copy. Otherwise, you'll just have to start searching for one on the usual web sites...

It looks lke there's one copy available there, but I'm afraid it might be a bit to far to pay them a visit after lunch and be back for dinner in a timely manner !
User avatar
rolfmichelsen
Posts: 299
Joined: Wed Apr 08, 2009 8:43 pm
Location: Oslo, Norway
Contact:

Re: I remember a program...please help me find it?

Post by rolfmichelsen »

I have uploaded a scanned copy of Advanced Sound & Graphics to the Uploads section of the forums. See this post.

-- Rolf
Post Reply