POV-Ray : Newsgroups : povray.newusers : Sphere_sweep doubt Server Time
2 Jul 2024 11:18:16 EDT (-0400)
  Sphere_sweep doubt (Message 1 to 8 of 8)  
From: a galli
Subject: Sphere_sweep doubt
Date: 4 Oct 2010 12:05:01
Message: <web.4ca9fa775bdef7053a1866be0@news.povray.org>
I am trying to draw several bonding wires between electronics components. I
opted to use sphere_sweep because the wires should roughly follow a parabola.
However, when I add too many instances to my design, only a small part of the
wires is represented.
Here is the code to reproduce the problem:


//#version 3.6;

#include "colors.inc"

global_settings {
  assumed_gamma 1.0
  max_trace_level 10
}

camera{
 location <-20,10, -4>
 direction 1.5*z
 right x*image_width/image_height
 look_at <4,0,-4>
}

background {color rgb <1,1,1>}

light_source {
  <0, 0, 0>            // light's position (translated below)
  color rgb <1, 1, 1>  // light's color
  translate <-30, 30, -30>
}



#macro Bonding(Inizio,Fine)
 #local Distanza= vlength(Fine-Inizio);
 #local Raggio = 0.020;
 sphere_sweep{
  cubic_spline
  4,
  Inizio + <0,-Distanza,0>, Raggio
  Inizio, Raggio
  Fine, Raggio
  Fine + <0,-Distanza,0>, Raggio
  tolerance 0.1
  texture{pigment{Red}}
 }
#end


#declare Altezza_base = 0.5;
#declare Altezza_gradino = 1;
#declare Altezza_cima_package = Altezza_base+Altezza_gradino;
#declare Altezza_ceramica = 0.5;
#declare Altezza_pellet = 0.5;
#declare Altezza_peltier = Altezza_ceramica*3+Altezza_pellet*2;
#declare Altezza_Base = 0.63;
#declare Altezza_scheda = 1.2;
#declare Quota_scheda =
Altezza_cima_package+Altezza_peltier-Altezza_scheda+Altezza_Base;
#declare Pos_x_ceramica = 0;
#declare Pos_z_ceramica = 0;

// Posizione pad
#declare Pad_Ceramica_base_esterni_1 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-3.40, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_2 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-2.60, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_3 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-2.20, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_4 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-1.80, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_5 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-1.40, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_6 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-1.00, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_7 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-0.60, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_8 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <-0.20, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_9 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <0.20, 0, -3.15>;
#declare Pad_Ceramica_base_esterni_10 = <Pos_x_ceramica,
Quota_scheda+Altezza_scheda, Pos_z_ceramica> + <0.60, 0, -3.15>;

// Posizione pad
#declare Pad_Ceramica_scheda_1 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <-0.0, 0, 0>;
#declare Pad_Ceramica_scheda_2 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <0.8, 0, 0>;
#declare Pad_Ceramica_scheda_3 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <1.2, 0, 0>;
#declare Pad_Ceramica_scheda_4 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <1.6, 0, 0>;
#declare Pad_Ceramica_scheda_5 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <2.0, 0, 0>;
#declare Pad_Ceramica_scheda_6 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <2.4, 0, 0>;
#declare Pad_Ceramica_scheda_7 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <2.8, 0, 0>;
#declare Pad_Ceramica_scheda_8 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <3.2, 0, 0>;
#declare Pad_Ceramica_scheda_9 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <3.6, 0, 0>;
#declare Pad_Ceramica_scheda_10 = <Pos_x_ceramica-3.40,
Quota_scheda+Altezza_scheda, Pos_z_ceramica-4.70> + <4.0, 0, 0>;


object{Bonding(Pad_Ceramica_base_esterni_1, Pad_Ceramica_scheda_1)}
object{Bonding(Pad_Ceramica_base_esterni_2, Pad_Ceramica_scheda_2)}
object{Bonding(Pad_Ceramica_base_esterni_3, Pad_Ceramica_scheda_3)}
object{Bonding(Pad_Ceramica_base_esterni_4, Pad_Ceramica_scheda_4)}
object{Bonding(Pad_Ceramica_base_esterni_5, Pad_Ceramica_scheda_5)}
object{Bonding(Pad_Ceramica_base_esterni_6, Pad_Ceramica_scheda_6)}
object{Bonding(Pad_Ceramica_base_esterni_7, Pad_Ceramica_scheda_7)}
object{Bonding(Pad_Ceramica_base_esterni_8, Pad_Ceramica_scheda_8)}
object{Bonding(Pad_Ceramica_base_esterni_9, Pad_Ceramica_scheda_9)}
object{Bonding(Pad_Ceramica_base_esterni_10, Pad_Ceramica_scheda_10)}


If I comment out the last line, however, the wires are drawn in their entirety.
Could someone explain what am I doing wrong here?
Thank you in advance


Post a reply to this message

From: Christian Froeschlin
Subject: Re: Sphere_sweep doubt
Date: 4 Oct 2010 15:53:08
Message: <4caa30a4$1@news.povray.org>
a_galli wrote:

> I am trying to draw several bonding wires between electronics components. I
> opted to use sphere_sweep because the wires should roughly follow a parabola.
> However, when I add too many instances to my design, only a small part of the
> wires is represented.

I can reproduce the problem in 3.7 beta 39 (although for me,
reducing the number of objects doesn't improve the situation).
Making them thicker seems to help but is not a real solution.
I think sphere_sweeps are rather known for being suspectible
to numerical problems. You could try if you can get away
with scaling a portion of a torus instead.


Post a reply to this message

From: Florian Siegmund
Subject: Re: Sphere_sweep doubt
Date: 7 Oct 2010 18:10:01
Message: <web.4cae4512bca4eba63686c44f0@news.povray.org>
"a_galli" <and### [at] gmailcom> wrote:
> If I comment out the last line, however, the wires are drawn in their entirety.
> Could someone explain what am I doing wrong here?
> Thank you in advance

It seems as if pov-ray's automatic bounding system did not handle those objects
right (i wonder why...? bugs? *bzzzz*)
So to bypass this problem, you could manually bound your objects (bounded_by
{...}) or simply add +MB or Bounding=off in the ini settings.
Result: pov-ray renders slower but renders right :)

Regards,
Florian


Post a reply to this message

From: Florian Siegmund
Subject: Re: Sphere_sweep doubt
Date: 7 Oct 2010 18:15:01
Message: <web.4cae45bfbca4eba63686c44f0@news.povray.org>
Sorry, typo... it hast to be "-MB"!


Post a reply to this message

From: Christian Froeschlin
Subject: Re: Sphere_sweep doubt
Date: 8 Oct 2010 08:52:24
Message: <4caf1408$1@news.povray.org>
Florian Siegmund wrote:

> Sorry, typo... it hast to be "-MB"!

Didn't seem to solve the problem here so I don't
think it is a bounding issue.


Post a reply to this message

From: a galli
Subject: Re: Sphere_sweep doubt
Date: 9 Oct 2010 10:30:01
Message: <web.4cb07bb2bca4eba6f4c27d2c0@news.povray.org>
Christian Froeschlin <chr### [at] chrfrde> wrote:
> Florian Siegmund wrote:
>
> > Sorry, typo... it hast to be "-MB"!
>
> Didn't seem to solve the problem here so I don't
> think it is a bounding issue.

Disabling auto bounding does indeed solve the issue for me. However, these are
part of a much larger scene, so the rendering would become unacceptably slow.
Thank you for your suggestion, though.


Post a reply to this message

From: Christian Froeschlin
Subject: Re: Sphere_sweep doubt
Date: 9 Oct 2010 12:33:22
Message: <4cb09952$1@news.povray.org>
a_galli wrote:

> Disabling auto bounding does indeed solve the issue for me. However,
> these are part of a much larger scene, so the rendering would become
> unacceptably slow.

strange that it didn't work here, I probably did something
wrong. But if it solves your problem for you can use manual
bounding as Florain suggested (look up "bounded_by").


Post a reply to this message

From: Kenneth
Subject: Re: Sphere_sweep doubt
Date: 10 Oct 2010 05:25:00
Message: <web.4cb185aabca4eba6196b08580@news.povray.org>
"Florian Siegmund" <flo### [at] gmxat> wrote:

> It seems as if pov-ray's automatic bounding system did not handle those objects
> right (i wonder why...? bugs? *bzzzz*)
> So to bypass this problem, you could manually bound your objects (bounded_by
> {...}) ...

Unfortunately, there's a manual-bounding problem in POV-Ray v3.6 (the one that
the OP's using) whereby manually-added bounding shapes are automatically removed
(from *some* objects) even when they shouldn't be; i.e., Remove_Bounds (in the
INI file) seems to always be 'ON' in such cases, even when turned off. It's
discussed in an older thread...

http://news.povray.org/povray.bugreports/thread/%3Cweb.4b9ad12c8fcde48e18d0cecb0%40news.povray.org%3E/?tmax=100&mtop=33
9469

AFAIK, this behavior has been corrected in one of the 3.7 betas.

Ken


Post a reply to this message

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