Path: chuka.playstation.co.uk!news From: sosman@terratron.com (Steven Osman) Newsgroups: scee.yaroze.freetalk.english Subject: Re: Dynamic Texture Changing Date: Tue, 18 Jan 2000 20:24:03 GMT Organization: PlayStation Net Yaroze (SCEE) Lines: 91 Message-ID: <3884cb4d.3545346658@news.playstation.co.uk> References: <3880CDAA.87D5513@which.net> <388207D8.8826ECED@which.net> <38838fe2.3399055253@news.playstation.co.uk> <3884BE6C.1928D403@which.net> NNTP-Posting-Host: 209.27.57.69 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Newsreader: Forte Agent 1.5/32.452 Max, I was thinking about what you are talking about, BUT... The question is, when does the model get sent to the rendering engine? If you change ONE copy of the model, and then ask the scene to be rendered, you run the risk that all objects will use the latest incarnation of the model. What I'm getting at, is whether or not NY duplicates an object each time you call SortObject. If it does not, you'll find that you are messing them all up. If, on the other hand, sortobject really does duplicate the model data, then you're okay. If you consider what I told you though -- changing only the polygon data of the object, you'll eliminate the need of having to run the update for each frame -- possibly twice! Steven On Tue, 18 Jan 2000 19:26:36 +0000, Max wrote: >Righty then, > >I think I have a pretty good idea of what to do now, an emalgamtion of most >everything I think!!!! >Tricky business indeed, I think I'll just have a loop within a function to change >the texture each time this way I will only have one version of the model no >matter which way I do it.... funky, no cheree? > >Our French class for today is concluded on the note that I know none. > >Max > >Steven Osman wrote: > >> Max, >> >> You can load the different textures in different pages. Then you >> modify the "TSB" element in the packet data of your TMD. Basically, >> part of this "TSB" element contains the texture page which is used for >> the texture mapped onto the model. The thing is that you may need to >> take your TMD file and make 3 copies of it in memory, (well, not >> entirely, and I'll get to that), so that each one of the three copies >> points to different texture pages. >> >> The "not entirely" part is this... >> >> When you load a TMD file, the beginning of it contains 3 pointers: one >> to a list of vertices, one to a list of normals, and the last one to a >> list of polygons. The neat part is that your 2 new copies of the TMD >> file (so you have three in all), can point to the original >> vertex/normal lists, you need only duplicate the polygon data. You >> then have to go through these polygons, pick out whichever ones use >> textures, and alter the texture page appropriately. >> >> Steven >> >> On Sun, 16 Jan 2000 18:03:04 +0000, Max wrote: >> >> >Well yee see, >> > >> >what I'm trying to do is just have 3 textures then have one model. What I >> >would have otherwise done is load up three versions of the same model to >> >accomodate 3 different textures. What I would like to do is just have one >> >model uploaded (to save space, etc...) and then just have the three texures >> >put on it. Please note I do not want to change the textures while they are >> >on the model i.e. flashing between the 3 different textures, it's a bit hard >> >to explain. Overwriting them in VRAM wouldn't work because I want to display >> >the same model with the 3 textures all at a time essentially coming up with >> >3 models (same model) with the different textures on each of them, >> >overwriting would screw up the textures. >> > >> >If any one can come up with a soloution then you would probably be like the >> >smartest guy I know and I would also be very happy. >> > >> >Cheers, >> >Max >> > >> >Max wrote: >> > >> >> Right now, >> >> >> >> Does any one know how to change textures dymnamically within the code. I >> >> have one model and three textures and it would be really handy to have >> >> just one model instead of three. >> >> >> >> Thanking everybody in advance. >> >> >> >> Max