Textures and memory and more...

About Truespace Archives

These pages are a copy of the official truespace forums prior to their removal somewhere around 2011.

They are retained here for archive purposes only.

Textures and memory and more... // Archive: Tech Forum

1  |  

Post by dlpeach // Sep 15, 2007, 1:57pm

dlpeach
Total Posts: 22
Hi again,


Thought I'd make a new topic, even though the question is related to my previous "disappearing textures problem" topic.


I've managed to render my scene now without any texture problems. I did it by dramatically reducing the resolution of some of the textures. It still wasn't entirely painless, but at least it did work.


So, could the resolution of my textures have been why some of the textures weren't displaying at render time?


Also, along these same lines, I have another question...


My project is such that it requires me to model entire furnished rooms, and take snapshots of those rooms from various angles. But obviously, if I'm taking a shot from a certain angle, everything that's behind the camera is not required as it can't be seen.


Up until now I haven't bothered about this - I've just placed the camera and rendered the shot. I'm wondering now though, if this has meant there was unnecessary resources being used by these unseen objects...?


If I removed all the objects that can't be seen, would that mean I could use higher resolution textures on the objects that could been seen?


My question I guess is: are objects and faces and textures that can't be seen by the camera, still draining resources when I'm rendering a shot?


Hope I'm making sense. :cool:

Post by Jack Edwards // Sep 15, 2007, 3:16pm

Jack Edwards
Total Posts: 4062
pic
Which render engine are you using?


For DX9, the maximum texture resolutions depends on your video card and video memory.


-Jack.

Post by dlpeach // Sep 15, 2007, 3:36pm

dlpeach
Total Posts: 22
I'm just using whatever tS 6.6 uses by default.


My video card is an 128mb ATI Radoen X600. I have a Pentium D 3.4 ghz processor and 2gb RAM. So, I think, it's not too low of resources.


But, I have high res textures in other scenes, and I experience no problems. This particular scene though is full of stuff - the biggest scene I have. Navigating around it is very slow compared to other scenes.


It appears to me that these textures didn't render because there wasn't enough memory or something. I think that, because reducing the texture size has made it work.


But, I'm not a technical person, so I don't know the ins and outs of it.


I was just hoping somebody here could tell me if objects that can't be "seen" by the camera are still draining my system when I'm trying to render the things that CAN be seen. Because if removing those unseen objects means I have more system resources to play with, then I can remove them all, and hopefully revert back to my higher res textures, which I prefer. :)


I may not fully understand the technical things, but I like to at least try and understand why things are happening. :cool:

Post by TomG // Sep 17, 2007, 2:48am

TomG
Total Posts: 3397
There may be a maximum limit of how large a texture can be in Lightworks. What sizes were the textures?


The easiest way to test is to use a simple scene with just a cube, and paint a large texture on it. If it renders, then it is the combination of several large textures and lots of objects that is causing the isssue. If it doesnt render, then it is simply that textures above a certain size won't render.


It is possible that memory is being exhausted - remember a JPG file is only a certain size on disk, but uncompressed it takes up much more memory (so it might be 1Mb on disk, but take up 10Mb or maybe 100Mb when opened up in memory to be used in the render). So it could be, depending on the textures and amount of geometry, that the machine is running out of memory and this is why the render fails, even with 2Gb of memory.


Objects will still use some resources even when not visible, I believe so - I think textures may be loaded to memory for the scene even if they are not going to be rendered (ie they are loaded before the render starts, while the machine doesnt know what will be seen and what not). I am not 100% sure on that though.


Certainly the geometry etc is stored and so takes up memory, so deleting unseen things for a particular shot could well reduce the memory needed and might help (but see point 1 above, it could just be the size of a single texture that prevents it from rendering, you'd need to test and see). Beware of things that ought to cast a shadow or reflection though, those may still be needed for a good result :)


HTH!

Tom

Post by dlpeach // Sep 17, 2007, 9:13am

dlpeach
Total Posts: 22
Thanks Tom.


I tried removing all unseen objects (which weren't casting important shadows), and it seemed to render without a problem.


So I think I'm just running out of memory with this scene, which is no surprise as it's a big scene.


I've been using quite large textures at times when it's not necessary to use such large textures, so I guess I'll have to just prepare my scenes better in the future, depending on what I need to render.


Something else I've learnt. :)

Post by TomG // Sep 17, 2007, 9:24am

TomG
Total Posts: 3397
That is a good point, something I often overlook too in my 3D work. If you have a 3000x3000 wood texture, and you apply it with 3 repeats to a table that will be 300 pixels wide, then in truth you don't need a 3000x3000 texture.


Now, you may need to plan ahead for if you are doing multiple shots, maybe the table will be right in the foreground in another shot and you do need that large texture, so you do need to think and plan.


But by doing so you can save yourself memory and speed up your workspace by using textures that are the right size for a particular project - it is good advice! Even in this day and age of large memory and disk space, it can be good to avoid the approach of using maximum quality everything, and still worth it to optimize here and there.


Just thought I'd use this thread to raise that subject, it's an interesting one :)


Glad you got the rendering working too, that's good news!


Thanks!

Tom

Post by Nez // Sep 18, 2007, 11:22pm

Nez
Total Posts: 1102
pic
A number of useful points raised here that are worth remembering! I certainly try to avoid rendering with geometry outside the view - but it can require certain photography style tricks (like relecting objects, projector lights etc) to ensure the lighting, shadows and refelctions still work as you want.

As Tom mentioned, you may have to consider how an object looks at different distances - you may want to use different texture resolutions (or even differnet geometry) accordingly. And if you have a big scene, it's definetly worth thinking about the level of detail you can see for distant items - my biggest model was 70MB, pretty much all geometry, but probably could have been a lot less if I'd applied some thought in reducing the poly count on distant objects. The extra time an effort would probably have been rewarded too as the scene took ages to render and turned my computer into a sluggish heap...

Can't remember if 6.6 has layers, but if so you could place items in certain directions on different layers so they are easy to switch on and off (also useful during modelling to keep working scene file running smoothly); as TS5 doesn't have layers, I just use custom object libraries to achieve a similar effect.

NB - any chance of seeing some renders from this monster? ;) Sounds interesting!

Post by dlpeach // Sep 19, 2007, 6:32pm

dlpeach
Total Posts: 22
Thanks Nez. That's a good idea about the layers. I haven't actually used them at all yet in trueSpace, but I can see their advantage, so I might give them a go.


I've posted some renders of the "monster" at the end of this thread:


http://forums1.caligari.com/truespace/showthread.php?t=3655


Maybe I was overstating this room's actual size in my earlier posts. To me, and compared to my other scenes, it is quite big, but I'm sure compared to some that others here have done, it's relatively small. :)

Post by jamesmc // Sep 19, 2007, 10:59pm

jamesmc
Total Posts: 2566
Regarding textures in trueSpace, does it still work in tS7.51 when you have a texture of let's say 512 X 500, you would set the size in the object info box of X coordinates of 5.12 and Y coordinate size of 5.00?


And the display size to 512?
Awportals.com is a privately held community resource website dedicated to Active Worlds.
Copyright (c) Mark Randall 2006 - 2024. All Rights Reserved.
Awportals.com   ·   ProLibraries Live   ·   Twitter   ·   LinkedIn