POV-Ray : Newsgroups : povray.general : QUESTION: Bump_Map not Effective? Server Time
24 Nov 2024 21:06:33 EST (-0500)
  QUESTION: Bump_Map not Effective? (Message 1 to 10 of 14)  
Goto Latest 10 Messages Next 4 Messages >>>
From: Sven Littkowski
Subject: QUESTION: Bump_Map not Effective?
Date: 15 Jul 2017 20:42:01
Message: <596ab659@news.povray.org>
I never actually used bump_maps before. Now I try to use one, but not
seeing any effect. Can someone assist me?

The scene contains a stratosphere helium balloon, and the bump_map
should have created the typical balloon surface. However, I don't see
the surface changed. Before posting any images, I show you the scene
file. is there any error the way I do it?

-------------------------------------------

#version 3.7;

#include "kolors.inc"
#include "finish.inc"
#include "textures.inc"

#declare MyRadiosity = off;

global_settings
{
 #if(MyRadiosity)
  radiosity
  {
   media on
   pretrace_start 0.08
   pretrace_end   0.001
   count 400
   error_bound 0.75
   recursion_limit 1
  }
 #end
 subsurface        {}
 adc_bailout       0.0039
 ambient_light     rgb < 0.000, 0.000, 0.000 >
 assumed_gamma     1.000
 irid_wavelength   rgb < 0.250, 0.180, 0.140 >
 max_trace_level   5
 number_of_waves   10
 noise_generator   3
 charset           ascii
}

camera
{
 location < -000.0, 400.0, -500.0 >
 look_at < 0.0, -200.0, 0.0 >
 right 1.77*x
}

//
----------------------------------------------------------------------------------------------------------------------------------


light_source
{
 < 2500.0, 2500.0, 5000.0 >
 rgb < 0.72265625, 0.8046875, 0.80859375 > *10.0
}

//
----------------------------------------------------------------------------------------------------------------------------------

#declare MyRadius = 200.0;

//
----------------------------------------------------------------------------------------------------------------------------------

#declare MyOuterBalloonFinish = finish
{
// reflection   0.00
 crand        0.10
}

#declare MyInnerBalloonFinish = finish
{
 brilliance   1.50
 phong albedo 0.05
 metallic     0.00
 ambient      0.00
 emission     0.00
 reflection   0.50
}

#declare MyOuterBalloonTexture = texture
{
 pigment
 {
  image_map { png "H:\My Documents\My Pictures\POV-Ray\Space - Launcher
- Balloon - Type 001 - Moon Runnings - Balloon Texture.png" }
  translate -0.5
  rotate < 90.0, 0.0, 0.0 >
  scale MyRadius*2
 }
 normal
 {
  bump_map { png "H:\My Documents\My Pictures\POV-Ray\Space - Launcher -
Balloon - Type 001 - Moon Runnings - Balloon BumpMap.png" gamma 1.8
bump_size 150.0 }
  translate -0.5
  rotate < 90.0, 0.0, 0.0 >
  scale MyRadius*2
 }
 finish { MyOuterBalloonFinish }
}

#declare MyInnerBalloonTexture = texture
{
 pigment { color rgb < 0.7686275,  0.7607843,  0.7333333 > }
 finish { MyInnerBalloonFinish }
}

//
----------------------------------------------------------------------------------------------------------------------------------

#declare UpperBalloonShape = torus     // Balloon Radius: 175 m /
Launcher Radius: 10 m
{
 95.0, 105.0
 scale < 1.0, 0.5, 1.0 >
}

#declare LowerBalloonShape = difference
{
 sphere { < 0.0, 0.0, 0.0 > MyRadius }
 cylinder { < 0.0, 0.0, 0.0 > < 0.0, 175.001, 0.0 > MyRadius+0.001 }
 scale < 1.0, 1.5, 1.0 >
}

#declare MyBalloonHullOutside = union
{
 object { UpperBalloonShape }
 object { LowerBalloonShape }
 texture { MyOuterBalloonTexture }
}

#declare MyBalloonHull = difference
{
 object { MyBalloonHullOutside }
 object
 {
  MyBalloonHullOutside
  scale 0.99999
  texture { MyInnerBalloonTexture }
 }
 cylinder  // Launcher Openings
 {
  < 0.0, -((MyRadius*1.5)+0.001), 0.0 > < 0.0, (MyRadius+0.001), 0.0 > 3.5
  texture { MyInnerBalloonTexture }
 }
}

#declare Launcher = difference
{
 union
 {
  #declare MyLength = 10.0;
  #declare MyHeight = 0.0;
  #declare MyTop = 35.0;
  cylinder { < 0.0, -((MyRadius*1.5)+30.0), 0.0 > < 0.0, MyTop, 0.0 >
3.5 }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 000.0, 0.0 > }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 045.0, 0.0 > }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 090.0, 0.0 > }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 135.0, 0.0 > }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 180.0, 0.0 > }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 225.0, 0.0 > }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 270.0, 0.0 > }
  box { < MyLength, -MyHeight, -0.1 > < -MyLength, MyTop, 0.1 > rotate <
0.0, 315.0, 0.0 > }
 }
 cylinder { < 0.0, -((MyRadius*1.5)+30.001), 0.0 > < 0.0, MyTop+0.001,
0.0 > 3.3 }
 pigment { color rgb 1.0 }
}

#declare DoublePositionLight = union
{
 union
 {
  cylinder { < 0.0, 0.0,  2.5 > < 10.0, 0.0,  2.5 > 0.20 }
  cylinder { < 0.0, 0.0, -2.5 > < 10.0, 0.0, -2.5 > 0.20 }
  pigment { color rgb < 0.05, 0.05, 0.05 > }
  finish { MyOuterBalloonFinish }
 }
 union
 {
  sphere { < 10.0, 0.0, 2.5 > 0.35 }
  sphere { < 10.0, 0.0, -2.5 > 0.35 }
  pigment { color rgbf < 1.0, 0.0, 0.0, 0.5 > }
  finish { ambient rgb < 0.3, 0.1, 0.1 > }
 }
 union
 {
  light_source
  {
   < 10.0, 0.0, 2.5 >
   rgb < 0.7, 0.0, 0.0 > *10.0
   fade_distance 50.0
   fade_power 4
  }
  light_source
  {
   < 10.0, 0.0, -2.5 >
   rgb < 0.7, 0.0, 0.0 > *1.0
   fade_distance 50.0
   fade_power 4
  }
 }
}

#declare PositionLights = union
{
 #declare MyDistance = MyRadius-0.1;
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 000.0, 0.0 > }
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 045.0, 0.0 > }
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 090.0, 0.0 > }
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 135.0, 0.0 > }
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 180.0, 0.0 > }
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 225.0, 0.0 > }
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 270.0, 0.0 > }
 object { DoublePositionLight translate < MyDistance, 0.0, 0.0 > rotate
< 0.0, 315.0, 0.0 > }
}

union
{
 object { MyBalloonHull }
 object { Launcher }
 object { PositionLights }
}

background { rgb < 0.02392157,  0.03490196,  0.04627451 > }

---
Diese E-Mail wurde von AVG auf Viren geprüft.
http://www.avg.com


Post a reply to this message

From: omniverse
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 16 Jul 2017 00:35:01
Message: <web.596aebdd3b5fa6e29c5d6c810@news.povray.org>
Sven Littkowski <I### [at] SvenLittkowskiname> wrote:
> I never actually used bump_maps before. Now I try to use one, but not
> seeing any effect. Can someone assist me?
>
> The scene contains a stratosphere helium balloon, and the bump_map
> should have created the typical balloon surface. However, I don't see
> the surface changed. Before posting any images, I show you the scene
> file. is there any error the way I do it?

That light source is extremely bright, is that really needed?

radiosity=off but you can add:

 normal on // affect surface normal too

into the radiosity statement for when you set it to on.

The extreme bump_size might not be needed, unless your map image lacks contrast.
I made a test map of a dozen vertical lines, repeatedly changing smoothly from
almost black to nearly white, and it shows the "bumps" easily by using only
bump_size 1.5. Just thought I would mention that.

And of course, if you're expecting light to shadow transition bumps... well,
forget it, because a texture normal isn't going to change the surface itself.
;)
Only fakes the bumpiness for the lit area. And you might already know that, I'm
just telling what I can.

For the outside image_map you might want to add:

transmit all [decimal0to1]

so the inside texture is at least partially seen through it.
I'm not sure what you're actually trying for with those outside and inside
textures, but you could also apply it using interior_texture within the object.

Oh, the 'crand' might be a bad idea for that balloon.
Hopefully some help for now.

Bob


Post a reply to this message

From: Thomas de Groot
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 16 Jul 2017 02:52:41
Message: <596b0d39$1@news.povray.org>
On 16-7-2017 1:41, Sven Littkowski wrote:
> I never actually used bump_maps before. Now I try to use one, but not
> seeing any effect. Can someone assist me?
> 
> The scene contains a stratosphere helium balloon, and the bump_map
> should have created the typical balloon surface. However, I don't see
> the surface changed. Before posting any images, I show you the scene
> file. is there any error the way I do it?
> 
> -------------------------------------------

Same comments as Omniverse. I give you here an example from my 
BeenThereDoneThat scene, the moon in the sky:

#declare MoonMap =
   texture {
     pigment {
       image_map {
         png "PlanetMaps/MoonMap.png" gamma 1.0
         map_type 1
         once
         interpolate 2
       }
     }
     normal {
       bump_map {
         png "PlanetMaps/MoonBump.png"
         map_type 1
         once
         interpolate 2
       }
       bump_size 5.0
     }
     finish {
       diffuse albedo 0.9
     }
   }

That is all that is needed. The bump_size is even rather high but works 
best for this scene.

Note that in order for the maps to be effective you need to add the 
map_type parameter which seems to be missing in your code. 1 is for a 
sphere. See docs for mor info on image_maps and bump_maps.

-- 
Thomas


Post a reply to this message

From: omniverse
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 16 Jul 2017 03:10:00
Message: <web.596b10e23b5fa6e29c5d6c810@news.povray.org>
Thomas de Groot <tho### [at] degrootorg> wrote:
> On 16-7-2017 1:41, Sven Littkowski wrote:
> > I never actually used bump_maps before. Now I try to use one, but not
> > seeing any effect. Can someone assist me?
> >
> > The scene contains a stratosphere helium balloon, and the bump_map
> > should have created the typical balloon surface. However, I don't see
> > the surface changed. Before posting any images, I show you the scene
> > file. is there any error the way I do it?
> >
> > -------------------------------------------
>
> Same comments as Omniverse. I give you here an example from my
> BeenThereDoneThat scene, the moon in the sky:
>
> #declare MoonMap =
>    texture {
>      pigment {
>        image_map {
>          png "PlanetMaps/MoonMap.png" gamma 1.0
>          map_type 1
>          once
>          interpolate 2
>        }
>      }
>      normal {
>        bump_map {
>          png "PlanetMaps/MoonBump.png"
>          map_type 1
>          once
>          interpolate 2
>        }
>        bump_size 5.0
>      }
>      finish {
>        diffuse albedo 0.9
>      }
>    }
>
> That is all that is needed. The bump_size is even rather high but works
> best for this scene.
>
> Note that in order for the maps to be effective you need to add the
> map_type parameter which seems to be missing in your code. 1 is for a
> sphere. See docs for mor info on image_maps and bump_maps.
>
> --
> Thomas

Definitely onto something there Thomas. I was looking at it again because I
thought there was a reason for the default planar mapping, but I wondered if
that could be a mistake for this particular thing.
map_type 1 will wrap around the balloon shape spherically and not need
translate, rotate or scale.

But the main thing I was thinking about was to skip the image_map to get a
better look at what the bump_map is doing. So to try that, Sven, you might want
to look at it with only pigment { rgb 1 filter 0.5 } or similar. That way you
can see the normal alone.

I realized my attempt using my own image file masked the appearance somehow.
Probably something to do with the bump_map being like an illusion and not a real
surface deformation for the visible image to paint onto. So using the plain
pigment color it highlights the bump_map instead of masking it from view.
At least that's my thought on this.

Bob


Post a reply to this message

From: Thomas de Groot
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 16 Jul 2017 06:58:49
Message: <596b46e9@news.povray.org>
On 16-7-2017 9:08, omniverse wrote:
> Thomas de Groot <tho### [at] degrootorg> wrote:
>> On 16-7-2017 1:41, Sven Littkowski wrote:
>>> I never actually used bump_maps before. Now I try to use one, but not
>>> seeing any effect. Can someone assist me?
>>>
>>> The scene contains a stratosphere helium balloon, and the bump_map
>>> should have created the typical balloon surface. However, I don't see
>>> the surface changed. Before posting any images, I show you the scene
>>> file. is there any error the way I do it?
>>>
>>> -------------------------------------------
>>
>> Same comments as Omniverse. I give you here an example from my
>> BeenThereDoneThat scene, the moon in the sky:
>>
>> #declare MoonMap =
>>     texture {
>>       pigment {
>>         image_map {
>>           png "PlanetMaps/MoonMap.png" gamma 1.0
>>           map_type 1
>>           once
>>           interpolate 2
>>         }
>>       }
>>       normal {
>>         bump_map {
>>           png "PlanetMaps/MoonBump.png"
>>           map_type 1
>>           once
>>           interpolate 2
>>         }
>>         bump_size 5.0
>>       }
>>       finish {
>>         diffuse albedo 0.9
>>       }
>>     }
>>
>> That is all that is needed. The bump_size is even rather high but works
>> best for this scene.
>>
>> Note that in order for the maps to be effective you need to add the
>> map_type parameter which seems to be missing in your code. 1 is for a
>> sphere. See docs for mor info on image_maps and bump_maps.
>>
>> --
>> Thomas
> 
> Definitely onto something there Thomas. I was looking at it again because I
> thought there was a reason for the default planar mapping, but I wondered if
> that could be a mistake for this particular thing.
> map_type 1 will wrap around the balloon shape spherically and not need
> translate, rotate or scale.
> 
> But the main thing I was thinking about was to skip the image_map to get a
> better look at what the bump_map is doing. So to try that, Sven, you might want
> to look at it with only pigment { rgb 1 filter 0.5 } or similar. That way you
> can see the normal alone.
> 
> I realized my attempt using my own image file masked the appearance somehow.
> Probably something to do with the bump_map being like an illusion and not a real
> surface deformation for the visible image to paint onto. So using the plain
> pigment color it highlights the bump_map instead of masking it from view.
> At least that's my thought on this.
> 
> Bob
> 
> 
>

You are absolutely right. Best to test with a plain pigment, preferably 
a light one. ;-)


-- 
Thomas


Post a reply to this message

From: omniverse
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 17 Jul 2017 02:00:06
Message: <web.596c51763b5fa6e29c5d6c810@news.povray.org>
Sven, I found some possible errors in other things you might not be aware of
yet. I was trying a remake of your scene file, just like I often do with SDL
shared by other people.

The top of the LowerBalloonShape was not differenced out completely, so unless
you intend a parachute hovering above the balloon you will need to increase the
cylinder height from 175.001 to MyRadius+0.001 in the y direction.

The position lights are embedded into the surface of the cylinder ends, and
moving each light_source from the current 10 to maybe 10.25 (x direction) should
make those visible. I was not seeing them before changing that.

I didn't continue with your bump_map and instead used:

 normal {radial frequency 24 bump_size 6} // wraps around y axis

for both the outside and inside textures.
And just a pigment {rgb 1 transmit 0.2}, although I'm curious what your balloon
bump_map image is and if that was too low in contrast or some other reason for
not showing obvious surface features.

Bob


Post a reply to this message

From: omniverse
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 17 Jul 2017 11:50:01
Message: <web.596cdc593b5fa6e29c5d6c810@news.povray.org>
"omniverse" <omn### [at] charternet> wrote:
>
> I didn't continue with your bump_map and instead used:
>
>  normal {radial frequency 24 bump_size 6} // wraps around y axis

There should have been a scallop_wave in there too, sorry. Not suggesting you
change your way of doing things, I was just telling what I did.

Bob


Post a reply to this message

From: Sven Littkowski
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 23 Jul 2017 18:15:26
Message: <59751ffe$1@news.povray.org>
On 17.07.2017 11:48, omniverse wrote:
> "omniverse" <omn### [at] charternet> wrote:
>>
>> I didn't continue with your bump_map and instead used:
>>
>>  normal {radial frequency 24 bump_size 6} // wraps around y axis
> 
> There should have been a scallop_wave in there too, sorry. Not suggesting
 you
> change your way of doing things, I was just telling what I did.
> 
> Bob
> 
> 
> 


---
Diese E-Mail wurde von AVG auf Viren geprüft.
http://www.avg.com


Post a reply to this message

From: Sven Littkowski
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 23 Jul 2017 18:22:07
Message: <5975218f@news.povray.org>
On 17.07.2017 11:48, omniverse wrote:
> "omniverse" <omn### [at] charternet> wrote:
>>
>> I didn't continue with your bump_map and instead used:
>>
>>  normal {radial frequency 24 bump_size 6} // wraps around y axis
> 
> There should have been a scallop_wave in there too, sorry. Not suggesting you
> change your way of doing things, I was just telling what I did.
> 
> Bob
> 
> 
> 
Thanks to you all. :-)
And sorry for my absence, I was not at home.

I think, it might be a good idea to attach the bump_map file. Just for
size reasons, it is now a JPG, but you can put it back to a PNG file.

I also added the once keyword and the map_type. Still, no change.

Will apply the other correctional changes as advised. but please see my
bump_map file and check out. Thanks.


---
Diese E-Mail wurde von AVG auf Viren geprüft.
http://www.avg.com


Post a reply to this message


Attachments:
Download 'space - launcher - balloon - type 001 - moon runnings - balloon bumpmap.jpg' (436 KB)

Preview of image 'space - launcher - balloon - type 001 - moon runnings - balloon bumpmap.jpg'
space - launcher - balloon - type 001 - moon runnings - balloon bumpmap.jpg


 

From: omniverse
Subject: Re: QUESTION: Bump_Map not Effective?
Date: 24 Jul 2017 01:55:00
Message: <web.59758b8e3b5fa6e29c5d6c810@news.povray.org>
Sven Littkowski <I### [at] SvenLittkowskiname> wrote:

I replied to your message at povray.binaries.images with a changed SDL text and
the image file after I enhanced it for contrast and smoothness (was grainy
before).
You should be able to see how the bumpiness looks from rendering that now.

I did some excercises in scaling to get it best way I could, as you might find
out when reading it.
Anyway, see what I wrote there and download the other image for it.

There's probably a better way, that just what I managed to do.

Bob


Post a reply to this message

Goto Latest 10 Messages Next 4 Messages >>>

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.