How do you save a Grayscale in 16 bit, is it possible?

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

Starstreams

New Member
Mar 12, 2001
1,516
0
0
USA
mgiese1.home.comcast.net
Would anyone happen to know how to save a texture as a 16 bit grayscale from photoshop?
According to the UDN web site you supposedly can.

See here under the heading Title “The TerrainMap”
http://udn.epicgames.com/pub/Content/CreatingTerrain/#Preparing_Your_Map_for_Terrain


It says Quote: “Most of the times you will want to import 16-bit or 8-bit grayscale textures for the TerrainMap”

I haven’t found out how to save a 16 bit texture right off the bat. I can only save my grayscales as 8bit Bitmaps, any ideas.... ?
 

Mychaeel

New Member
Qbic said:
RGB mode -> Save as -> Targa -> 16bit (inthe popup box)

I expect that doesn't save the bitmap in 16-bit grayscale (what Starstreams wants) but in 16-bit RGB: 5 bits red, 6 bits green, 5 bits blue per pixel (R5G6B5).

I understand PhotoShop is able to switch to 16-bit grayscale too (and can certainly save it as well), but that it is very limited in what it can actually do with those files.
 

Qbic

The horrors...
Apr 15, 2001
202
0
0
Norway
Visit site
Mychaeel said:
I expect that doesn't save the bitmap in 16-bit grayscale...

Good point, forgot about the heightmap bit.

As far as I can tell you have to flatten the grayscale image before converting to 16bit, you are not allowed to work in 16 bit (don't know where the extra 8bits come from). Only saves as .psd .raw and .tif so don't know how useful it is for Ued.
 
Last edited:

Starstreams

New Member
Mar 12, 2001
1,516
0
0
USA
mgiese1.home.comcast.net
I was flatining my images


Anyway I don't know what the hell is going on here?
I just tried saving a bitmap file from an RGB image I was making and now I have the option to save as 16 bit but if you notice in the picture I’ve attached the image bar on the top window still says 24 bit. What a joke this is.

This is funny because I tried saving an RGB image last night and I only had 4,8, and 24 as options in the bitmap save window, Now I've got 16, go figure.
I don’t know what to believe anymore
 

Attachments

  • 16_bit_map.jpg
    16_bit_map.jpg
    42.2 KB · Views: 21

Mychaeel

New Member
Starstreams said:
Anyway I don't know what the hell is going on here?
I just tried saving a bitmap file from an RGB image I was making and now I have the option to save as 16 bit but if you notice in the picture I’ve attached the image bar on the top window still says 24 bit. What a joke this is.

Selecting "16 bit" in a "Save As" dialog only affects the saved image file, not the image that's open in PhotoShop.

And, again (see above), saving a color image as a 16-bit bitmap isn't the same as saving a 16-bit grayscale image. The former reduces 24 bit of actual color information (8 bits per R,G,B color component) into 16 bits per pixels (5 bits R, 6 bits G, 5 bits B). The latter actually saves 16 bits of colorless brightness information.

Also, you won't have any benefit from even correctly saving a normal grayscale image with 16-bit grayscale depth. If the image you're saving has only 8 bits of grayscale information per pixel stretching that to 16 bits per pixel only doubles the file size without actually making the image smoother. You'd have to entirely work in 16-bit grayscale depth to see any positive effect.

I don't see why you are bothering with imported heightmaps at all though. Can't you do all terrain editing you need directly in the editor?
 

Starstreams

New Member
Mar 12, 2001
1,516
0
0
USA
mgiese1.home.comcast.net
My reasons for using a hightmap is to give myself a quick start on a layout I had in mind and then I was going to go back and use the terrain tool for doing my detail work. By the way I use the terrain tool when I first start out but then I swap out the map in the terrain info

So if I understand what you said above, it sound like it all comes out the same wither you choose to start out with an RGB or a grayscale?

By the way, I was able to save my RGB image as a 16 bit image that imported fine, however grayscale textures only save in 4 and 8 bit: This is by design I believe, or I think?


By the way Mychaeel, if you were going to be importing your own custom high quality textures for things such as walls and or anything BSP related, which of the 4 format’s would you probably choose and why?

1. .Tiff
2. .Targa
3. .Pcx
4. .Dxt3
5. .Dxt5

btw, thanks for your help, I’m learning something hear! :)
 

Mychaeel

New Member
Starstreams said:
My reasons for using a hightmap is to give myself a quick start on a layout I had in mind and then I was going to go back and use the terrain tool for doing my detail work.

Then you don't need a 16-bit grayscale heightmap. Just make a normal 8-bit heightmap, import it and convert it to 16-bit in UnrealEd before starting to tweak it with the terrain tools.

By the way, I was able to save my RGB image as a 16 bit image that imported fine, however grayscale textures only save in 4 and 8 bit: This is by design I believe, or I think?

I think it has been said several times in this thread already, but I'll reiterate it once more: 16-bit RGB is something completely different than 16-bit grayscale. The former uses 16 bits to encode three individual color channels, thus reducing its quality by compressing normally 24 bits of information per pixel into 16 bits per pixel; the latter uses 16 bits to encode one color/grayscale channel, thus allowing for 16 bits of information per pixel instead of the normal 8 bits.

Obviously, saving a grayscale image that has been designed in an 8-bit mode won't improve in quality at all if it's saved in 16-bit grayscale mode; just like a monochrome image won't suddenly attain color by saving it as an RGB image.

If you mean to make a 16-bit grayscale image, there's no RGB format involved anywhere, and comparing 16-bit RGB to 16-bit grayscale is comparing apples and oranges.

if you were going to be importing your own custom high quality textures for things such as walls and or anything BSP related, which of the 4 format’s would you probably choose and why?

UDN: TextureComparisons goes into detail about texture format choice.
 

Starstreams

New Member
Mar 12, 2001
1,516
0
0
USA
mgiese1.home.comcast.net
Thanks Mychaeel, I do understand what you were saying but I guess what I was trying to get at was not the question of the differences between 16bit gray and 16bit RGB in regards to there channel information.

My question would be a more cut and dry answer as to which one would import my map with more detail "meaning smoother". Now you have said twice that 16-bit RGB is something completely different than 16-bit grayscale. I understand that concept, however what I’m trying to get at is: what exactly is the different as far as the end result on the brush itself?

So when I import a hightmap where a soft paint brush was used to paint walk ways, I don’t what it to import into the editor as big blocks much like an 8bit would produce.

So where you said "comparing 16-bit RGB to 16-bit grayscale is comparing apples and oranges", that sounds to me like your implying that a 16-bit RGB will render more detail on the import right off the bad?

And I do understand that you can’t make something out of nothing, such as making a monochrome image into an RGB. You didn’t loose me there ;) I’ve always known this.
Again, my main objective in this post was to find out what combination would give my Hightmap the smoothest curves on my terrain?

Sorry if I’ve I’m being a pain in the a$$ :(
 
Last edited:

Mychaeel

New Member
You seem to be designing your heightmap in 8-bit grayscale depth, right? That's the maximum in quality you'll ever get out of it then. By saving it in different formats (16-bit RGB for instance) you can only lose quality, never improve it.

For that matter, designing a heightmap in RGB mode (and saving it as such) will not improve its quality either. The only information of interest in a heightmap is the lightness of a given pixel; if you encode that in three color planes instead of one you'll just use more memory to do it, but won't actually add any usable information. So you're still putting no more than 8 bits of information per pixel into that image, only that they're redundantly spread over three color planes.

...and then, if you save those three color planes with less than 8 bits per pixel each as you would when you save a RGB image in 16-bit mode, you obviously lose information on each color channel separately. Since there's a redundancy between the three color channels, you lose overall quality; about as much as if you saved a grayscale image with 5 bits per pixel.

Again, my main objective in this post was to find out what combination would give my Hightmap the smoothest curves on my terrain?

Designing it in 16-bit grayscale mode and then saving it in that mode too. It's pointless to try saving it in any different mode than the one you designed it in for it won't improve its quality after the fact. That, too, has been said before.

It was also mentioned before that you can switch the bit depth of an image's color/grayscale planes from 8 bits to 16 bits in PhotoShop somewhere; consult the manual. The "Save File" dialog is just not the right place to look for that option.
 

Starstreams

New Member
Mar 12, 2001
1,516
0
0
USA
mgiese1.home.comcast.net
Ah, I see now that makes sense
By the way to answer your first question I was making my Maps in 24bit RGB and then later saving them as 16bit RGB’s but like you said it’s not worth increasing the files size. Thanks for that info!

Also, The place you change the bit depth that you were referring to in photoshop is in the mode menu, "see image"
Now as you probably already know, you can not paint on a 16bit grayscale texture, the paint brush actually turns to a (No) sign kind of like the way a no smoking sign looks. However you CAN paint in RGB and then change it to 16bit in the mode menu and it seems to preserve the detail. But the problem with doing it this way is that you no longer have the option to save it as a bit map in the Formats dropdown list from the save window. See image in second post:
 

Attachments

  • mode_16.jpg
    mode_16.jpg
    51.1 KB · Views: 11
Last edited:

Mychaeel

New Member
Starstreams said:
Now as you probably already know, you can not paint on a 16bit grayscale texture, the paint brush actually turns to a (No) sign kind of like the way a no smoking sign looks. However you CAN paint in RGB

...in the 16-bit mode you can select on your first screenshot? (That'd mean that each of the three color channels R,G,B would have a 16-bit color depth.)

and then change it to 16bit in the mode menu and it seems to preserve the detail.

Since you're changing from a lower-quality setting (normal 8-bit-per-channel RGB) to a higher-quality setting (16-bit-per-channel RGB), all detail is indeed preserved; however, it's still the old 8-bit details since you didn't have any more to start with.

Painting grayscale in RGB merely keeps three precise copies of the very same grayscale image in the three color planes so they'll make up the final grayscale image when they're displayed.

Converting anything from a low- or normal-quality setting to a higher-quality setting doesn't improve the quality of anything you previously painted in the low- or normal-quality setting. So unless you can actually paint in 16-bit channel mode, stop trying; you can't get the quality any higher than what you painted in.

By the way... you can attach several images to the same posting.
 

Qbic

The horrors...
Apr 15, 2001
202
0
0
Norway
Visit site
Guess you could try working in double res, convert to 16bit grayscale and resize. It still wouldn't save to a useful format, maybe there is some converter that will do the job?

If you just made your heightmap in Ued you would probably have it ready by now.
 

chip

New Member
Nov 14, 2002
524
0
0
Visit site
some technical talk that may help clarify the bit depth/channels discussion: 24-bit RGB images have 3 channels of 8-bit greyscale data that specify values of the additive primaries. 3x8=24bit color.

as Mychaeel wrote, 16-bit RGB images have the number of bits reduced in each channel.

each 8-bit greyscale channel has the potential for 256 levels of grey ranging from black (usually 0) to white (usually 255). in 24-bit color images these values are assigned to the Red, Green or Blue brightness in a combined color.

greyscale images have only one channel, so 8-bit greyscale images have 256 "steps" of grey to work with (2^8=256)

16-bit greyscales images have 65536 possible grey values (2^16=65536).

obviously more value" steps" = "smoother"

converting 8-bit GS to 16-bit GS doesn't changethe actual greyscale steps, just stretches them over a longer scale, so it isn't automatically smoother.

afaik the Terrain Editor works directly with 16-bit values, so it will be smoother than anything you could do with 8-bit. plus you get immediate visual feedback on the result.

importing terrain maps would be good when using heightmap data from other sources, if they can be properly converted to 16-bit GS. prob'ly would need tweaking in UEd even then.