POV-Ray : Newsgroups : povray.general : almost a paralellagram Server Time
23 Nov 2024 21:00:22 EST (-0500)
  almost a paralellagram (Message 1 to 7 of 7)  
From: David Kraics
Subject: almost a paralellagram
Date: 22 Jan 2023 06:15:00
Message: <web.63cd1a8e975f41801c1b6180a57e0@news.povray.org>
Hi guys, I'm back with another puzzle. I create objects but placing a jpeg of
the item on a prim and placing prims on the picture to match. In today's work I
am placing prims in order to difference out a window. The two sides are angled,
and match each other. The bottom is straight, but the top is at an angle. I use
a shape called wedge, that I made a couple decades ago, and almost have the
whole thing filled out. as below


#declare wedge=    //common wedge shape with 45 degree angle. One unit in size.
difference{
 box{<0,0,-.5>,<1,1,.5>}
 box{<0,-1,-1>,<2,2,1>
  rotate<0,0,45>
  translate<1,0,0>}
 }


union{
 object{wedge scale<.05,.48,.01> translate<2.02,.12,0>}
 object{wedge scale<.25,.05,.01> translate<1.77,.54,0>}
 object{wedge
  rotate<0,180,0>
  rotate<180,0,0>
  scale<.05,.48,.01> translate<1.77,.54,0>}
 box{<1.77,.12,-.01>,<2.02,.54,.01>}
 }

this leaves an oddly shaped chunk in the top left corner that my mind can't fill
in, at 6am in the morning. The side and top should meet, but the wedge won't
work. Any ideas?


Post a reply to this message

From: David Kraics
Subject: Re: almost a paralellagram
Date: 22 Jan 2023 06:20:00
Message: <web.63cd1bc936034bd81c1b6180a57e0@news.povray.org>
"David Kraics" <bar### [at] aolcom> wrote:
> Hi guys, I'm back with another puzzle. I create objects but placing a jpeg of
> the item on a prim and placing prims on the picture to match. In today's work I
> am placing prims in order to difference out a window. The two sides are angled,
> and match each other. The bottom is straight, but the top is at an angle. I use
> a shape called wedge, that I made a couple decades ago, and almost have the
> whole thing filled out. as below
>
>
> #declare wedge=    //common wedge shape with 45 degree angle. One unit in size.
> difference{
>  box{<0,0,-.5>,<1,1,.5>}
>  box{<0,-1,-1>,<2,2,1>
>   rotate<0,0,45>
>   translate<1,0,0>}
>  }
>
>
> union{
>  object{wedge scale<.05,.48,.01> translate<2.02,.12,0>}
>  object{wedge scale<.25,.05,.01> translate<1.77,.54,0>}
>  object{wedge
>   rotate<0,180,0>
>   rotate<180,0,0>
>   scale<.05,.48,.01> translate<1.77,.54,0>}
>  box{<1.77,.12,-.01>,<2.02,.54,.01>}
>  }
>
> this leaves an oddly shaped chunk in the top left corner that my mind can't fill
> in, at 6am in the morning. The side and top should meet, but the wedge won't
> work. Any ideas?

BTW, to help make it clearer, the locations of the four points is below.
1.72x .6y 0z
2.02x .54y 0z
1.77x .12y 0z
2.07x .12y 0z


Post a reply to this message

From: David Kraics
Subject: Re: almost a paralellagram
Date: 22 Jan 2023 06:55:00
Message: <web.63cd23d636034bd81c1b6180a57e0@news.povray.org>
NEVERMIND
I replaced the coding with this

union{
 object{wedge scale<.05,.48,.01> translate<2.02,.12,0>}
 difference{
  box{<1.72,.12,-.01>,<2.02,.6,.01>}
  object{wedge scale<.05,.48,1> translate<1.72,.12,0>}
  object{wedge
   rotate<0,180,0>
   rotate<180,0,0>
   scale<.3,.05,1> translate<2.02,.6,0>}
   }
 }


Post a reply to this message

From: Alain Martel
Subject: Re: almost a paralellagram
Date: 22 Jan 2023 10:57:30
Message: <63cd5cea$1@news.povray.org>
Le 2023-01-22 à 06:14, David Kraics a écrit :
> Hi guys, I'm back with another puzzle. I create objects but placing a jpeg of
> the item on a prim and placing prims on the picture to match. In today's work I
> am placing prims in order to difference out a window. The two sides are angled,
> and match each other. The bottom is straight, but the top is at an angle. I use
> a shape called wedge, that I made a couple decades ago, and almost have the
> whole thing filled out. as below
> 
> 
> #declare wedge=    //common wedge shape with 45 degree angle. One unit in size.
> difference{
>   box{<0,0,-.5>,<1,1,.5>}
>   box{<0,-1,-1>,<2,2,1>
>    rotate<0,0,45>
>    translate<1,0,0>}
>   }
> 
> 
> union{
>   object{wedge scale<.05,.48,.01> translate<2.02,.12,0>}
>   object{wedge scale<.25,.05,.01> translate<1.77,.54,0>}
>   object{wedge
>    rotate<0,180,0>
>    rotate<180,0,0>
>    scale<.05,.48,.01> translate<1.77,.54,0>}
>   box{<1.77,.12,-.01>,<2.02,.54,.01>}
>   }
> 
> this leaves an oddly shaped chunk in the top left corner that my mind can't fill
> in, at 6am in the morning. The side and top should meet, but the wedge won't
> work. Any ideas?
> 

Why don't you use a prism object ?


Post a reply to this message

From: David Kraics
Subject: Re: almost a paralellagram
Date: 22 Jan 2023 11:50:00
Message: <web.63cd686a36034bd81c1b6180a57e0@news.povray.org>
Alain Martel <kua### [at] videotronca> wrote:


>
> Why don't you use a prism object ?

I don't know how. There are still tons of options and stuff I never used. All
these years, I have made do with basic prims. Only recently did I use triangles
to create a shape I couldn't by the normal means.


Post a reply to this message

From: David Kraics
Subject: Re: almost a paralellagram
Date: 22 Jan 2023 12:00:00
Message: <web.63cd6b1536034bd81c1b6180a57e0@news.povray.org>
I just read up on the prism object. OMG this will make things easier!


Post a reply to this message

From: Bald Eagle
Subject: Re: almost a paralellagram
Date: 22 Jan 2023 21:00:00
Message: <web.63cde98a36034bd81f9dae3025979125@news.povray.org>
"David Kraics" <bar### [at] aolcom> wrote:
> I just read up on the prism object. OMG this will make things easier!

Yes indeed.
What will make even easier still is plopping ready-made code examples into your
scene with a few clicks from the drop-down Insert menu.

Have a look at:
Insert --->  Basic Shapes Angular


Post a reply to this message

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