|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> With orthographic, the cut should be something like a box (sides aligned
> with the camera)
Currently, there is a code block which handles the planes that cause the cut to
make the back post invisible.
To achieve this, two planes are created like this:
#declare Plane1 = plane {-x, 0 rotate y * Alpha};
#declare Plane2 = plane { x, 0 rotate y *-Alpha};
Where Alpha is the distance from the camera position to the vertical post that
needs to be visible. This is done by the following:
#local r = R;
#local Alpha = asin(r / ViewVector) * 180 / pi;
This makes the conical shape from the cube to the camera.
Since I now use the orthographic camera, I need to change this setting by making
the two planes simply parallel to each other and fixed to the ViewVector for
animation purposes.
What should I do to solve this problem?
I am also attaching a screenshot of what the scene looks like with the
orthographic camera and the default angle.
Post a reply to this message
Attachments:
Download 'orthographic.png' (106 KB)
Preview of image 'orthographic.png'
|
|
| |
| |
|
|
From: Le Forgeron
Subject: Re: To Encore, Making part of an object tranparent
Date: 3 Dec 2012 13:56:46
Message: <50bcf5ee$1@news.povray.org>
|
|
|
| |
| |
|
|
Le 03/12/2012 17:00, Encore nous fit lire :
>
>> With orthographic, the cut should be something like a box (sides aligned
>> with the camera)
>
> Currently, there is a code block which handles the planes that cause the cut to
> make the back post invisible.
>
> To achieve this, two planes are created like this:
>
> #declare Plane1 = plane {-x, 0 rotate y * Alpha};
> #declare Plane2 = plane { x, 0 rotate y *-Alpha};
>
> Where Alpha is the distance from the camera position to the vertical post that
> needs to be visible. This is done by the following:
>
> #local r = R;
> #local Alpha = asin(r / ViewVector) * 180 / pi;
>
Well, instead of rotating your plane, translate it.
something along:
#declare Plane1 = plane { -x, 0 translate r*x }; // and so on
now, I wonder if it should be asin or atan ? (given that r is probably
small when compared to ViewVector, that might be irrelevant)
Or maybe I do not understand R, r & ViewVector.
Alpha is not a distance, it's an angle.
> This makes the conical shape from the cube to the camera.
> Since I now use the orthographic camera, I need to change this setting by making
> the two planes simply parallel to each other and fixed to the ViewVector for
> animation purposes.
> What should I do to solve this problem?
>
> I am also attaching a screenshot of what the scene looks like with the
> orthographic camera and the default angle.
>
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Well, instead of rotating your plane, translate it.
> something along:
> #declare Plane1 = plane { -x, 0 translate r*x }; // and so on
>
> now, I wonder if it should be asin or atan ? (given that r is probably
> small when compared to ViewVector, that might be irrelevant)
> Or maybe I do not understand R, r & ViewVector.
>
> Alpha is not a distance, it's an angle.
>
Yeah sorry for that I meant the angle. Well I've tried the translate r*x
and at first it looks just fine (it's attached to the left and right part of the
back edge) but then if I start animating the scene, the planes are just messed
up, as if they don't track that edge any more. I am pretty sure I'm not tracking
the edge with the ViewVector that's why it's messed up when I animate it
Post a reply to this message
|
|
| |
| |
|
|
From: Ger
Subject: Re: To Encore, Making part of an object tranparent
Date: 6 Dec 2012 03:33:29
Message: <50c05859@news.povray.org>
|
|
|
| |
| |
|
|
Encore wrote:
>
> I still can't figure out how to change the camera to an orthographic view.
> When I set the camera to orthographic, it simply messes up my "cuts", I
> would guess because those cuts are something like cone shapes that extend
> from the camera position to the point on the object, whereas it should now
> be more like a long parallelogram because of the different perspective.
> Any ideas how I can tackle this problem? :/
I have it figured out, by not using the orthographic camera, but pulling the
camera way back from the object and then zooming in. It didn't work the
first time because I had a mix-up in my math.
Camera distance increased by 1000
--
Ger
Post a reply to this message
Attachments:
Download 'transpattempt2000.png' (93 KB)
Preview of image 'transpattempt2000.png'
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> I have it figured out, by not using the orthographic camera, but pulling the
> camera way back from the object and then zooming in. It didn't work the
> first time because I had a mix-up in my math.
>
> Camera distance increased by 1000
> --
> Ger
So basically you change the Cam0Location to something like
#declare Cam0Location = < 0 , 1 ,-1000>;
which puts it to -1000 on the z-axis. How would you zoom in then after that?
Post a reply to this message
|
|
| |
| |
|
|
From: Le Forgeron
Subject: Re: To Encore, Making part of an object tranparent
Date: 6 Dec 2012 10:44:25
Message: <50c0bd59$1@news.povray.org>
|
|
|
| |
| |
|
|
Le 06/12/2012 16:33, Encore nous fit lire :
>
>> I have it figured out, by not using the orthographic camera, but pulling the
>> camera way back from the object and then zooming in. It didn't work the
>> first time because I had a mix-up in my math.
>>
>> Camera distance increased by 1000
>> --
>> Ger
>
> So basically you change the Cam0Location to something like
> #declare Cam0Location = < 0 , 1 ,-1000>;
>
> which puts it to -1000 on the z-axis. How would you zoom in then after that?
>
I guess: a small angle.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> > So basically you change the Cam0Location to something like
> > #declare Cam0Location = < 0 , 1 ,-1000>;
> >
> > which puts it to -1000 on the z-axis. How would you zoom in then after that?
> >
> I guess: a small angle.
Yeah I was about to post another reply about that.
I changed the angle to about 0.380
and the #declare Cam0Location = < 0 , 1000 ,-1000>;
After that, I needed to translate the camera along the x-axis like this:
#declare Cam0Location = vrotate(Cam0Location, <0, CamAngle/1, 0>) + <450, 30,
-3>;
It still needs some configurations but the problem is that the wedges do not
extend until the object anymore, so the result looks something like what you can
see in the screenshot:
Post a reply to this message
Attachments:
Download 'transpattempt.png' (35 KB)
Preview of image 'transpattempt.png'
|
|
| |
| |
|
|
From: Ger
Subject: Re: To Encore, Making part of an object tranparent
Date: 6 Dec 2012 12:31:02
Message: <50c0d656@news.povray.org>
|
|
|
| |
| |
|
|
Encore wrote:
>
>> I have it figured out, by not using the orthographic camera, but pulling
>> the camera way back from the object and then zooming in. It didn't work
>> the first time because I had a mix-up in my math.
>>
>> Camera distance increased by 1000
>> --
>> Ger
>
> So basically you change the Cam0Location to something like
> #declare Cam0Location = < 0 , 1 ,-1000>;
>
> which puts it to -1000 on the z-axis. How would you zoom in then after
> that?
Code is in povray.text.scene-files
--
Ger
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Le_Forgeron wrote:
> Le 06/12/2012 16:33, Encore nous fit lire :
>>
>>> I have it figured out, by not using the orthographic camera, but pulling
>>> the camera way back from the object and then zooming in. It didn't work
>>> the first time because I had a mix-up in my math.
>>>
>>> Camera distance increased by 1000
>>> --
>>> Ger
>>
>> So basically you change the Cam0Location to something like
>> #declare Cam0Location = < 0 , 1 ,-1000>;
>>
>> which puts it to -1000 on the z-axis. How would you zoom in then after
>> that?
>>
> I guess: a small angle.
No, what I did was increase direction
#declare CamFactor = frame_number/100;
//#declare CamFactor = 1000;
#declare CamAngle = frame_number;
#declare Cam0Location = < 0 , (1+CamFactor) ,0>;
#declare Cam0Location = vrotate(Cam0Location, <0, 0, CamAngle>);
#declare Cam0Location = vrotate(Cam0Location, <0, CamAngle, 0>) + (<-3, 3,
-3>*(1+CamFactor));
#declare Cam1Location = <8.0 , 1.5 ,5>;
/*
Declare the illusion camera pointing along the z-axis
*/
#declare UseIllusionCamera = 1;
#if (UseIllusionCamera)
camera {
location Cam0Location
look_at <0.0 , 0.0 , 0.0>
direction z * CamFactor
right image_width / image_height * x
}
Doing it this way gives me a perfect view on what the difference is
--
Ger
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Encore wrote:
>> > So basically you change the Cam0Location to something like
>> > #declare Cam0Location = < 0 , 1 ,-1000>;
>> >
>> > which puts it to -1000 on the z-axis. How would you zoom in then after
>> > that?
>> >
>> I guess: a small angle.
>
> Yeah I was about to post another reply about that.
> I changed the angle to about 0.380
> and the #declare Cam0Location = < 0 , 1000 ,-1000>;
>
> After that, I needed to translate the camera along the x-axis like this:
> #declare Cam0Location = vrotate(Cam0Location, <0, CamAngle/1, 0>) + <450,
> #30,
> -3>;
>
> It still needs some configurations but the problem is that the wedges do
> not extend until the object anymore, so the result looks something like
> what you can see in the screenshot:
I had a mix-up in my code which wasn't apparent at short distances. I have
tried it with direction z * 1e8 and it still works now.
--
Ger
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|