L3DT users' community
Large 3D terrain generator

TVi2 loading mgfs

Please report software faults here.

TVi2 loading mgfs

Postby monks » Tue Nov 29, 2005 10:52 pm

Hi Aaron- I've had some pretty fruity goings on here with TVi2 in loading .mgf files.
The problem is: when loaded in TVi2 the lighting is all out - it is black as if no lightmap has been generated or some such.

Eg
Open file 1 in TV= OK
close TV
open TV
Open file 1 with TV= NOT OK
close TV
scratch head
...methinks that this is where my investigations should have stopped :) but like Alice I was curious and continued for a couple of hours...bad move :roll: !- I can't figure out what the problem is. I need to be able to provide the article I've just written with a tutorial .mgf, but at this point I can't be sure it's going to work in TVi2 for readers. The files are fine in L3DT. It would be a shame to go through the tutorial and not to be able to see those splendid visuals at the end (I like TVi2).
I am doubtful because I tried opening the file that works and resetting the terracing to 0, keeping everything else the same, and resaving. The problem reasserts itself in the new file. The tutorial file is set up so that users can modify the mgf themselves.


I'll just send you the the one file that I know does work and one that doesn't. You could try reproducing the terracing thing.

Questions : can you reset the terracing by reactivating the pencil terrace tool and setting the slider to 0, then apply to all ?
If so, does it matter if you deactivate the terrace tool before moving on to generate the rest of the maps ?
What's the difference between saving group as... and save Map group file ?

Cheers
monks
Oracle
 
Posts: 292
Joined: Tue Nov 22, 2005 10:38 pm
Location: Middle Earth

Re: TVi2 loading mgfs

Postby Aaron » Wed Nov 30, 2005 5:11 am

monks wrote:I've had some pretty fruity goings on here with TVi2 in loading .mgf files.


Urgh. L3DTVi2's loader expects everything to be just-so, and it doesn't handle unexpected things very well at all. Basically, you need to use HFF in 16-bit mode for terrain, and jpeg/bmp for textures etc. There are also a few arcane bridge-rules like not having image files with the same name but different extension (ie mymap_TX.bmp and mymap_TX.jpg).

Hmmm...I'm beginning to think now would be a good time to write some documentation for L3DTVi2.

monks wrote:The problem is: when loaded in TVi2 the lighting is all out - it is black as if no lightmap has been generated or some such.


I think that means L3DTVi2 couldn’t find the texture, or there was another problem with the texture.

monks wrote:Open file 1 in TV= OK
close TV
open TV
Open file 1 with TV= NOT OK
close TV
scratch head


Whacky. I can't explain why it would vary from session to session.

monks wrote:I'll just send you the the one file that I know does work and one that doesn't. You could try reproducing the terracing thing.


Yeah, that would be good. I'll need at least the .mgf and .def, but if you could send me the entire map directory zipped-up, it would be even better.

monks wrote:Questions : can you reset the terracing by reactivating the pencil terrace tool and setting the slider to 0, then apply to all ?


I'm not sure I understand what you mean by 'reset', but if you mean simply stopping all cliffs/terraces overlays when generating the heightfield, then yes, it will do that.

monks wrote:If so, does it matter if you deactivate the terrace tool before moving on to generate the rest of the maps ?


No, it shouldn't matter. That is probably the recommended method of operation, though.

monks wrote:What's the difference between saving group as... and save Map group file ?


'Save group as...' saves the entire contents of the map group, including all map files (.hff, .wmf, etc.) and the descriptor files (.mgf, .def, .html, etc). The 'save map group file' is an option that you would not normally need to use, as it only saves the .mgf file and not the rest of the map group.

Cheers,
Aaron.
User avatar
Aaron
Site Admin
 
Posts: 3691
Joined: Sun Nov 20, 2005 2:41 pm
Location: Melbourne, Australia

Postby monks » Thu Dec 01, 2005 10:59 am

Hi Aaron- I'll post my reply here as well for the sake of clarity for board discussion

I've been using x8 textures, but the problem was still the same with x1... that's what I originally found anyway. The texture format has been left at the default. (didn't know it could be changed).
HOWEVER, I've just opened up an mgf where the terracing has been previously removed. One of the mgfs used for the gallery shots on ME-DEM. It has a x8 texture. It has the problem.
So I re-did it (went and regenerated all of the maps from heightmap onwards but changed the texture to x1 resaved it under a different name in its own folder. It opened perfectly 4 times on the trot.
I redid it with x8 texture, saved in its own folder. Problem again.
I redid it once again- using a x4 texture, saved in it's own folder. It opened fine.
I redid it again, own folder at x8 texture. Problem.

I did think it might be a problem of saving mgfs in the same directory so I tested for that yesterday and that was not the problem. I saved two identical files both generated from the same parent, one saved in the parent directory, the other in its own. Both had the problem -both had x8 textures though.

Add to that, the fact that I have had x8 textures open up in TVi2- the gallery shots on ME-DEM are proof of that ! - though it did have problems getting at them. My problems seemed to start as soon as I tried to change the lighting (sun angle)- I originally thought it was this. With the exception of 1 or 2 mgfs (out of maybe 30) all of my tests have been at x8 texture. My previous post is further proof. Open a file OK, open it again, not OK.

I have 2GB mem, 256 Mb card. There is possibly a question mark over 1 of the gig sticks I have in there. It could be that. I've had a similar problem in Leveller before now, where I was pushing the limit with a 10K square file. Sometimes they would open, sometimes not. Sounds suspiciously similar. I did a RAM test and it showed errors in one of the modules. Could it be that the larger memory space required for the texture is increasing the odds of access to those dodgy memory addresses ? From that reasoning, wouldn't I have the same problem (just less chance) with ANY texture ? Confused.
Also, I have McAfee virus scan software running- I disabled it but the problems were the same.
OK, enough speculation :) I've attached from those last tests in my email.
Parent (x8 tex)
child 1 x8
child 2 x4

Update// one problem I did iron out was the fact that my heightmap export format in preferences was set to Terragen. I did this in order to get the terrain into Leveller. So I was getting mgfs with no hff at one point which was adding to my problem !. That was solved.

Cheers
monks
Oracle
 
Posts: 292
Joined: Tue Nov 22, 2005 10:38 pm
Location: Middle Earth

Postby Aaron » Fri Dec 02, 2005 4:36 am

monks wrote:I have 2GB mem, 256 Mb card.


I think you ran out of memory on your GFx card. An 8x texture for a 1024x1024 heightmap is exactly 256Mb. It might help if you split the texture into tiles.

Cheers,
Aaron.
User avatar
Aaron
Site Admin
 
Posts: 3691
Joined: Sun Nov 20, 2005 2:41 pm
Location: Melbourne, Australia

Postby monks » Sun Dec 04, 2005 12:47 pm

AHA !
I posted just the parent file again today- I think it finally went through. I was thinking about trying that option in the texture creation- that's pretty much the one thing I thought of trying but didn't - sod's law !

Oh my- looks like I need a new grafix card- new motherboard- new RAM- new CPU....UGH - good job we have L3DT eh ? :P
monks
Oracle
 
Posts: 292
Joined: Tue Nov 22, 2005 10:38 pm
Location: Middle Earth

Postby monks » Sun Dec 04, 2005 12:52 pm

...well it looks like the files may have been blocked again :evil: It must be my McAfee that's up to no good- I thought it was security, not house-arrest !
I'll try the tiling to check that.
monks
Oracle
 
Posts: 292
Joined: Tue Nov 22, 2005 10:38 pm
Location: Middle Earth

Postby Aaron » Sun Dec 04, 2005 4:28 pm

monks wrote:Oh my- looks like I need a new grafix card- new motherboard- new RAM- new CPU....UGH - good job we have L3DT eh ? :P


Whoa, please don't upgrade on L3DT's account! You really don't need a fancy box to run this software; I'm still using an elderly 2.1GHz AMD with 512Mb RAM and an el-cheapo 128Mb graphics card, and it runs L3DT and L3DTVi2 just fine. I usually resort to tiling for any map larger than about 2k x 2k, but even with a couple of gig's of RAM I'd still need to tile anything larger than about 4k x 4k, so it's no biggie.

Cheers,
Aaron.
User avatar
Aaron
Site Admin
 
Posts: 3691
Joined: Sun Nov 20, 2005 2:41 pm
Location: Melbourne, Australia

Postby Aaron » Tue Dec 06, 2005 4:21 pm

Hi Monks,

Yup, it looks like the only problem with your map was that the texture was too large to hold in video memory. I tried your map with the 8x texture in L3DTVi2 using my 128Mb card and it gave a black heightmap as you found. I then loaded the map in L3DT and split the texture into a mosaic (see http://www.bundysoft.com/L3DT/tute/tute_ops.php#mosaic_split). With the tiled texture thus, the map loaded in L3DTVi2 just fine.

Cheers,
Aaron.
User avatar
Aaron
Site Admin
 
Posts: 3691
Joined: Sun Nov 20, 2005 2:41 pm
Location: Melbourne, Australia


Return to Bug reports

Who is online

Users browsing this forum: No registered users and 2 guests

cron