Jump to content
Sign in to follow this  
AASE

Importing Sat and layer mask

Recommended Posts

Hey i have tried searching but i cant find anything that fixes this problem for me.

I am working on just a basic map to figure out visitor using the visitor 3 tut but when i try to import my Sat and Layer mask it dose for a fair bit then crashes at around 60 to 70 % of the way.

here what my codes and stuff.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">ambient[]={0.900000,0.900000,0.900000,1.000000};

diffuse[]={0.900000,0.900000,0.900000,1.000000};

forcedDiffuse[]={0.020000,0.020000,0.020000,1.000000};

emmisive[]={0.000000,0.000000,0.000000,0.000000};

specular[]={0.000000,0.000000,0.000000,0.000000};

specularPower=1.000000;

PixelShaderID="NormalMapDiffuse";

VertexShaderID="NormalMapDiffuseAlpha";

//surfaceInfo = "landtext/bumps.bisurf";

class Stage1

{

texture="kandahar\data\pisekplaz_detail_nohq.paa";

uvSource="tex";

class uvTransform

{

aside[]={10.000000,0.000000,0.000000};

up[]={0.000000,10.000000,0.000000};

dir[]={0.000000,0.000000,10.000000};

pos[]={0.000000,0.000000,10.000000};

};

};

class Stage2

{

texture="kandahar\data\pisekplaz_detail_co.paa";

uvSource="tex";

class uvTransform

{

aside[]={10.000000,0.000000,0.000000};

up[]={0.000000,10.000000,0.000000};

dir[]={0.000000,0.000000,10.000000};

pos[]={0.000000,0.000000,10.000000};

};

};

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">ambient[]={0.900000,0.900000,0.900000,1.000000};

diffuse[]={0.900000,0.900000,0.900000,1.000000};

forcedDiffuse[]={0.020000,0.020000,0.020000,1.000000};

emmisive[]={0.000000,0.000000,0.000000,0.000000};

specular[]={0.000000,0.000000,0.000000,0.000000};

specularPower=1.000000;

PixelShaderID="NormalMapDiffuse";

VertexShaderID="NormalMapDiffuseAlpha";

//surfaceInfo = "landtext/bumps.bisurf";

class Stage1

{

texture="kandahar\data\travajih_detail_nohq.paa";

uvSource="tex";

class uvTransform

{

aside[]={10.000000,0.000000,0.000000};

up[]={0.000000,10.000000,0.000000};

dir[]={0.000000,0.000000,10.000000};

pos[]={0.000000,0.000000,10.000000};

};

};

class Stage2

{

texture="kandahar\data\travajih_detail_co.paa";

uvSource="tex";

class uvTransform

{

aside[]={10.000000,0.000000,0.000000};

up[]={0.000000,10.000000,0.000000};

dir[]={0.000000,0.000000,10.000000};

pos[]={0.000000,0.000000,10.000000};

};

};

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">ambient[]={0.900000,0.900000,0.900000,1.000000};

diffuse[]={0.900000,0.900000,0.900000,1.000000};

forcedDiffuse[]={0.020000,0.020000,0.020000,1.000000};

emmisive[]={0.000000,0.000000,0.000000,0.000000};

specular[]={0.000000,0.000000,0.000000,0.000000};

specularPower=1.000000;

PixelShaderID="NormalMapDiffuse";

VertexShaderID="NormalMapDiffuseAlpha";

//surfaceInfo = "landtext/bumps.bisurf";

class Stage1

{

texture="kandahar\data\skalaj_detail_nohq.paa";

uvSource="tex";

class uvTransform

{

aside[]={10.000000,0.000000,0.000000};

up[]={0.000000,10.000000,0.000000};

dir[]={0.000000,0.000000,10.000000};

pos[]={0.000000,0.000000,10.000000};

};

};

class Stage2

{

texture="kandahar\data\skalaj_detail_co.paa";

uvSource="tex";

class uvTransform

{

aside[]={10.000000,0.000000,0.000000};

up[]={0.000000,10.000000,0.000000};

dir[]={0.000000,0.000000,10.000000};

pos[]={0.000000,0.000000,10.000000};

};

};

Layers.CFG

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class Layers

{

class pisekplaz

{

texture = "kandahar\data\pisekplaz_mco.paa";

material="kandahar\data\pisekplaz.rvmat";

};

class skalaj

{

texture = "kandahar\data\skalaj_mco.paa";

material="kandahar\data\skalaj.rvmat";

};

class travajih

{

texture = "kandahar\data\travajih_mco.paa";

material="kandahar\data\travajih.rvmat";

};

};

class Legend

{

picture="kandahar\source\mapLegend.png"

};

class Colors

{

pisekplaz[]={{255,255,0}};

skalaj[]={{255,0,0}};

travajih[]={{0,255,0}};

};

};

my Sat and layers mask are the same size at 512 by 512.

Thanks

AASE

Share this post


Link to post
Share on other sites

The most likely cause of this, and therefore the first thing you should think of, is that the Mask image has too many colours, and should only have 4 colours.

Now, to qualify that, you can have more than 4 colours, indeed you can have as many as you wish, but you must ONLY have 4 in any one map segment. So if you're unsure what represents a map segment just now, I suggest making the Mask image ONLY 4 colours just to be sure. This is what I did and from there, once I got a working map, I expanded the number of colours.

This means that you use solid chunks of colour with NO aliasing between the colours, just 4, discrete, colours. Use the pencil tool instead of the paint tool with maximum hardness.

Share this post


Link to post
Share on other sites

Make sure both your Sat and Mask are RGB (24bit) colour. I get this crash when I forget to convert my mask map from 8bit to RGB.

Share this post


Link to post
Share on other sites

i cant select 24 bit with my photo shop for some reseon only 8 and 16

Share this post


Link to post
Share on other sites

Probably should have left the 24bit remark out, sorry to confuse you. Keep the mode on RGB, don't change the lower option on the mode list to 16, keep it on 8 when working with Sat\Mask images.

Share this post


Link to post
Share on other sites

yeah thats what i had before and it was still crashing was RGB and 8 bit

Share this post


Link to post
Share on other sites

Trying comparing your files\images to BIS's Rahmadi sample map. Might be able to troubleshoot what's causing your crash that way..

Share this post


Link to post
Share on other sites

your images, bck.bmp, Sat_lco.png and the Mask_lco.png must be in 24bit.

Worked fine for me with 24 bit and had problems with different bits

Share this post


Link to post
Share on other sites

Photo shop wont let me put them into 24 bit for some reason.

Share this post


Link to post
Share on other sites

Ok my images are saved at RGB at 8 bit and they crash and i tried RGB at 16 bit and still crash

Share this post


Link to post
Share on other sites
Ok my images are saved at RGB at 8 bit and they crash and i tried RGB at 16 bit and still crash

I say again: You need 24bit! not 6,8 or 16 nor 32.

24! I had same problem and i have to use 2 programs to edit the images. Fireworks to save to 24bit, because i couldn't also find a option to save in 24bit.

Share this post


Link to post
Share on other sites

you need a 8bit per color picture. => 24 bit.

8 bit Red , 8bit Green , and 8bit blue.

in photoshop , you must use 8bit per color, in mode RGB .

Share this post


Link to post
Share on other sites
Ok my images are saved at RGB at 8 bit and they crash and i tried RGB at 16 bit and still crash

your problem is elsewhere.

Share this post


Link to post
Share on other sites

Any one have any ideas on how to fix this problem?

Share this post


Link to post
Share on other sites

Jesus.. i think you need to clean your glasses!

People already told you what was the problem and how to fix it.

Now its up to you to fix it..

I say for the 3rd time and last time!

<span style='font-size:15pt;line-height:100%'>You need to save all images (Mask_lco.png, Sat_lco.png and background.bmp) with 24bit!</span>

If your Photoshop does not have that option (like mine), get a program such as Fireworks to save with 24bit. Else you will have the same error.

Over and out.

edit: typo

Share this post


Link to post
Share on other sites

Actually 24bit is a bit misleading...

It's more 8bits per RGB channel = 24bits. Hence if it's already in RGB (mind you not in CMYK mode, or Bitmap mode, or Greyscale mode or Lab mode) it is probably not the problem.

As far as I know, no version of Photoshop (or any other competitor) actually saves images in 24 bits per channel, recent versions offer 16 bit per channel, but it's overkill for many uses.

Being a problem with png, it could be a question of interlaced picture ? that's an option when saving to png but I don't know if that's a problem with visitor.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×