POV-Ray : Newsgroups : povray.binaries.images : Metallica Logo : Re: Metallica Logo Server Time
16 Apr 2024 02:40:01 EDT (-0400)
  Re: Metallica Logo  
From: Dave Blandston
Date: 22 Feb 2010 10:20:00
Message: <web.4b82a034ccaa8d9dcba3fb0f0@news.povray.org>
"jute" <nomail@nomail> wrote:
> That's the best use of brick pattern I ever saw!
>
> --
> jussi

Thanks! Since the original posting I've adjusted the camo texture. It looked
fine at screen-size resolution, but the final version of this scene will be much
larger. I wasn't satisfied with just using the brick pattern because real fabric
would have a gradual change in color, and the brick pattern only allows for a
sudden change between the brick and morter colors. Therefore, I'm now using a
home-made brick pattern with gradient edges for a more realistic look. The
home-made pattern also has the advantage of being able to offset the rows of
bricks by any amount. Here's what I'm using now...

#local Transparent = color Black transmit 1;
#local SemiTransparent = color Black transmit .4;

#local BallisticNylonScale = .28; //Overall scale

#local BallisticNylon = pigment {
   #local ThreadWidth = .26;
   #local EdgeWidth = .14;
   #local HorizontalScale = .85; //Controls the width of the "bricks"
   #local RowOffset = .5;
   gradient x
   color_map {
      [0 color SemiTransparent]
      [EdgeWidth / HorizontalScale color Transparent]
      [1 - EdgeWidth / HorizontalScale color Transparent]
      [1 color SemiTransparent]
   } //color_map
   scale <HorizontalScale, 1, 1>
} //pigment

#local BallisticNylon = pigment {
   gradient y
   pigment_map {
      [0 color Transparent]
      [.5 - ThreadWidth / 2 - EdgeWidth color Transparent]
      [.5 - ThreadWidth / 2 - EdgeWidth color SemiTransparent]
      [.5 - ThreadWidth / 2 BallisticNylon]
      [.5 + ThreadWidth / 2 BallisticNylon]
      [.5 + ThreadWidth / 2 + EdgeWidth color SemiTransparent]
      [.5 + ThreadWidth / 2 + EdgeWidth color Transparent]
      [1 color Transparent]
   } //color_map
} //pigment

#local BallisticNylon1 = texture {
   pigment {BallisticNylon}
   scale <BallisticNylonScale, BallisticNylonScale, 1>
} //texture

#local BallisticNylon2 = texture {
   pigment {BallisticNylon translate <RowOffset * HorizontalScale, .5, 0>}
   scale <BallisticNylonScale, BallisticNylonScale, 1>
} //texture

#local NewTexture = texture {OldTexture} texture {BallisticNylon1} texture
{BallisticNylon2}

Regards,
Dave Blandston


Post a reply to this message


Attachments:
Download 'ballisticnylon.png' (37 KB)

Preview of image 'ballisticnylon.png'
ballisticnylon.png


 

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