Game Development Community

Atlas map.

by Thomas Salisbury · in Torque Game Engine Advanced · 07/24/2009 (4:28 pm) · 13 replies

I am trying to load an atlas map with the atlas demo. I created the map, and exported it using the plugin. When I exported it I over wrote the existing atlas map that the demo is supposed to be using, but it still loads the existing map, doesn't load the one I exported.

It there something I am missing? Is the map file actually something else. I would think if I over wrote the existing map file it should load it?

#1
07/27/2009 (3:03 pm)
Nobody? I am sure someone has done this at least once......
#2
07/28/2009 (3:55 am)
All I can offer is...Are you sure you saved over the original file?
This sounds like a simple mistake.

If you have Torsion then open the atlasdemo.torsion project and browse to the game\scriptsAndAssets\data\terrains folder and right click on the terrains folder and select explore and check to make sure that the atlas file has a recent modified date to see if you overwrote it.
#3
07/28/2009 (4:26 am)
Another thing I just thought of is which plugin did you use?
If we are talking about the 2 for L3DT then depending on which one you used the export could have failed and L3DT would not have reported an error.

The Torque Atlas2 plugin lets TGEA do the heavy lifting by placing all the relevant data(bitmaps and RAW height data) in a folder below were the TGEA executable is. It then creates a script file for TGEA to use for the conversion and then executes TGEA with the script file as an argument causing it to start the export. If for any reason the script runs into a problem L3DT won't know about it. Usually it fails on the RAW 16bit to CHU conversion.
The only way to know for sure is right after you run the export and TGEA gets done running open up the console.log file and see if it reported any errors.

The Torque Atlas(legacy) plugin uses the TGEA library code to create the atlas file and can do a better job of reporting errors.
The only problem with this plugin is that is based off of the 1.0.3 version of TGEA and produces some very inefficient atlas files(the texture data suffers from very poor compression).


P.S.
I have updated the legacy pluging based off of TGEA 1.7.1 and the files it creates are significantly smaller to the 1.0.3 version.
I haven't released it yet but will be soon.
#4
07/28/2009 (5:00 am)
ok, I will try the export again, and look at the log file directly after.
#5
07/28/2009 (5:55 am)
here is the log file
//-------------------------- 7/28/2009 -- 07:54:06 -----
Starting Atlas Build!


Generating chunked geometry (depth=4, baseMaxError=2.500000)
   o Calculating activation levels...
      - done.
   o Propagating activation levels...
      - done.
   o Writing file header...
      - done.
   o Generating empty TOC...
      - done.
   o Generating meshes...
AtlasOldActivationHeightfield::generateNodeData - Max exceeded! May have paging issues!
AtlasOldActivationHeightfield::generateNodeData - Min exceeded! May have paging issues!
AtlasOldActivationHeightfield::generateNodeData - Max exceeded! May have paging issues!
AtlasOldActivationHeightfield::generateNodeData - Min exceeded! May have paging issues!
AtlasOldActivationHeightfield::generateNodeData - Min exceeded! May have paging issues!
AtlasOldActivationHeightfield::generateNodeData - Max exceeded! May have paging issues!
      - done.
=== Chunk Statistics ===\
\===== Level    Count    Avg. Size
            0          64      3793.562500
            1          16      14737.687500
            2           4      33955.000000
            3           1      66836.000000
========================================
                chunks:         85
           input verts:    1048576
          output verts:      73390

       avg verts/chunk:        863
NOTE: verts/chunk is low; for higher poly throughput consider setting the tree depth to 3 and reprocessing.
          output bytes:       3173
      bytes/input vert:       0.00
     bytes/output vert:       0.04
        real triangles:     681247
AtlasDeferredFile::ensureStreamWritable - switching file into writable mode... This may cause a crash if you have other copies of Torque accessing it!
importOldAtlasCHU - created new Atlas file 'scriptsAndAssets/data/terrains/deleteme/geom.atlas'
importOldAtlasCHU - Atlas file initialized, converting...
importOldAtlasCHU - Headers read, remapping chunks...
importOldAtlasCHU - Importing geometry chunks...
importOldAtlasCHU -    level 3 chunks...
importOldAtlasCHU -    level 2 chunks...
importOldAtlasCHU -    level 1 chunks...
importOldAtlasCHU -    level 0 chunks...
AtlasFile::waitForPendingWrites - Waiting for pending output to finish.
AtlasFile::waitForPendingWrites - Done!
importOldAtlasCHU - import OK!
AtlasFile::waitForPendingWrites - Waiting for pending output to finish.
AtlasFile::waitForPendingWrites - Done!
atlasGenerateTextureTOCFromTiles - Initializing atlas file 'scriptsAndAssets/data/terrains/deleteme/tex.atlas'...
AtlasDeferredFile::ensureStreamWritable - switching file into writable mode... This may cause a crash if you have other copies of Torque accessing it!
atlasGenerateTextureTOCFromTiles - Atlas started, processing tiles for 4 deep tree...
atlasGenerateTextureTOCFromTiles - Storing tiles in JPEG format...
#6
07/28/2009 (5:58 am)
Is that the whole console.log?
#8
07/28/2009 (7:35 am)
Well in that case this may be your problem.

The solution can be found here.
#9
07/28/2009 (1:09 pm)
ok, got that... How do I use that BAT(thats in the source code folder) file to re-compile the source?
#10
07/28/2009 (1:14 pm)
I use Visual studios to compile the source.
Haven't look in to using the batch file before.
#11
07/28/2009 (1:16 pm)
ok. I will keep using VS then. just takes so long. :)
#12
07/28/2009 (6:16 pm)
You don't have to completely recompile the whole engine.
If you edit a class like say AtlasInstance you just have to choose build solution instead of rebuild solution.
#13
07/28/2009 (6:59 pm)
o hell. lol. That makes things MUCH easier.