Jump to content
Sign in to follow this  
VovoNauta

mask_Ico has a limit of 4 layers?

Recommended Posts

no such thing as Mask_lco its Sat_LCO and Mask_LCA look in BIS pBO`s ,

However there is always a BUT , it is not documented as to wheter the LCA meeds Visitor 4 for the use of the Alpha to work properly.

Share this post


Link to post
Share on other sites
no such thing as Mask_lco its Sat_LCO and Mask_LCA look in BIS pBO`s ,

However there is always a BUT , it is not documented as to wheter the LCA meeds Visitor 4 for the use of the Alpha to work properly.

Mask_lco works. I use Mask_LCO. Your mask_lco can have more than 4 colors in it. However, it cannot have more than 4 colors per segment. It is possible to have more than 4 colors per segment but it is tricky and I have never tried it yet.

Share this post


Link to post
Share on other sites

yes it works , but I have never seen a BIS map use mask_LCO extension on there map , I only ever saw mask_LCA , so in relation to more than 4 colour I presume LCA as per bis map uses alpha for more and possibly Visitor 4 ?

Share this post


Link to post
Share on other sites

BI currently use a "mysterious process" involving .lcA (alpha) format Sat & Mask tiles, plus .rvmat rewriting/fudging in order to achieve SIX "colours per segment", as opposed to the usual FOUR...

It's a lot of fuss, and I've yet to successfully pull it off myself, but I'm assured it can be done...

However, for most terrain work, and certainly, unless you want to get involved with lca's, uvTransforms, and rvmat craziness - you'd be well advised to stick to the traditional, and fully-automated-within-Visitor "FOUR colours per segment"

You can still do a lot with that, and still retain the hair you'd otherwise lose trying to hack the 6-colour thing :D

See eg: CWR2 Malden for an example of a 12x12km terrain with FOURTEEN different ground textures in use (and only one or two "conflict areas", which I'll fix... honest! ;)... or CWR2 Everon with TWELVE (and, happily, no "conflict areas" at all) :) !.....

B

Share this post


Link to post
Share on other sites

well im not totally sure they use as much as six but maybe 5 , However a look at BIS rvmats and LCA would soon establish what and how there doing it .

I know Mike Bart did a lot of looking into it some years ago not sure what he found.

Again , I believe they use VIS 4 anyway , I am using TOH and already I have had to update the BIN pbo config Bin many times because whats in there is very old, so I guess when people try things in those tools when Binarising OA things its a wonder they work sometimes.

Share this post


Link to post
Share on other sites
"FOUR colours per segment"
"

tks, but I still do not get these 4 colors SEGMENT. Could someone explain it more detailed.

-how to work "four colors per segment"?

EDITED:

I think I'm beginning to understand, if I'm wrong, please correct.

-I made a grid placed it on my mask_Ico.

-part of my mask_ico with overlapping segments:

http://i42.photobucket.com/albums/e327/kareca/Mask.jpg (122 kB)

-Each square is a segment.

-In each segment of this I can put four colors (respecting areas that overlap)

(My mask_ico: segment 512x512, 10240x10240)

Is it?

Tks, sry.

Edited by VovoNauta

Share this post


Link to post
Share on other sites

6 colors per segment is the limit. Visitor3 does not offer any way of automatically converting and creating the correct .rvmat files.

However you can "patch" single segments by hand afterwards. I did so for Celle 2, so it is very much possible with the current tools. Painful slow and not really efficient, but possible. :)

Share this post


Link to post
Share on other sites
Each square is a segment.

-In each segment of this I can put four colors (respecting areas that overlap)

That's it! Exactly!! Well done!

Yes - a grid to match the "tiles" that Visitor makes when it slices your mask up - the limit is 4 colours - in each of those segments (respecting borders, as you said)!

B

Share this post


Link to post
Share on other sites

@mondkalb: what did you do manually???? tweaking rvmats inside layers folder??? did you use an LCA??? would you show us some ref rvmat??? c'mon mondy!!! c'mon!!! would you????

Share this post


Link to post
Share on other sites

All I did was have a look at the utes layer .paa files and the related .rvmats.

But here's the excerpt from Celle 2:

First the _lca texture, left RGBA, right Alpha:

\mbg\mbg_celle2_data\data\layers\M_009_010_lca.paa

Basically the first four Colors in the RGB map are your first four detail textures, the other two detail textures are stored in the alpha map, one being the alpha value of 0, the other being 127. In future this may become used elsewhere. (Normal map, hint).

\mbg\mbg_celle2_data\data\layers\P_009-010_L00_L01_L02_L04.rvmat

ambient[]={0.89999998,0.89999998,0.89999998,1};
diffuse[]={0.89999998,0.89999998,0.89999998,1};
forcedDiffuse[]={0.02,0.02,0.02,1};
emmisive[]={0,0,0,0};
specular[]={0,0,0,0};
specularPower=0;
class Stage0
{
texture="mbg\mbg_celle2_data\data\layers\s_009_010_lco.paa";
texGen=3;
};
class Stage1
{
texture="mbg\mbg_celle2_data\data\layers\m_009_010_lca.paa";
texGen=4;
};
class TexGen3
{
uvSource="worldPos";
class uvTransform
{
	aside[]={0.0009765625,0,0};
	up[]={0,0,0.0009765625};
	dir[]={0,-0.0009765625,0};
	pos[]={-8.40625,2.65625,0};
};
};
class TexGen4
{
uvSource="worldPos";
class uvTransform
{
	aside[]={0.0009765625,0,0};
	up[]={0,0,0.0009765625};
	dir[]={0,-0.0009765625,0};
	pos[]={-8.40625,2.65625,0};
};
};
class TexGen0
{
uvSource="tex";
class uvTransform
{
	aside[]={1,0,0};
	up[]={0,1,0};
	dir[]={0,0,1};
	pos[]={0,0,0};
};
};
class TexGen1
{
uvSource="tex";
class uvTransform
{
	aside[]={10,0,0};
	up[]={0,10,0};
	dir[]={0,0,10};
	pos[]={0,0,0};
};
};
class TexGen2
{
uvSource="tex";
class uvTransform
{
	aside[]={10,0,0};
	up[]={0,10,0};
	dir[]={0,0,10};
	pos[]={0,0,0};
};
};
PixelShaderID="TerrainX";
VertexShaderID="Terrain";
class Stage2
{
texture = "#(rgb,1,1,1)color(0.5,0.5,0.5,1,cdt)";
texGen = 0;
};
class Stage3 //Black
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_grass_nopx.paa";
texGen=1;
};
class Stage4 //Black
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_grass_co.paa";
texGen=2;
};
class Stage5 //Red
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_forest_nopx.paa";
texGen=1;
};
class Stage6 //Red
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_forest_co.paa";
texGen=2;
};

class Stage7 //Green
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_sand_nopx.paa";
texGen=1;
};
class Stage8 //Green
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_sand_co.paa";
texGen=2;
};

class Stage9 //Blue
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_gravel_nopx.paa";

texGen=1;
};

class Stage10 //Blue
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_gravel_co.paa";

texGen=2;
};

class Stage11 //Alpha 50
{
texture="ca\chernarus\data\cr_beton_detail_nopx.paa";
texGen=1;
};

class Stage12 //Alpha 50
{
texture="ca\chernarus\data\cr_beton_detail_co.paa";
texGen=2;
};

class Stage13 //Alpha 0
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_cobblestone_nopx.paa";
texGen=1;
};

class Stage14 //Alpha 0
{
texture="mbg\mbg_celle2_data\data\mbg_celle2_cobblestone_co.paa";
texGen=2;
};

Chernarus and Utes use this for all tiles, so they are the ones to look out for as additional references.

Share this post


Link to post
Share on other sites
in future this may become used elsewhere. (normal map, hint).

sledgehammer "hint" ;) .

Painful slow and not really efficient, but possible.

Yeah - you'd really need to want 6 colours badly... and not really practical to do manually for a whole terrain...

B

Share this post


Link to post
Share on other sites

Very good. (6 colors per segment)!! (one segment or another may need more than 4 textures and not the whole map (good))

1) m_009_010.lco -> m_009_010.Lca : what's the difference?

2) what are files .lca

class Stage12 //Alpha 50

alpha 50 = 50% opacity?

alpha 0 = 0% opacity?

the other two detail textures are stored in the alpha map

- (segment per segment? create alpha channel?)

-how would the file layers.cfg (section class colors)?

- Mondkalb u can post u file layers.cfg (mbg_celle2)?

tks.

Edited by VovoNauta

Share this post


Link to post
Share on other sites

Thank you mondy <3

That's precisely the kind of job for a 5th texture...

But I do not understand how the engine can distinguish values coming from alpha channel, how engine deals with LCA...

Afaik in layers.cfg you define color values corresponding to a given texture... how do you manage alpha then?

What does layers.cfg say then? Do you add an alpha value in RGB colors definition list there?

Share this post


Link to post
Share on other sites

I hand edited this particular .paa file.

Everything that is visible (255 in alpha channel), will be picked from the four basic colors. If something is at 127 in the alpha channel (50%), it will be the "5th color". 0 in alpha channel (0%) will be the "6th color".

In total I "hacked" seven tiles on Celle 2.

Share this post


Link to post
Share on other sites

So far so ok but what is hard to understand how the engine works is this:

1 - I edited my arquivo.paa (created Alpha channel)

2 - I edited file rvmat

questions:

1 - wich establish the color to bind the texture (layers.cfg file)?

2 - Whenever I run the dozer he creates new segments and new files. Png and. Paa overlapping those edited (hacked).

3- How to prevent this?

Mondkalb u can post u file layers.cfg (mbg_celle2)?

===============

class Legend

{

picture="prc\Mymap\source\mapLegend.png";

class Colors

{

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

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

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

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

// prc_stones[]={{1.000,0.000,0.000 1.000}}; <<<<<====== what to put here for the fifth texture?

};

};

===============

tks.

Edited by VovoNauta

Share this post


Link to post
Share on other sites

@Mondkalb:

That means LCA only apply to those tiles "hacked" as you say, and the rest of them remain as LCO, am I right?

EDIT: FATA will have a better looking wheatfield area :)

@VOVO: I think is clear enough now... :p

1. As far as I understand you do not have to bind anything in layers.cfg... for these purposes you have to leave it as it is... read again what Mondy <3 said hahaha alpha tiles would add ref values automatically -> 0, 127, 255 = black, gray, white (in this last case alpha should be off)

2-3. ok, you have to replace those files manually BEFORE launching buldozer... get rid of PNG files inside layers folder and then replace corresponding LCO for your new shiny LCAs... if you do not delete png files, buldozer will convert them into paa again replacing your "hacked" tiles...

If you do not know how to get an LCA file just modify your png tile put your alpha in there and then convert it using pal2pac... I think it's important to change png file name sufix _LCO and rename it as _LCA so pal2pac can make a proper conversion...

I will try this all later... I hope not to be wrong with my assumptions...

Saludos!

Edited by Robster

Share this post


Link to post
Share on other sites

The layers.cfg is unimportant to hacking single texture tiles to use 6 colors. Everything happens on a "per tile" base. In my case I did that as the final step before release. This way I was sure that the change I made weren't lost if I had to re-import the sat map.

Share this post


Link to post
Share on other sites
The layers.cfg is unimportant to hacking single texture tiles to use 6 colors. Everything happens on a "per tile" base. In my case I did that as the final step before release. This way I was sure that the change I made weren't lost if I had to re-import the sat map.

TKS Mondkalb!

Finally!! Working with 6 textures!

=====================

(sry my english)

STEP BY STEPS TO WORK WITH 6 TEXTURES per SEGMENT:

- Tks Mondkalb

I'm using Mask_LCO and Sat_LCO

1 - ATTENTION!

No need to change anything in your file layers.cfg!

He will be alone with the 4 basic trexturas.

The engine uses the file rvmat changed (conf below EDITING The RVMAT)

to put the 2 new textures ALPHA CHANNEL.

-If you want to change the 5 or 6th texture will have to change them in the file rmvat

2 - Run the bulldozer;

-Save the mymap.wrp;

-Save the mymap.pew;

NOTE: you do not see running bulldozer textures Alpha channel, only in the game you will see

3 - In the Layers folder, locate the segment you want to add (s) texture (s);

(Example: M_011_015_LCO.paa)

4 - Open with TexView2

5 - In the drop down menu select the right ALPHA

(It will open the alpha channel right all blank)

texview.jpg

6 - Save as M_011_015_LCA.tga

7 - open it with Photoshop

8 - note the tab CHANNEL Photoshop that already is the alpha channel.

9 - the RGB channel select the area you want to put the new texture

10-click the Alpha Channel

11-paint the selected area with black (100% opacity)

(For 6th texture select area and slide the marker to 50% and paint)

12-save as tga

13 - open this tga with TexView

Edited.jpg

14 - Save as M_011_015_LCA.paa folder LAYERS

EDITING The RVMAT

1 - locate the folder layers corresponding to the edited segment rvmat

2 - open with notepad

3 - change (red detail) the Class Stage0 to .... texture="mbg\mbg_celle2......s_009_010_LCO.paa (Example Mondkalb)

4 - change the Class Stage1 to .....texture="mbg\mbg_celle2M_009_010_LCA.paa (Example Mondkalb)

5 - change the Class Stage2 for:

class Stage2

{

texture = "# (rgb, 1,1,1) color (0.5,0.5,0.5,1, cdt)";

texGen = 0;

};

6 - For each texture leave only the stages that contains the file NOPX and CO

7 - keep the numbering of the stages in the correct sequence

8 - Include two more stages for the FIFTH TEXTURE

Example Mondkalb:

Stage11 class / / Alpha 50

{

texture = "ca \ Chernarus \ data \ cr_beton_detail_nopx.paa";

texGen = 1;

};

Stage12 class / / Alpha 50

{

texture = "ca \ Chernarus \ data \ cr_beton_detail_co.paa";

texGen = 2;

};

9 - Include two more stages to 6ª TEXTURE (Alpha 0)

10 - Save your rvmat layers folder and make a copy in another folder

(In case you run the dozer again and not have to edit it)

11 - Do not run the dozer.

12 - Run the BinPbo

13 - get in the game and make sure the textures are correct.

Tks all!

Edited by VovoNauta

Share this post


Link to post
Share on other sites

Many thanks Vovonauta! You put it all pretty nice & clear...

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  

×