Path: chuka.playstation.co.uk!news From: James Russell Newsgroups: scea.yaroze.programming.3d_graphics Subject: Re: 3D "How-To" Q's Date: Thu, 09 Jul 1998 10:05:07 +0100 Organization: Sony Computer Entertainment Europe Lines: 55 Message-ID: <35A487C3.7124784B@scee.sony.co.uk> References: <6o0qvi$7mk11@scea> NNTP-Posting-Host: camfw01.millennium.co.uk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 4.05 [en] (Win95; I) Steve Spiller wrote: > > First of all, Camera Movement. > I'm working on a 3/4 view 3rd person game and was wondering how camera > movement is usually handled. Do you keep the world static and move the > camera through it, do you setup a game object (player) to be the parent of > the camera so it moves around with it, or do you move the world around the > camera? It's best to think of this as two separate problems: 1) How to I get all my objects into world coordinates? 2) Once everything is in world coordinates, how do I look at that world from an arbitrary position/direction with the camera? Problem 1 is taken care of by the structures in the libraries - each model has its own coordinate system (and possible child/parent coordinate systems) and the libraries take care of translating those coord systems to WORLD. Problem 2 is dead easy. You can specify a camera position and direction in WORLD coordinates (using a GsRVIEW2/GsVIEW2 structure with a super of WORLD). The libraries can use this structure and your object's GsCOORDINATE2 structures to get an object from Local -> World -> Screen. This is very useful, because placing the camera in terms of world coordinates is a very intuitive way of thinking about it. However, sometimes you want to put the camera behind the player's head (like Tomb Raider). If you specify the camera position relative to the player's LOCAL coordinate system, then have the 'super' structure of the camera (in GsRVIEW2 or GsVIEW2) point to the coordinate system of the player object, the libraries will automatically calculate the World -> Screen matrix required to make it look like the camera is behind the player. > Second, 3D Object Animation. > If I'm trying to animate a humanoid character, what's the best/easiest way? > Should I have models for each of the different positions, create seperate > models for each jointed segment and setup an object hierarchy where I can > just rotate the "limbs", or create a single object and modify verticies > directly (if that can be done)? The easiest way is to create multiple objects (one for each limb), then create a hierarchy. It *is* possible to do direct vertex modification, but it's a world of hurt for any complicated model (especially one that uses multiple coordinate systems!). Cheers, James -- == James_Russell@scee.sony.co.uk +44 (171) 447-1626 == Developer Support Engineer - Sony Computer Entertainment Europe A diagnostic is someone who doesn't know if there are two Gods.