+ All Categories
Home > Documents > Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7....

Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7....

Date post: 01-Sep-2020
Category:
Upload: others
View: 1 times
Download: 0 times
Share this document with a friend
8
Image Masking Test Results This document will contain the results of my image masking tests. More tests will be added soon and I’ll remove the draft status.
Transcript
Page 1: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Image Masking Test Results This document will contain the results of my image masking tests. More tests will be added soon and I’ll remove the draft status.

Page 2: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Table of Contents

POPULATION OBJECT SPACING ................................................................................3

Detailed Results............................................................................................................................................................4

IMAGE MASK RESOLUTION .........................................................................................5

COLOURING LEAVES....................................................................................................6

Original texture............................................................................................................................................................6

Custom mask images ...................................................................................................................................................7

Surface Layer Structure..............................................................................................................................................7 Sample tweaks ..........................................................................................................................................................8

Sample Files..................................................................................................................................................................8

Page 3: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Population object spacing This test is intended to demonstrate the changes in object spacing for various pixels values. Each grey square is bounded by an area of both white and black for comparison purposes. The results of this test can be used to determine the contrast of mask images to get the desired spacing of objects across the entire mask. The mask values are given for % brightness.

Mask image

Render

Page 4: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Detailed Results

90%

80%

70%

60%

50%

40%

30%

20%

10%

Page 5: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Image Mask Resolution So you’ve made a mask image to mask a surface layer. It’s got fine details in it that are important to your final image. What resolution should your mask image be?

or Terragen2 has greatly improved image anti-aliasing. This can be both a blessing and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9 thin lines and fine details in low resolution images used to render as fuzzy squares. This is no longer the case. BUT, it will also obliterate fine, high contrast details, which is often what you are using your mask for in the first place. The test image I created contains a number of dots and lines that start off at 1 pixel wide, with a 1 pixel gap. A diagonal line shows the effect of interpolation on jagged lines.

Original mask

• Gaps between dots/lines non-existent

• Reduced brightness of masked area

Mask size x2

• Gaps appear but are reduced in width

• Brightness of masked area OK

Mask size x4

• Gap width increased, closer to expected.

Mask size x8

• Minor increase in gap wdth

Page 6: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Colouring Leaves One of the biggest problems with tree objects is that they have a very limited amount of variation. The XFrog trees that are commonly used have only one or two leaf textures per tree. This project looks at replacing the coloured leaf texture of a tree with a set of image masks and coloured surface shaders to provide a greater range of variation.

Original texture While I may be showing my ignorance of rendering programs here, as a photographer I can’t understand why texture images are so washed out. Terragen’s lighting control has always been pretty good, and with ambient lighting and atmosphere effects, the use of washed out textures on trees detracts from their realism in the final render.

Original texture Adjusted texture

. But I digress. This project is about replacing the coloured texture image with surface shaders. I’ve tried a lot of different combinations, and there are probably many others than those mentioned here that will produce good results… but this is what I’ve settled on for now.

Page 7: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Custom mask images The original leaf texture consists of a colour texture image and a greyscale transparency mask.

From these two images, I constructed a couple of different masks for various shaders.

Mask image to restrict TG surfaces to leaves and petioles

Modified leaf texture. Leaves and petioles converted to greyscale to provide basic tones for surfaces. (Or alternatively, leave the original colour image)

Shadow image map applied to Colour shader of final leaf surface

Surface Layer Structure I have played around with various TG shaders to try and simulate a realistic leaf texture. Most of my attempts either did not work as well as expected, or excessively increased render times with little perceivable change. The final structure is relatively simple and provides a simple means of creating additional levels of variation in colour beyond the individual leaf texture.

• Base tones and original texture (in areas not coloured by shaders) • Base colour masked to leaves and petioles

o Contrasting colours using fractal shaders to provide variation • Colour map (masked to leaves and petioles) adjusting lightness and

saturation to correct for over saturation of colour in shadows of base texture image

I’m still not 100% sure of everything in this node network. Any corrections/suggestions are welcome.

Page 8: Image masking test resultsarchive.bigben.id.au/terragen/files/image_masking_tests.pdf · 2008. 7. 18. · and a curse. It’s a blessing because it’s pretty bloody good. In TG0.9

Base leaf colour The main colouring of the leaves is achieved by mixing two colour layers. The main tweaks are:

• Choice of colours to mix • Coverage and fractal breakup

density of the primary contrast surface

• Scaling of the Leaf detail Small “imperfections” are added to the leaf via two additional surface shaders. These shaders have both low coverage and low fractal density. The main tweaks are:

• Choice of colour (recommend at least one complementary colour to the main leaf colour)

• Seed of the fractal breakups Tonal detail The “shadows” and other tonal detail are created by applying a modified greyscale image derived from the original leaf texture. Altering the levels and contrast of this image provide the main tweaks. The brightness of each pixel in the image relates to the colour slider of the underlying surfaces i.e. black is equivalent to Apply colour = 0 and white is equivalent to Apply colour = 1. This image thus provides tweaks for the colour, brightness and saturation of the leaves.

Sample tweaks Increase the variation in primary colours in individual leaves

Decrease the scaling values of the Primary contrast fractal breakup

Decrease the noise in distant trees Decrease the fractal breakup amount in the Primary contrast shader

Sample Files This demo is based on the XFrog birch tree. I have only provided the modified files to be used in conjunction with this model. The model is included in the free set of tgo trees <http://skindustry.net/planetside/XfrogPlants_5_Species_Terragen2.zip>.92Mb. The zip file linked below contains my test TGD, a clip file of the tree population and my modified images. Place the images into the same directory as your XFrog birch TGO file prior to using the TGD or TGC files and then correct the links to the images when you use the TGD or TGC. (More help on that later) <http://www.path.unimelb.edu.au/~bernardk/terragen/files/coloured_leaves_mod.zip> 1.2Mb


Recommended