Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Greven

Let's see if I have this right...

This topic is 6099 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I happed to see Resident Evil the other day (the original, in all of it''s glory) and it made me think. How did they put 3D characters in a pre-rendered 2D world. So I sat and thought about it for a while. The best solution I came up with was a pre-rendered z-buffer as well. I know in apps like Bryce, 3DS, TrueSpace, etc etc etc, you can render the depth buffer. If you did that and then placed that in your z buffer before each frame (as your erase of the z) wouldn''t that make whatever you draw on to it be placed in the scene? So if you put someone back in the scene behind something, that they would be partially hidden by it? I would try this to see if I''m right, but I really lack the 3D expertise to actually complete this. I just want to know if I''m on the right track... Always remember, you''''re unique. Just like everyone else.

Share this post


Link to post
Share on other sites
Advertisement
I think you''re right. As far as I can tell, there are no semi-transparent things you can stand behind (except for smoke, but that''s made out of sprites), so it looks like it could be done with a zbuffer.

However, to define where you can walk about, the map would also have to have 3D blocks overlaid on it. These wouldn''t be for display, just for ''where you can walk''.

Now that I think about it, you might be able to make do with a top-down height-map, as long as you can''t walk under thinks that you can also walk over on the same screen.

All your bases belong to us

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Its just an image written directly into the framebuffer.

So the order of operations at frame-end are.

1) Shove large background image into framebuffer.
2) clear z-buffer..actually, what im i thinking!?!, the playstation doesnt have a zbuffer except for in software..all it can do is render 2d images on the screen and its up to the game to make sure triangles are in screen space..hence no such thing as texture correction or projection.
3) render 3d objects to framebuffer
4) shove framebuffer out to video.

There are also tricks that can be done to overlay transparency effects and other backgrounds to give a better sense of depth.

Share this post


Link to post
Share on other sites
quote:
Original post by Anonymous Poster
Its just an image written directly into the framebuffer.
1) Shove large background image into framebuffer.
2) clear z-buffer.
3) render 3d objects to framebuffer
4) shove framebuffer out to video.



This simply isn''t true: you can walk behind parts of the scene, so it isn''t just a case of drawing a background and foreground; you have to make sure that any object isn''t obscured by something that''s in front of it.

All your bases belong to us

Share this post


Link to post
Share on other sites
One possible way of doing it it to sort all the visuals on distance from camera, then draw them front to back.

[The views stated herein do not necessarily represent the view of the company Eurocom ]

Eurocom Entertainment Software
www.Eurocom.co.uk

The Jackal

Share this post


Link to post
Share on other sites
One possible way of doing it it to sort all the visuals on distance from camera, then draw them front to back.

[The views stated herein do not necessarily represent the view of the company Eurocom ]

Eurocom Entertainment Software
www.Eurocom.co.uk

The Jackal

Share this post


Link to post
Share on other sites
You don''t necessarily draw the entire background first, then the characters, since they do in fact go behind objects and such. What you do is for each part of the background you assign a z value, then you define how the character moves in relation to the depth of the current background, which basically means you decide what angle the camera and viewer are seeing the action from. Then you just draw farthest to nearest. You also have to apply collision rectangles or circles or whatever you want obviously. And you don''t need a hardware zbuffer either, you want a z value for each object, not each pixel.

------------
- outRider -

Share this post


Link to post
Share on other sites
But then how do you use a fully pre-rendered scene? If I pre-render each object, sure that would work. But then your scene will lack the lighting quality and shadow effects that you would otherwise have... If you use the z-buffer approach and you pre-define the area in-game (where you can walk, where things are) as someone said earlier, the pre-rendered scene would look better I think...

Always remember, you''''re unique. Just like everyone else.

Share this post


Link to post
Share on other sites
Render the whole scene as one, then later cut out all the parts that are supposed to go over the characters, so you can draw them seperately. To use the Z buffer to render your prerendered scene would be impossible, at least from the way you described as wanting it done. Z Buffer affects actual polygons with vertices, not a giant static texture.

------------
- outRider -

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!