[pstricks] pst-3dplot
Michael Sharpe
msharpe at ucsd.edu
Fri Jul 4 19:01:22 CEST 2008
Alpha, Beta values are stored in \psk at ThreeDplot@Alpha and
\psk at ThreeDplot@Beta.
Michael
On Jul 4, 2008, at 9:18 AM, camus.philippe at free.fr wrote:
> Selon camus.philippe at free.fr:
>
>> Selon Christoph Bersch <usenet at bersch.net>:
>>
>>> camus.philippe at free.fr schrieb:
>>>>
>>>> \pspicture(-5,-5)(5,5)
>>>> \psset{Alpha=150,Beta=40}
>>>> \pstThreeDCoor[xMin=0,xMax=4,yMin=0,yMax=4,zMin=0,zMax=4]
>>>> \def\al{60}\def\be{130} %just because I can't use \Alpha and
>>>> \Beta !
>>>> \FPeval{a}{cos(\be)*sin(\al)}
>>>> \FPeval{b}{cos(\be)*cos(\al)}
>>>> \FPeval{c}{sin(\be)}
>>>>
>>>> \pstThreeDLine(\a,\b,\c)(0,0,0)
>>>>
>>>> \endpspicture
>>>>
>>>> I expect that the 3DLine is reduced to a point (the origin).
>>>
>>> I don't known why you expect this. \a \b and \c each contain a
>>> number
>>> (which are all != 0 for your angles), so you plot a line from the
>>> point
>>> specified by theses coordinates to the origin.
>>>
>>> Christoph
>>
>> Because the transformation frome 3D to 2D is made through the
>> matrix :
>> (-cos(al) sin(al) 0 )
>> M=( )
>> (-sin(al)sin(be) -cos(al)sin(be) cos(be))
>> and (if my computations are OK),
>> (\a) (0)
>> M* (\b)= ( ).
>> (\c) (0)
>>
>> (this is what I mean by "kernel" of the matrix.
>> More generally, every projection is made following a direction, and
>> I'm
>> looking
>> for this direction...
>>
>> Philippe
>>
> Sorry
> the answer is sometimes too obvious !
> fp seems to work with radians when postscript uses degrees !
> that's ll !
> but I'd still be glad to know how to use Alpha and Beta directly in
> the
> computation.
>
> Philippe
> _______________________________________________
> PSTricks mailing list
> PSTricks at tug.org
> http://tug.org/mailman/listinfo/pstricks
>
More information about the PSTricks
mailing list