Author Topic: Strip - in reply to this post in the bug thread....  (Read 1592 times)

Offline Waffle

  • HTC Staff Member
  • Administrator
  • *****
  • Posts: 4849
      • HiTech Creations Inc. Aces High
Strip - in reply to this post in the bug thread....
« on: August 31, 2009, 08:45:47 AM »

Open gndtype.bmp with some sort of photo editing software.
Use eyedropper or set RGB to specific value and change whole bmp to that color, save to proper folder.
Open TE, load proper file and the change will not show up.

It does not look like the manual changes made to the gndtype.bmp show up properly. The displayed terrain ends up looking like a blend of two types. It certainly doesn't look like any of the the main terrain tiles. Can anyone else replicate this? All of the issues so far can be duplicated.

Strip


Your graphic program is probably changing the rgb values of the color when saving.

to test this, open your saved greyscale image in MS PAINT and check on the RGB value there. It's probably off  from what you had in the graphics program.



Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Strip - in reply to this post in the bug thread....
« Reply #1 on: August 31, 2009, 09:27:24 AM »
Your graphic program is probably changing the rgb values of the color when saving.

to test this, open your saved greyscale image in MS PAINT and check on the RGB value there. It's probably off  from what you had in the graphics program.
Waffle,
I opened both the output file and my input file, the RGB values line up perfectly with your list. Saving in 256 color bmp....is this right? Its what the output file is too.

Starting with a new terrain...
Erased some water and added areas of different land types....
Saved and closed TE...
Opened the gndtype.bmp...

I get two colors, 68 and 0, no difference with the amount of tile types placed either.

Strip



Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Strip - in reply to this post in the bug thread....
« Reply #2 on: August 31, 2009, 09:28:21 AM »
Trying this out from a different angle now...

Starting with a new terrain, btw I have done all this with saved terrains too....
Erased some water..
Saved and closed TE...
Open gndtype.bmp and made color changes with different RGB values from the list..... (MSPaint)
Saved bmp in 256 color mode (same format its output in)

Open TE and all changes show up as whitish sand (not terrain I can create with blends or normal tiles)

I have done this in MSPaint, Ultimate Paint, GIMP 2, and Open Paint

Any thoughts?

Strip

Offline Waffle

  • HTC Staff Member
  • Administrator
  • *****
  • Posts: 4849
      • HiTech Creations Inc. Aces High
Re: Strip - in reply to this post in the bug thread....
« Reply #3 on: August 31, 2009, 09:31:28 AM »
save and edit in grayscale, dont work in color rgb. There should be a "convert to grayscale" option on one of those programs.


« Last Edit: August 31, 2009, 09:33:07 AM by Waffle »

Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Strip - in reply to this post in the bug thread....
« Reply #4 on: August 31, 2009, 09:49:15 AM »
save and edit in grayscale, dont work in color rgb. There should be a "convert to grayscale" option on one of those programs.

No change...

Even tho I could be saving in the wrong format shouldn't different shades show up for the separate tile types after saving?

Right now it seems like no matter what changes I make in the TE the only the thing that shows up is the rough shape of changes in the gndtype.bmp

Sounds like its working fine on your computer so I am gonna try a fresh download/install and try it out again.

Strip

Offline Waffle

  • HTC Staff Member
  • Administrator
  • *****
  • Posts: 4849
      • HiTech Creations Inc. Aces High
Re: Strip - in reply to this post in the bug thread....
« Reply #5 on: August 31, 2009, 10:23:30 AM »
try this:

open gndtype.bmp on a map you're working on.

paint the entire thing rgb 68,68,68.

save it as 8 bit grayscale.

open the map in AHTE.

Erase water.

Where you erased water - you should see farm 1.

Does that work?

Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Strip - in reply to this post in the bug thread....
« Reply #6 on: August 31, 2009, 11:05:09 AM »
I just got the fresh install up and running...........ran everything again like before and it works as advertised now. It will show changes made in TE on the gndtype.bmp now as well. Sometimes I really would like to shoot every computer I see.

:confused: :furious

Thanks for working with me, hope you didn't spend to much time on this. I must say this TE has a bunch of useful tools and excellent visual abilities. We have just scratched the surface and it seems like the possibilities are endless.

 :salute

Strip

Offline ghostdancer

  • Aces High CM Staff
  • Platinum Member
  • ******
  • Posts: 7562
Re: Strip - in reply to this post in the bug thread....
« Reply #7 on: August 31, 2009, 11:20:23 AM »
In photoshop your grayscale colors will change as soon as you save it to a BMP.

Say you set some beach area (rgb color of 170,170,170) in a layer above another layer with say water (rgb color of 0,0,0). Then you set some farm 1 (rgb color of 68,68,68). When you save the file to a BMP (doesn't matter if you save direct, or first index and or if you flatten the image then save as a bmp the colors will shift.

- 170,170,170 shifts to 151,151,151
- 68,68,68 shifts to 49,49,49

So for photoshop when using multiple layers:

1) Make sure you are working in grayscale mode.
2) Save your work to a PSD file. This is important because you want to save your individual layers for later work.
3) Then flatten your image.
4) Then go and sample your individual an area (beach).
5) Then click on image and select color range from the drop down menu.
6) Make sure the fuzziness is set to 0 and then click okay. This will select all of that color in your image.
7) Change your color value to 170,170,170 in your color palette.
8) Click on Edit in the tool bar and then fill. Make sure the Use: says Foreground Color and then hit OK.

This will replace any pixel that had a color value of 151,151,151 to 170,170,170.

Repeat the process for the other color areas you set. After you do this then save as grndtype.bmp.
4) After doing this click on save as, select the format BMP and then save it as grndtype.bmp.
X.O. 29th TFT, "We Move Mountains"
CM Terrain Team

Offline Waffle

  • HTC Staff Member
  • Administrator
  • *****
  • Posts: 4849
      • HiTech Creations Inc. Aces High
Re: Strip - in reply to this post in the bug thread....
« Reply #8 on: August 31, 2009, 11:27:44 AM »
or you can go to your color settings (cntrl + shift +k) and make sure your grayscale mode under working spaces is set to sgray.
It will save your rgb values as they are when you draw them in photoshop.

You just have to use "save as" and save as .bmp, then 8 bit.
« Last Edit: August 31, 2009, 11:29:21 AM by Waffle »

Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Strip - in reply to this post in the bug thread....
« Reply #9 on: August 31, 2009, 11:37:29 AM »
Well, I know one issue was with the T.E. export gndtype.bmp not even showing any changes.

That is now fixed, and without changing any of my process everything works. I was saving in 256 color mode and 8-bit grayscale, neither would show up in the T.E.

Did a fresh install and it works in either method...idk, just glad its fixed!

 :D

Offline ghostdancer

  • Aces High CM Staff
  • Platinum Member
  • ******
  • Posts: 7562
Re: Strip - in reply to this post in the bug thread....
« Reply #10 on: August 31, 2009, 11:40:06 AM »
I forgot about that, thanks Waffle. That basically knocks out most of those steps. :)
X.O. 29th TFT, "We Move Mountains"
CM Terrain Team

Offline Waffle

  • HTC Staff Member
  • Administrator
  • *****
  • Posts: 4849
      • HiTech Creations Inc. Aces High
Re: Strip - in reply to this post in the bug thread....
« Reply #11 on: August 31, 2009, 12:00:22 PM »
Well, I know one issue was with the T.E. export gndtype.bmp not even showing any changes.

That is now fixed, and without changing any of my process everything works. I was saving in 256 color mode and 8-bit grayscale, neither would show up in the T.E.

Did a fresh install and it works in either method...idk, just glad its fixed!

 :D

there's not an option to export gndtype.bmp...it saves changes when you save in the TE.
When you change water / land and save it in the TE, it changes the waterd.htz file in the root terrain directory. If you wish to edit water outside the TE, there's the export option.
Keep in mind waterd.htz and waterc.htz ONLY do water / land divisions. The gndtype.bmp sets the ground / underwater textures only.

Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Strip - in reply to this post in the bug thread....
« Reply #12 on: August 31, 2009, 12:05:09 PM »
I said export but that probably is the wrong term, I meant the saved file.

Offline ghostdancer

  • Aces High CM Staff
  • Platinum Member
  • ******
  • Posts: 7562
Re: Strip - in reply to this post in the bug thread....
« Reply #13 on: August 31, 2009, 12:09:10 PM »
How does it set the underwater textures?

I mean I see that you have a value for deep ocean but basically nothing else. Well except for doing a transition between deep ocean and beach in the gndtype.bmp.

I thought you set the water depth over in waterd.bmp.
X.O. 29th TFT, "We Move Mountains"
CM Terrain Team

Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Strip - in reply to this post in the bug thread....
« Reply #14 on: August 31, 2009, 12:24:34 PM »
Water textures now work under the .bmps called wntt001 through wntt0012, so it is now possible to have up to 12 underwater textures on one terrain.  If you place a new water texture in your texsrc folder and name it wntt0001, when you "paint" your water using grass(nt0001) you will see this new underwater texture.  Want to add another underwater texture?  Place a second .bmp in your texsrc and call it wntt0002.  Now when you paint your water with forrest(ntt0002)  you will see the second water texture you placed in there.  Repeat up to wntt0012 if desired.  Should make for some really neat coral reefs & such.

Quoted from the water textures thread...