POV-Ray : Newsgroups : povray.general : stiches Server Time
1 Nov 2024 19:15:02 EDT (-0400)
  stiches (Message 1 to 3 of 3)  
From: Peter Warren
Subject: stiches
Date: 20 Sep 2014 06:35:01
Message: <web.541d5724faac323272cb68aa0@news.povray.org>
this has been driving me crazy for years. whats the deal with the stiches not
showing up on this watchband? (hope this inc file is enough for anyone who care
to check it.)
btw. pov rocks!

// Persistence of Vision Ray Tracer Scene Description File
// File: ?.pov
// Vers: 3.5
// Desc: watch
// Date: april 2004
// Auth: foam
//
//#include "cords.inc"
/*
#version 3.5;

#include "colors.inc"
#include "textures.inc"
#include "shapes.inc"

global_settings {
  assumed_gamma 1.0
}

background { color rgb <0.1, 0.3, 0.8> }

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

camera {                //19
  location   <-0.0,  0.0, -19.7> // <0.0,  4.0, -3.0> //  <6.0, 0., -1.0> //
<0.0, -3., -3.0> //
   // <.0,  -5.0, -6.0>  //  <3.0,  -5.0, -2.1>   //
  direction 1.5*z
  right     x*image_width/image_height
  look_at    <0.0, 0.00,  0.0>// <0.0, -5.0,  0.0>  //
rotate y*-0 translate<0,0,0> }

// An area light (creates soft shadows)


light_source {
  <0, 0, 0>            // light's position (translated below)
  color rgb <1, 1, 1>  // light's color
  translate <5.0, 0., -4.0>  //<4.0, -5., -2.0>//
}
*/
//===========================TEXTURES=============================//
               //z*0.4
#declare STRAPTEX= //Brown
 texture { pigment {Brown/3.5} normal {quilted scale 0.2 control0 1 control1 1
rotate 90*z scale <1,1,0.4> turbulence .2}}
////////////////////////////////////////////

#declare WATCH  = union{
#include "watchface.inc"
#declare CF_ShowTickMarks = yes;
   #declare CF_ShowBorder = no; #declare CF_BorderWidth = 0.1;
  // #declare CF_FontName ="comic.ttf"
   #declare CF_NumeralScale = <0.8,0.9,1>;    //Goldenrod   Tan
   #declare CF_FaceTexture = texture {pigment {Feldspar}}//{Jade scale 5 }
   #declare CF_NumeralTexture = texture { pigment { rgb <0,0,0> } finish {
   ambient 0.4 } } #declare CF_HandTexture = texture { pigment { rgb <0.5,1,0.5>
} finish {
   ambient 0.3 } } #declare CF_KnobTexture = texture { CF_NumeralTexture }
#declare
   CF_BorderTexture = texture { CF_HandTexture }
#declare CLOCK=
   object{
  // ClockFace (3, 30, 37)
   ClockFace (7, 10, 47)                  //.01
         scale 0.25 translate <-0.00,0.0,-.12>  }
  object {CLOCK}

// ----------------------------------------
//wind      1.2             1.28
#declare CUT= box { <-.3, -.005, -.13>, <.3, .005, -.15> }  //rotate x*40
#declare CUTALL=
union{
#declare Index = 15;
#while(Index <= 360)
object { CUT rotate x*Index }
  #declare Index = Index + 15;
#end
}
#declare WIND=
difference {                            //.12
cylinder { <0.0, 0, -0.0>, <.08, 0, 0.0>, .14 pigment {Green}}// translate x*1.2
}
// box { <-.3, -.01, -.11>, <.3, .01, -.13> }  //rotate x*40
object {CUTALL}
}
object {WIND translate x*1.2 }
difference{
torus { 1.0, 0.2 rotate x*90 scale 1 texture {Silver1 }}//pigment {Red}}
cylinder { <0, 0, -0.5>, <0, 0, 0.5>, 1 texture {Silver1 }}
}
cylinder { <0, 0, 0.01>, <0, 0, 0.2>, 1.2 pigment {Red/3}}

//disc { <0, 0, 0>, z, 1.0, 0.0 pigment {Yellow/2*White*2/2} }
//glass
//#declare COVER=
cylinder { <0, 0, -0.21>, <0, 0, -0.1>, 1.0 //texture {Glass}//
pigment {Clear}
}
#declare GRAB=
union{
cylinder { <0.5, 0.2, 0>, <0.5, 0, 0>, .05  pigment {Red} translate x*.1}
cylinder { <-0.5, 0.2, 0>, <-0.5, 0, 0>, .05  pigment {Green} translate x*-.1}
#declare TURN=
difference{
torus { 0.2, 0.05 rotate x*90}
box { <-.5, 0, -.5>, <.5, -.5,.5> }
box { <-.5, .5, -.5>, <.0, -.5,.5> }
//new  make bigger
translate x*.1}
// turn bend
object{TURN translate <0.30,0.20,.0>} //right
object{TURN  rotate y*180 translate <-0.30,0.20,.0>} //left
cylinder { <-0.4, 0, 0>, <0.4, 0, 0>, .05 translate <0.0,0.40,.0> pigment
{Yellow}}
}//end grab
object {GRAB translate y*0.955}
 object {GRAB rotate x*180 translate y*-0.955}
//===========================STRAP=============================//
#declare BSTRAPtop= union{
//box { <-.5, -.47, .0>, <.45, -.20, -.1>pigment {White/2}  translate y*1.7}
object { Round_Box_Union(<-.5, -.47, .0>,<.5, -.20, -.1>, .06) texture {
STRAPTEX}  translate y*1.7 }
//cylinder { <0, 0, 0.00>, <0, 0, -0.1>, .45 pigment {White}
object{ Round_Cylinder_Union(<0, 0, 0.00>, <0, 0, -0.1>,.5 , .04) texture {
STRAPTEX}
clipped_by { plane { -y, 0.0 } }
translate y*1.4
}
//strap
//box { <-.45, -.47, -.0>, <.45, 1.20, .1>pigment {White/4}  translate y*1.7}
//#declare STRAP=
//difference{
object { Round_Box_Union(<-.5, -.47, -.0>,<.5, 3.0, .1>, .06)
    texture { STRAPTEX} //     pigment {White/2}
translate y*1.7 translate z*-.0}
//cylinder { <0, 4.2,-0.1>, <0,4.2, .2>, .05 }
//}    pigment {Red}
                                              //3

#declare STITCHTX=
texture { pigment {Red*1}finish {ambient 1}}

#declare TSTITCH=  //round stitchs
torus { 0.4, 0.01 texture {STITCHTX}// pigment {White}
rotate x*90 clipped_by { plane { -y, 0.0 } }
clipped_by { plane { -y, 0.0 inverse}rotate -z*18 }
 }
 //top lower
object {TSTITCH rotate z*-5 translate y*1.4 translate z*-.1}
object {TSTITCH rotate z*-35 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-65 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-95 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-125 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-155 translate y*1.4 translate z*-.1 }
//nbstitch
cylinder { <0.4, 1.26, -0.11>, <0.4, 1.38, -0.11>, .01 texture
{STITCHTX}//pigment {White}
}
cylinder { <-0.4, 1.26, -0.11>, <-0.4, 1.38, -0.11>, .01 texture
{STITCHTX}//pigment {White}
}
//object {TSTITCH rotate z*-30}
}//end union  BSTRAP top
//===========================botSTRAP=============================//
#declare BSTRAPbot= union{
//box { <-.5, -.47, .0>, <.45, -.20, -.1>pigment {White/2}  translate y*1.7}
object { Round_Box_Union(<-.5, -.47, .0>,<.5, -.20, -.1>, .06) texture {
STRAPTEX} translate y*1.7 }
//cylinder { <0, 0, 0.00>, <0, 0, -0.1>, .45 pigment {White}
object{ Round_Cylinder_Union(<0, 0, 0.00>, <0, 0, -0.1>,.5 , .04) texture {
STRAPTEX}//pigment {White}
clipped_by { plane { -y, 0.0 } }
translate y*1.4
}
//strap
//box { <-.45, -.47, -.0>, <.45, 1.20, .1>pigment {White/4}  translate y*1.7}
#declare HOLE= cylinder { <0, 5.5,-0.2>, <0,5.5, .2>, 0.05 translate y*-.4}
 //cylinder { <0, 4.6,-0.1>, <0,4.6, .2>, .05 }
//object{HOLE}
/*
#declare HOLES=
union{
#declare IndexH = -0.2;
#while(IndexH <= -6.0)
object { HOLE translate y*IndexH }
  #declare IndexH = IndexH - .2;
#end
}
 object{HOLES}
*/
//#declare STRAP=


difference{
object { Round_Box_Union(<-.5, -.47, -.0>,<.5, 3.5, .1>, .06) texture {
STRAPTEX} translate y*1.7 translate z*-.0}
object{HOLE}                                 //3.0
object{HOLE translate y*-.4}
object{HOLE translate y*-0.8}
object{HOLE translate y*-1.2}
//object{HOLE translate y*-1.6}
}
                                              //3
#declare TSTITCH=
torus { 0.4, 0.01 rotate x*90 clipped_by { plane { -y, 0.0 } }
clipped_by { plane { -y, 0.0 inverse}rotate -z*18 }
texture {STITCHTX}
//pigment {White} finish {ambient 0.1}
}
object {TSTITCH rotate z*-5 translate y*1.4 translate z*-.1}
object {TSTITCH rotate z*-35 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-65 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-95 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-125 translate y*1.4 translate z*-.1 }
object {TSTITCH rotate z*-155 translate y*1.4 translate z*-.1 }
//nbstitch
cylinder { <0.4, 1.26, -0.11>, <0.4, 1.38, -0.11>, .01 texture
{STITCHTX}//pigment {White}
}
cylinder { <-0.4, 1.26, -0.11>, <-0.4, 1.38, -0.11>, .01 texture
{STITCHTX}//pigment {White}
 }
//object {TSTITCH rotate z*-30}
}//end union  BSTRAP  bot
object{BSTRAPtop  }
object{BSTRAPbot rotate z*180}
//nbstitch
//cylinder { <0.4, 1.26, -0.11>, <0.4, 1.38, -0.11>, .01 pigment {Black} }
//cylinder { <-0.4, 1.26, -0.11>, <-0.4, 1.38, -0.11>, .01 pigment {Black} }
#declare STITCH=
cylinder { <0.4, 1.46, -0.01>, <0.4, 1.58, -0.01>, .01 texture { STITCHTX}}
#declare STITCHALL=
union{
#declare sIndex = .2;
#while(sIndex <= 3.5)  //3
object { STITCH translate y*sIndex }
  #declare sIndex = sIndex + .2;
#end
}
object {STITCHALL translate z*-.015} //top right    translate z*-.01
object {STITCHALL translate x*-0.8 translate z*-.015}//top left
object {STITCHALL translate y*-6.76 translate z*-.015}//bottom right   translate
z*-.1
object {STITCHALL translate <-0.8,-6.76,0> translate z*-.015} //bottom left
// straploop
//#declare LOOP=
#difference{
object { Round_Box_Union(<-.55, 4.75, -.1>, <.55, 5.05, .1>, .06) texture {
STRAPTEX}}//pigment {White/4}}
object { Round_Box_Union(<-.51, 4.6, -.05>, <.51, 5.2, .2>, .06) texture {
STRAPTEX}}//pigment {White/4}}
translate <-0,  -1.0, -0.0>
}
//?
box { <-.1, 4.7, -.0>, <.1, 4.9, .1> pigment {White}}
//top of strap
object{ Round_Cylinder_Union(<-.5, 4.8, 0.05>, <.5,4.8, 0.05>,.15 , .01) texture
{ STRAPTEX} scale <1,1,0.4>}
//cylinder { <0.4, -0.05, -0.05>, <0.4, 0.05, -0.035>, .01 pigment {White}
rotate x*15 translate y*4.87}
//cylinder { <0.4, -0.05, -0.040>, <0.4, 0.05, -0.025>, .01 pigment {White}
rotate x*-20 translate y*4.74}
// top metal thing
object{Round_Cone_Union(<.55,4.8, 0.05>,.05,<.55,5.2, 0.05>, .08 .01)pigment
{White}}
object{Round_Cone_Union(<-.55,4.8, 0.05>,.05,<-.55,5.2, 0.05>, .08 .01)pigment
{White}}
#declare TORLOOP=
torus { 0.3, 0.08 rotate x*90 clipped_by { plane { -y, 0.0 } }
clipped_by { plane { x, 0.0 inverse}}
//translate <.31,5.5,0>
}
object {TORLOOP translate <.25,5.2,0.05> pigment {Red}}
object {TORLOOP rotate y*180 translate <-.25,5.2,0.05> }
cylinder { <-0.25, 5.5, 0.05>, <0.25,5.5, 0.05>, .08 pigment {Red}}
//loop stick     //4.8                  //5.5
union{
cylinder { <-0., -0.0, -0.02>, <0.,.58, -0.03>, .04  pigment {Yellow} }
sphere { <0, 0, -0.03>, 0.040 translate y*.58 pigment {Yellow/2}}
rotate x*-2.9 translate y*4.9}
//bottom
//#declare BOT=                                                  //.03
object{ Round_Cylinder_Union(<-.0, 0, -0.01>, <-.0,0, 0.1>,.495 , .0300 )
clipped_by { plane { y, 0.0 } } scale <1,1.4,1>
        texture { STRAPTEX}  translate y*-4.65   translate y*-0.5
    // scale <0.99,1,0.98>                    new
       }
//object{ Round_Cylinder_Union(<.25, -4.9, 0.05>, <.25,-4.9, -0.05>,.15 , .01)
pigment {White/2} scale z*0.4}
//++++++++++++++++++++++bottom
stitch++++++++++++++++++++++++++++++++++++++++++++++++++

#declare Zback = -.01;
//torus { 0.4, 0.01  clipped_by { plane { -z, 0.0 } }  rotate x*90
//clipped_by { plane {y, 0.0 inverse}rotate -z*180 }
//pigment {White} //scale y*1.4
//translate y*-4.59  translate z*Zback
//}
//cylinder { <0.4, 1.36, -0.01>, <0.4, 1.68, -0.01>, .01 pigment
{White}translate y*-6.6}
#declare BOTstich=
 union{
torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.01 } }
clipped_by { plane {y, 0.0 inverse}rotate -z*13 }
texture { STITCHTX}//  pigment {White}//
scale <1,1.4,1> //y*1.4
translate y*-4.7  translate z*Zback   translate z *-.015
}

torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.0 } rotate -z*20}
clipped_by { plane {y, 0.0 inverse}rotate -z*34 }
texture { STITCHTX}//pigment {White}//
 scale <1,1.4,1>
translate y*-4.7  translate z*Zback   translate z *-.015
}

torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.0 } rotate -z*40}
//position
clipped_by { plane {y, 0.0 inverse}rotate -z*58 }//lenght
texture { STITCHTX}//pigment {White}//
 scale <1,1.4,1>
translate y*-4.7  translate z*Zback   translate z *-.015
}

torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.0 } rotate -z*64}
clipped_by { plane {y, 0.0 inverse}rotate -z*90 }
texture { STITCHTX}// pigment {White}//
scale <1,1.4,1>
translate y*-4.7  translate z*Zback   translate z *-.015
}

torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.0 } rotate -z*100}
clipped_by { plane {y, 0.0 inverse}rotate -z*120 }
texture { STITCHTX}//pigment {White}
scale <1,1.4,1>
translate y*-4.7  translate z*Zback  translate z *-.015
}

torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.0 } rotate -z*126}
clipped_by { plane {y, 0.0 inverse}rotate -z*142 }
texture { STITCHTX}//pigment {White}
scale <1,1.4,1>
translate y*-4.7  translate z*Zback  translate z *-.015
}

torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.0 } rotate -z*148}
clipped_by { plane {y, 0.0 inverse}rotate -z*162 }
texture { STITCHTX}//pigment {White}
scale <1,1.4,1>
translate y*-4.7  translate z*Zback  translate z *-.015
}

torus { 0.4, 0.01 rotate x*90 clipped_by { plane { y, 0.0 } rotate -z*167}
clipped_by { plane {y, 0.0 inverse}rotate -z*182 }
texture { STITCHTX}//pigment {White}
scale <1,1.4,1>
translate y*-4.7  translate z*Zback   translate z *-.015
}
translate y*-.5  }// end union BOTstich
object{ BOTstich }   // translate z*-.015
// object {TSTITCHb translate y*-4.7  translate z*-.005 }
//object {TSTITCHb  translate y*-4.7  translate z*-.005 rotate z*-35}

}//end union watch
//object {WATCH rotate y*0 pigment {White} translate x*0 }


Post a reply to this message

From: Thomas de Groot
Subject: Re: stiches
Date: 20 Sep 2014 07:35:51
Message: <541d6697$1@news.povray.org>
On 20-9-2014 12:29, Peter Warren wrote:
> this has been driving me crazy for years. whats the deal with the stiches not
> showing up on this watchband? (hope this inc file is enough for anyone who care
> to check it.)
> btw. pov rocks!

Hmm... You would need to clean up the code a bit first. Unable to make 
it work.

Thomas


Post a reply to this message

From: Peter Warren
Subject: Re: stiches
Date: 7 Oct 2014 06:40:00
Message: <web.5433c2285932df6b6998e57f0@news.povray.org>
Thanks Tom.

I will try to clean it up.

Tanks again,

Pete

Thomas de Groot <tho### [at] degrootorg> wrote:
> On 20-9-2014 12:29, Peter Warren wrote:
> > this has been driving me crazy for years. whats the deal with the stiches not
> > showing up on this watchband? (hope this inc file is enough for anyone who care
> > to check it.)
> > btw. pov rocks!
>
> Hmm... You would need to clean up the code a bit first. Unable to make
> it work.
>
> Thomas


Post a reply to this message

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