English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 15 January 2015, 22:55   #21
Rebel-CD32
Amiga will never die!
Rebel-CD32's Avatar
 
Join Date: Nov 2004
Location: Gold Coast, Australia
Age: 39
Posts: 530
Send a message via MSN to Rebel-CD32
Quote:
Originally Posted by sandruzzo View Post
Thanks a lot

About Graphics, were I can get some good stuff to use to do road? I would like to do it full "textured"
I'd also really like to see someone attempt a textured road in a Lotus-style game. It's certainly possible, yet hardly anyone ever attempted it. I think the best way to go about the texturing would be to quickly mockup a textured road in a 3D program which uses a repeating pattern, scroll it towards the camera and save out the frames. The parallax road should then cycle through the animated frames to give the illusion of road moving towards us. Does this make sense? I'm only approaching this from a graphical point of view rather than having any technical programming knowledge, but I can see in my head how it would work.

Street Racer uses this technique, but sadly the engine doesn't support hills which I think are important for a game like this.



If you can work out how to code it, I'd like to help with the road/roadside textures, objects and colour palettes. I've had this on my mind for a long time and have just been waiting for someone else to be interested in the idea. I think an AGA Amiga should be able to reproduce a Need For Speed-style game with OutRunners-style graphics using a mixture of pseudo-3D roads, (animated) pattern-mapped polygonal landscapes combined with scaled bitmaps.
Rebel-CD32 is offline  
Old 15 January 2015, 23:00   #22
Lonewolf10
AMOS Extensions Developer
Lonewolf10's Avatar
 
Join Date: Jun 2007
Location: near Cambridge, UK
Age: 40
Posts: 1,923
I have Street Racer for the Megadrive, and completed it

Whilst the game does not indeed have hills, it is one of (the only?) racing game of this style that allows you to reverse back the way you came. The game also ran super smoothly (probably due to the lack of not worrying about hills in the games code) - probably 50fps or close to it.
Lonewolf10 is offline  
Old 16 January 2015, 07:39   #23
Nekoniaow
Banned

 
Join Date: Dec 2014
Location: Montreal
Posts: 129
Quote:
Originally Posted by Rebel-CD32 View Post
I'd also really like to see someone attempt a textured road in a Lotus-style game. It's certainly possible, yet hardly anyone ever attempted it. I think the best way to go about the texturing would be to quickly mockup a textured road in a 3D program which uses a repeating pattern, scroll it towards the camera and save out the frames. The parallax road should then cycle through the animated frames to give the illusion of road moving towards us. Does this make sense? I'm only approaching this from a graphical point of view rather than having any technical programming knowledge, but I can see in my head how it would work.

Street Racer uses this technique, but sadly the engine doesn't support hills which I think are important for a game like this.
I am indeed surprised that there was never an AGA Lotus, it certainly wouldn't have been too hard to add one more bitplane for the road in order to support an height colour texture and to use the big AGA sprites for some above road objects. A few weeks of work at most would have made it possible unless the code was a complete mess.

Quote:
If you can work out how to code it, I'd like to help with the road/roadside textures, objects and colour palettes. I've had this on my mind for a long time and have just been waiting for someone else to be interested in the idea. I think an AGA Amiga should be able to reproduce a Need For Speed-style game with OutRunners-style graphics using a mixture of pseudo-3D roads, (animated) pattern-mapped polygonal landscapes combined with scaled bitmaps.
If you are willing to limit the number of colours used by the road and background to sixteen (four bitplanes) and rely only on 64 pixels sprites then maybe (not even guaranteed) you could have patterned polygons for the background but anything more would likely eat too much blitter bandwidth. I might be a bit off and maybe one more bitplane could be afforded but it would definitely be difficult to use large bobs for roadside scenery and vehicles/obstacles.

These objects have to be drawn using a cookie cut function which is the most expensive blitter copy operation, and this has to be repeated for every bitplane of the road and background instead of just two for a Lotus-like three colours road/roadside.

I would not be surprised if Street Racer was using sprites to draw the vehicles precisely because cookie cutting through the road would have been too expensive.

It's definitely possible I'm wrong since I haven't bothered to compute bandwidth estimates but it's definitely difficult to do full screen redraws per frame on AGA machines unless you limit the number of bitplanes close to ECS levels or rely exclusively on sprites for foreground objects.

Last edited by Nekoniaow; 16 January 2015 at 07:41. Reason: Clarified.
Nekoniaow is offline  
Old 16 January 2015, 09:05   #24
sandruzzo
Registered User
 
Join Date: Feb 2011
Location: Italy/Rome
Posts: 1,779
Nekoniaow

You can use dualplayfield mode: one playfield will be used to do full texture road, and the other ones will be used for sprite. Thit tecnique will allow us to do a great off the chart racing game for AGA.
sandruzzo is offline  
Old 16 January 2015, 09:08   #25
sandruzzo
Registered User
 
Join Date: Feb 2011
Location: Italy/Rome
Posts: 1,779
Quote:
Originally Posted by Rebel-CD32 View Post
I'd also really like to see someone attempt a textured road in a Lotus-style game. It's certainly possible, yet hardly anyone ever attempted it. I think the best way to go about the texturing would be to quickly mockup a textured road in a 3D program which uses a repeating pattern, scroll it towards the camera and save out the frames. The parallax road should then cycle through the animated frames to give the illusion of road moving towards us. Does this make sense? I'm only approaching this from a graphical point of view rather than having any technical programming knowledge, but I can see in my head how it would work.

Street Racer uses this technique, but sadly the engine doesn't support hills which I think are important for a game like this.



If you can work out how to code it, I'd like to help with the road/roadside textures, objects and colour palettes. I've had this on my mind for a long time and have just been waiting for someone else to be interested in the idea. I think an AGA Amiga should be able to reproduce a Need For Speed-style game with OutRunners-style graphics using a mixture of pseudo-3D roads, (animated) pattern-mapped polygonal landscapes combined with scaled bitmaps.
Rebel-CD32

That's my problem to have good quality graphics . I can code, I just need time to polish my skill, a lot of years whitout coding on Amiga.

First I'll code road engine on Pc, then I will traslate it on Amiga Aga.
sandruzzo is offline  
Old 16 January 2015, 10:22   #26
Nekoniaow
Banned

 
Join Date: Dec 2014
Location: Montreal
Posts: 129
Quote:
Originally Posted by sandruzzo View Post
Nekoniaow

You can use dualplayfield mode: one playfield will be used to do full texture road, and the other ones will be used for sprite. Thit tecnique will allow us to do a great off the chart racing game for AGA.
Dual play field AGA allows maximum 32 colours though.
And while this lightens the load on the blitter by partially removing the need to cookie cut bobs against the background, the overlapping ones still need it at least between themselves on at least three bitplanes.

I highly recommend to compute an estimate RAM bandwidth budget as a function of the desired "specs" in order to avoid any deception:

Using the following variables it's relatively easy to determine if what you want to draw can fit in an AGA frame.
- Number of bitplanes for the background/road playfield?
- Number of bitplanes for the objects/vehicles playfield?
- Fraction of the background playfield to be redrawn each frame?
- Number of blitter channels needed per background element draw?
- Average surface (in bytes) * number of top objects/vehicles?
- Number of blitter channels needed per objects/vehicles element?

Once you decide on these numbers you can compute the number of DMA access needed for each frame and compare against what's available in an AGA frame. Then only can you determine whether that's feasible or not.

The AGA sprites, colour registers banks and the copper allow for nice cheats but obtaining a really good looking result is certainly not an easy task.
Nekoniaow is offline  
Old 16 January 2015, 11:58   #27
Shatterhand
Warhasneverbeensomuchfun

Shatterhand's Avatar
 
Join Date: Jun 2001
Location: Rio de Janeiro / Brazil
Age: 36
Posts: 3,437
Quote:
Originally Posted by Lonewolf10 View Post
I have Street Racer for the Megadrive, and completed it

Whilst the game does not indeed have hills, it is one of (the only?) racing game of this style that allows you to reverse back the way you came. The game also ran super smoothly (probably due to the lack of not worrying about hills in the games code) - probably 50fps or close to it.
I find curious how this game had so many different versions over different platforms. The Mega-Drive one looks a lot like the Amiga one, but the SNES one is very, very different, and then there are the 32 bits consoles versions (PS1 and Saturn) which were brilliant games that IMO never got the love they deserved. The Saturn version can be played by 6 playes at the same time if you have the adapter for this!
Shatterhand is offline  
Old 16 January 2015, 13:09   #28
sandruzzo
Registered User
 
Join Date: Feb 2011
Location: Italy/Rome
Posts: 1,779
Quote:
Originally Posted by Nekoniaow View Post
Dual play field AGA allows maximum 32 colours though.
And while this lightens the load on the blitter by partially removing the need to cookie cut bobs against the background, the overlapping ones still need it at least between themselves on at least three bitplanes.

I highly recommend to compute an estimate RAM bandwidth budget as a function of the desired "specs" in order to avoid any deception:

Using the following variables it's relatively easy to determine if what you want to draw can fit in an AGA frame.
- Number of bitplanes for the background/road playfield?
- Number of bitplanes for the objects/vehicles playfield?
- Fraction of the background playfield to be redrawn each frame?
- Number of blitter channels needed per background element draw?
- Average surface (in bytes) * number of top objects/vehicles?
- Number of blitter channels needed per objects/vehicles element?

Once you decide on these numbers you can compute the number of DMA access needed for each frame and compare against what's available in an AGA frame. Then only can you determine whether that's feasible or not.

The AGA sprites, colour registers banks and the copper allow for nice cheats but obtaining a really good looking result is certainly not an easy task.
If you use color's palette changing you can have more that 32 color, which are not but to start with. Whith dual playfield mode you can do the road without using the blitter. In order to do curves and hill you can play with playfield pointers and shift.
sandruzzo is offline  
Old 16 January 2015, 15:48   #29
Nekoniaow
Banned

 
Join Date: Dec 2014
Location: Montreal
Posts: 129
Quote:
Originally Posted by sandruzzo View Post
If you use color's palette changing you can have more that 32 color, which are not but to start with. Whith dual playfield mode you can do the road without using the blitter. In order to do curves and hill you can play with playfield pointers and shift.
There is no doubt that the copper can and must be used but 32 colours + copper still is ECS looking. Although it must be noted that Lotus 2&3 are actually 16 colors + copper, not 32. I was surprised to find this out a few weeks ago while playing with UAE's debugger.

As for the road you wrote yourself about pattern filled polygons for the background and hills, there is no way you can have these without actually writing to the frame buffer which is why I implied a redraw was needed.
If you go with a purely scrolling based solution for the road this makes it much easier indeed and coincides with what I described as a Lotus AGA with the dual playfield enormously reducing blitting needs in exchange for an ECS-like colour palette. This clearly has the added benefit that more blitter time is available for objects and vehicles even with one more bitplane than Lotus which I indeed failed to realize.

I would definitely have liked to buy and play such a game around 1992-94 and probably still would buy it if someone made one (damn, now I want to try it!) but it seemed to me that you were aiming for more.

Last edited by Nekoniaow; 16 January 2015 at 15:49. Reason: Grammar
Nekoniaow is offline  
Old 16 January 2015, 17:32   #30
sandruzzo
Registered User
 
Join Date: Feb 2011
Location: Italy/Rome
Posts: 1,779
Nekoniaow

If you do a pre animated road, and use it as look-up table, you can have zero blitter aid for it, and spare it for moving object.
sandruzzo is offline  
Old 16 January 2015, 19:13   #31
Der_Richter
 
Posts: n/a
One way could be to prerender the road, dump the frames and then use a mask on the section at the bottom (the same height as the player sprite) to determine the valid road edges. As the animation of the road changes, you change the mask, as to match the new bounds at the line that the player/car is...

Would generate a lot of frames, but if you can fin a way to stream that it should work.

Would be similiar to Megarace actually.
 
Old 17 January 2015, 01:30   #32
Nekoniaow
Banned

 
Join Date: Dec 2014
Location: Montreal
Posts: 129
Quote:
Originally Posted by sandruzzo View Post
Nekoniaow

If you do a pre animated road, and use it as look-up table, you can have zero blitter aid for it, and spare it for moving object.
That much is obvious and I never said anything remotely disagreeing with this statement.

What I was arguing was costly was your initial proposition:

Quote:
Originally Posted by sandruzzo
I think an AGA Amiga should be able to reproduce a Need For Speed-style game with OutRunners-style graphics using a mixture of pseudo-3D roads, (animated) pattern-mapped polygonal landscapes combined with scaled bitmaps.
The underlined part is why I talked of blit operations for the background. It's pretty clear if you re-read my post as I insisted on the fact that pattern mapped polygons are expensive.
Nekoniaow is offline  
Old 17 January 2015, 01:58   #33
Nekoniaow
Banned

 
Join Date: Dec 2014
Location: Montreal
Posts: 129
Quote:
Originally Posted by Der_Richter View Post
One way could be to prerender the road, dump the frames and then use a mask on the section at the bottom (the same height as the player sprite) to determine the valid road edges. As the animation of the road changes, you change the mask, as to match the new bounds at the line that the player/car is...
You don't even need to go that far.

If your road "texture" is sufficiently repetitive then you can store all scaled versions of it in memory and simply use the copper to fetch the proper line, shifting it left or right depending on the curvature of the road.

If say, your texture repeats after the bottom 8 pixels then you can store all scaled versions with the equivalent of 8 copies of the screen space taken by the road. Given that there is a lot of aliasing for the portions of the road which are further away from the camera you can probably get away with not storing all possible high z versions.
That's still a lot of space: about 8/2 = 4 screens worth of road if you assume that the road only takes half of the screen and neglecting the side margins needed for shifting the road left and right but the effect might be worth it given that there's nothing to draw at all since you are simply using the copper to point at the proper portion of pre-rendered road in memory.

The biggest drawbacks to this approach is that even just a few pixels of texture (along the z axis) require to reserve a large amount of screen space.

This said it seems possible to cheat and use the copper + bitplane delay to generate intermediate z values from existing ones on the fly which would reduce the memory requirement. Also as I said, high z values do not need to be all stored since the aliasing makes them unrecognizable anyway, using some kind of mipmapping scheme would both decrease memory consumption and increase visual quality in the distance.

It seems difficult at this stage to affirm that this would make the road visually pleasing enough to justify the memory consumption though. A prototype would help.
Nekoniaow is offline  
Old 17 January 2015, 08:37   #34
sandruzzo
Registered User
 
Join Date: Feb 2011
Location: Italy/Rome
Posts: 1,779
Quote:
Originally Posted by Nekoniaow View Post
That much is obvious and I never said anything remotely disagreeing with this statement.

What I was arguing was costly was your initial proposition:



The underlined part is why I talked of blit operations for the background. It's pretty clear if you re-read my post as I insisted on the fact that pattern mapped polygons are expensive.
Nekoniaow

My fault on says polygon. What I meant is just to have an animated road, like Agony's water on level one, and use it as lookup table when we calculate road, hills, and curves
sandruzzo is offline  
Old 17 January 2015, 23:59   #35
Lonewolf10
AMOS Extensions Developer
Lonewolf10's Avatar
 
Join Date: Jun 2007
Location: near Cambridge, UK
Age: 40
Posts: 1,923
Quote:
Originally Posted by Shatterhand View Post
I find curious how this game had so many different versions over different platforms. The Mega-Drive one looks a lot like the Amiga one, but the SNES one is very, very different, and then there are the 32 bits consoles versions (PS1 and Saturn) which were brilliant games that IMO never got the love they deserved. The Saturn version can be played by 6 playes at the same time if you have the adapter for this!
I don't. The game was developed at the time of console crossover between the then current-gen and next-gen consoles coming out - PS1 was out in Japan in late 1994 and the Saturn 1995?

Here are some videos on YouTube:

Megadrive - [ Show youtube player ]
SNES - [ Show youtube player ]
PS1 - [ Show youtube player ]
Saturn - [ Show youtube player ]


Differences:
- Megadrive: is essentially the version we are trying to reproduce on the Amiga. Note the 3 layers of parallax movement in the background.
- SNES: same as Megadrive but made use (predictably) of Mode 7. It is the special mode for the SNES that allows a low-res texture to be applied to the 'ground' and rotated. Mode 7 is also used in other racers such as Mario Kart and F-Zero.
- PS1: Polygonal racer, with 2 layers of parallax in the background.
- Saturn: Same as PS1, but had better clouds, transparencies & reflections. The better effects are due in part to the Saturn having superior sprite power vs. the PS1 - polygon-wise the reverse is true (750K per second for PS1 vs. 500K per second for Saturn).
Lonewolf10 is offline  
Old 18 January 2015, 08:54   #36
Michael
A1260T/PPC/BV/SCSI/NET

Michael's Avatar
 
Join Date: Jan 2013
Location: Moscow / Russia
Posts: 680
Anybody gave a thought about virtual carting and some other similar games? They had textured roads.

What is the hardware target ? Plain 1200, with fast ram or with 030+ ?

The later will allow a full 3D engine to run at 20+ fps (like GLOOM)
And the benefit is it will also be rtg compatible for more advanced machines and very fast there and if you go with 3D support we are close to WipeOut ;-).
Michael is offline  
Old 19 January 2015, 08:42   #37
sandruzzo
Registered User
 
Join Date: Feb 2011
Location: Italy/Rome
Posts: 1,779
Quote:
Originally Posted by Michael View Post
Anybody gave a thought about virtual carting and some other similar games? They had textured roads.

What is the hardware target ? Plain 1200, with fast ram or with 030+ ?

The later will allow a full 3D engine to run at 20+ fps (like GLOOM)
And the benefit is it will also be rtg compatible for more advanced machines and very fast there and if you go with 3D support we are close to WipeOut ;-).
Amiga 1200 with fast ram. No real 3d, only lotus style game
sandruzzo is offline  
Old 19 January 2015, 14:31   #38
Megol
Registered User

Megol's Avatar
 
Join Date: May 2014
Location: inside the emulator
Posts: 374
Quote:
Originally Posted by Michael View Post
Anybody gave a thought about virtual carting and some other similar games? They had textured roads.

What is the hardware target ? Plain 1200, with fast ram or with 030+ ?

The later will allow a full 3D engine to run at 20+ fps (like GLOOM)
And the benefit is it will also be rtg compatible for more advanced machines and very fast there and if you go with 3D support we are close to WipeOut ;-).
GLOOM is a 2D game faking a 3D view, those engines are often called 2.5D. In fact GLOOM is an enhanced Wolfenstein type engine which is less complex compared to a DOOM type engine (which still is a 2.5D engine - not a 3D one).
Megol is offline  
Old 19 January 2015, 14:32   #39
sandruzzo
Registered User
 
Join Date: Feb 2011
Location: Italy/Rome
Posts: 1,779
Quote:
Originally Posted by Megol View Post
GLOOM is a 2D game faking a 3D view, those engines are often called 2.5D. In fact GLOOM is an enhanced Wolfenstein type engine which is less complex compared to a DOOM type engine (which still is a 2.5D engine - not a 3D one).
2*2 chunky?? no way, just a classic Amiga Game.. Let that things were belong
sandruzzo is offline  
Old 19 January 2015, 15:49   #40
Michael
A1260T/PPC/BV/SCSI/NET

Michael's Avatar
 
Join Date: Jan 2013
Location: Moscow / Russia
Posts: 680
Why 2x2 ? It will run nicely in 1x1 on 030 chip and possibly 2x1 on a fast ram A1200.
And if we are really pushing the limits it can be a combination of textured mapped simple 3D (2.5) engine for the road and side buildings, bridges, and sprites for cars and powerup objects.

Anyways, this is for an advanced game, I will still be happy with Lotus, XJ200, Batman, ChaseHQ type road enigines. Or maybe a fully polygonal road like StuntCarRecer.

Anybody remembers AlienF1 ? A very nice and fast textured engine, just needs the easier arcade controls and more conventional lambo style cars
Michael is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Coding my game in Blitz2 r0ber7 Coders. General 103 11 September 2011 20:14
EAB/Lemon Super League 2008: Round 8 - What Lotus III Game Mode? Graham Humphrey EAB's competition 41 20 July 2008 01:49
Need help with audio coding. Thorham Coders. General 6 05 March 2008 08:38
Help coding alexh Coders. General 14 15 August 2006 09:24
Bedroom coding SabreGolly Nostalgia & memories 40 21 May 2003 20:35

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 03:24.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Page generated in 0.09367 seconds with 14 queries