POV-Ray : Newsgroups : povray.general : About the unit Server Time
6 Nov 2024 00:30:12 EST (-0500)
  About the unit (Message 1 to 7 of 7)  
From: Wu Yang
Subject: About the unit
Date: 26 Nov 2002 21:51:49
Message: <3de43345@news.povray.org>
Hi, all
   Does someone know the unit of the distance between the camera and object?
Thanks

Wu Yang


Post a reply to this message

From: Rafal 'Raf256' Maj
Subject: Re: About the unit
Date: 26 Nov 2002 21:55:18
Message: <Xns92D3275B41849raf256com@204.213.191.226>
"Wu Yang" <wya### [at] cswrightedu> wrote in news:3de43345@news.povray.org

> Hi, all
>    Does someone know the unit of the distance between the camera and
>    object? 
> Thanks

Your question is very hard to undersand.
There are no "units" in POV, all metrics (including ditance beetween camera 
to object) are in "Pov-units"

If you make scene 

sphere { // eath 
0 1.0
.. }

then 1 unit will be milons miles, and in scene 

sphere { 0 1.0 ... } // atom 

1 unit = 0.00000000000000000000000000001 " (or less)
 

-- 
#macro g(U,V)(.4*abs(sin(9*sqrt(pow(x-U,2)+pow(y-V,2))))*pow(1-min(1,(sqrt(
pow(x-U,2)+pow(y-V,2))*.3)),2)+.9)#end#macro p(c)#if(c>1)#local l=mod(c,100
);g(2*div(l,10)-8,2*mod(l,10)-8)*p(div(c,100))#else 1#end#end light_source{
y 2}sphere{z*20 9pigment{function{p(26252423)*p(36455644)*p(66656463)}}}//M


Post a reply to this message

From: Wu Yang
Subject: Re: About the unit
Date: 26 Nov 2002 22:47:25
Message: <3de4404d$1@news.povray.org>
Thank you for your reply
> There are no "units" in POV, all metrics (including ditance beetween
camera
> to object) are in "Pov-units"
>
Yes, you are right. Do you know how to measure the length , width , height
of a object? Thanks

Best Regards
Wu Yang


Post a reply to this message

From: Christopher James Huff
Subject: Re: About the unit
Date: 26 Nov 2002 23:14:25
Message: <chrishuff-2D19F6.23113826112002@netplex.aussie.org>
In article <3de4404d$1@news.povray.org>,
 "Wu Yang" <wya### [at] cswrightedu> wrote:

> Yes, you are right. Do you know how to measure the length , width , height
> of a object? Thanks

Length, width, and height are human measurements that would depend on 
the object. If you can specify the object, you should know its 
dimensions.

You could get an approximation of its extents along the x, y, and z axii 
by taking the corners of its bounding box, you can access this 
information with the min_extent() and max_extent() functions. Automatic 
bounding isn't always perfect though, the bounding box may fit a bit 
"loosely", especially on things like CSG difference or intersection and 
blob objects. And this information might not be useful...for example, 
the length of a cone is the distance between its end points, the length 
of a plane is the distance from its nose to its tail, but the extents 
are always of an axis-aligned bounding box containing the object.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tagpovrayorg
http://tag.povray.org/


Post a reply to this message

From: Sir Charles W  Shults III
Subject: Re: About the unit
Date: 27 Nov 2002 10:57:45
Message: <3de4eb79$1@news.povray.org>
If you know where your camera is in POVray (in coordinates or units) and you
also know where your object is, the distance is sqrt( (x2 - x1)^2 + (y2 - y1)^2
+ (z2 - z1)^2 ), the old and venerable Pythagorean theorem.
    <x1, y1, z1> should be your camera location, and <x2, y2, z2> should be your
object location.

Cheers!

Chip Shults
My robotics, space and CGI web page - http://home.cfl.rr.com/aichip


Post a reply to this message

From: Christopher James Huff
Subject: Re: About the unit
Date: 27 Nov 2002 13:46:20
Message: <chrishuff-88C488.13433627112002@netplex.aussie.org>
In article <3de4eb79$1@news.povray.org>,
 "Sir Charles W. Shults III" <aic### [at] cflrrcom> wrote:

>     If you know where your camera is in POVray (in coordinates or units) and 
> you also know where your object is, the distance is sqrt( (x2 - x1)^2 
> + (y2 - y1)^2 + (z2 - z1)^2 ), the old and venerable Pythagorean 
> theorem.
>     <x1, y1, z1> should be your camera location, and <x2, y2, z2> should be 
> your object location.

vlength(Pt - CamPos) is a bit easier and faster parsing. You only really 
need the Pythagorean equation when you are writing functions. Similar to 
using vrotate() instead of sin() and cos(), or vtransform() or transform 
functions instead of doing the transformations manually.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tagpovrayorg
http://tag.povray.org/


Post a reply to this message

From: Sir Charles W  Shults III
Subject: Re: About the unit
Date: 27 Nov 2002 18:57:08
Message: <3de55bd4$1@news.povray.org>
Thanks.  I read the docs when I need to find something out, but having done
a lot of math in the past, I often just write a function or equation without
looking for a shortcut.

Cheers!

Chip Shults
My robotics, space and CGI web page - http://home.cfl.rr.com/aichip


Post a reply to this message

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