POV-Ray : Newsgroups : povray.general : Modify already created object Server Time
8 Jul 2024 13:38:36 EDT (-0400)
  Modify already created object (Message 11 to 15 of 15)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: clipka
Subject: Re: Modify already created object
Date: 29 Aug 2014 18:59:44
Message: <540105e0@news.povray.org>
Am 29.08.2014 22:48, schrieb bublible:

> Another problem: I am not able find pattern that would do "radial gradient",
> that is circle blending (normal gradient transform linear on x or y axis). I was
> trying: onion, planar, wood...with all there is one big problem: I need to apply
> it to polygon (simple square) STARTING FROM THE CENTER, but all those patterns
> starting from a corner??? Being webdesigner I never saw anything like that cos
> when I apply circle/radial gradient those are centric circles, not ones having
> their center in a corner. I was trying to transalte its center but it did not do
> what I was expecting...please, help again my friend if you can. :(

Those patterns are not starting from a corner - they're starting from 
the coordinate origin (i.e. <0,0,0>). If you want it to start at e.g. 
<X,Y,Z>, apply translate the texture using "translate <X,Y,Z>".


Maybe you should read the tutorial in the docs.


Post a reply to this message

From: Alain
Subject: Re: Modify already created object
Date: 29 Aug 2014 22:00:32
Message: <54013040@news.povray.org>

> clipka <ano### [at] anonymousorg> wrote:
>> Am 29.08.2014 16:21, schrieb bublible:
>>
>>> BTW some other question: how can I access some array values? I mean vector
>>> values like ldd_camera_position variable consists of 3 values of x, y and z. Now
>>> how can I access them individually? I come from FLASH ActioScript2 scene and
>>> there you would do it easily like "ldd_camera_position[x]" where "x" is the
>>> index number beginning with 0...so how it is made in PovRay, please?
>>
>> You can access the components of some vector MyVector as follows:
>>
>>     MyVector.x
>>     MyVector.y
>>     MyVector.z
>
> Thanx a lot.
>
> Another problem: I am not able find pattern that would do "radial gradient",
> that is circle blending (normal gradient transform linear on x or y axis). I was
> trying: onion, planar, wood...with all there is one big problem: I need to apply
> it to polygon (simple square) STARTING FROM THE CENTER, but all those patterns
> starting from a corner??? Being webdesigner I never saw anything like that cos
> when I apply circle/radial gradient those are centric circles, not ones having
> their center in a corner. I was trying to transalte its center but it did not do
> what I was expecting...please, help again my friend if you can. :(
>
>
>
>

The onion pattern give you a repeating spherical gradient that is 
centered at the origin, or <0,0,0> going from zero at the origin, 
climbing to 1 at a radius of 1 then drop to zero.

The wood pattern give you a cylindrical repeating pattern along the Z axis.

The followings DON'T repeat :

The planar pattern evaluate to 1 on the X-Z plane and drop to zero at 
+1*y and -1*y.

The spherical pattern evaluate to 1 at <0,0,0> and drop to zero ar a 
radius of 1 in every directions.

The cylincrical pattern evaluate to 1 at the Y axis and drop to zero at 
a radius of 1 parallel to the x-z plane.

In POV-Ray, most pattern fill the space and the objects are "carved" 
from them. There are a few exeptions: aoi and slope.

Objects take the pattern from the location where they are created. After 
the pattern is applyed to an object, then, the pattern will follow that 
object's rotations, scallings and translations. If the pattern is 
applyed after any transform, the pattern will look as if it's moving on 
the object, but it realy is the other way around: The object is moving 
through the pattern.



Alain


Post a reply to this message

From: bublible
Subject: Re: Modify already created object
Date: 31 Aug 2014 07:15:01
Message: <web.5403034baf00b5afb91df8500@news.povray.org>
clipka <ano### [at] anonymousorg> wrote:
> Am 29.08.2014 22:48, schrieb bublible:
>
> > Another problem: I am not able find pattern that would do "radial gradient",
> > that is circle blending (normal gradient transform linear on x or y axis). I was
> > trying: onion, planar, wood...with all there is one big problem: I need to apply
> > it to polygon (simple square) STARTING FROM THE CENTER, but all those patterns
> > starting from a corner??? Being webdesigner I never saw anything like that cos
> > when I apply circle/radial gradient those are centric circles, not ones having
> > their center in a corner. I was trying to transalte its center but it did not do
> > what I was expecting...please, help again my friend if you can. :(
>
> Those patterns are not starting from a corner - they're starting from
> the coordinate origin (i.e. <0,0,0>). If you want it to start at e.g.
> <X,Y,Z>, apply translate the texture using "translate <X,Y,Z>".
>
>
> Maybe you should read the tutorial in the docs.

I DID READ IT BUT IT WAS OF NO HELP TO ME THEREFORE I AM ASKING HERE, DON'T YOU
THINK?!

Some time before I did exactly what you are advising me to do BUT all it does is
growing bigger NOT MOVING PATTERN CENTER...so what you are advising me to do
don't work as expected at all as I already try it out before as I said...but
thanx anyway.


Post a reply to this message

From: clipka
Subject: Re: Modify already created object
Date: 31 Aug 2014 08:27:33
Message: <540314b5$1@news.povray.org>
Am 31.08.2014 13:14, schrieb bublible:
> clipka <ano### [at] anonymousorg> wrote:
>> Am 29.08.2014 22:48, schrieb bublible:
>>
>>> Another problem: I am not able find pattern that would do "radial gradient",
>>> that is circle blending (normal gradient transform linear on x or y axis). I was
>>> trying: onion, planar, wood...with all there is one big problem: I need to apply
>>> it to polygon (simple square) STARTING FROM THE CENTER, but all those patterns
>>> starting from a corner??? Being webdesigner I never saw anything like that cos
>>> when I apply circle/radial gradient those are centric circles, not ones having
>>> their center in a corner. I was trying to transalte its center but it did not do
>>> what I was expecting...please, help again my friend if you can. :(
>>
>> Those patterns are not starting from a corner - they're starting from
>> the coordinate origin (i.e. <0,0,0>). If you want it to start at e.g.
>> <X,Y,Z>, apply translate the texture using "translate <X,Y,Z>".
>>
>>
>> Maybe you should read the tutorial in the docs.
>
> I DID READ IT BUT IT WAS OF NO HELP TO ME THEREFORE I AM ASKING HERE, DON'T YOU
> THINK?!

I'm not saying "read the docs", I'm saying "reat the tutorial in the 
docs"; maybe I should have been a bit more clear and written "work 
through the tutorial". You don't read tutorials to help you with a 
particular question, but to get the gist of some program, and it doesn't 
sound like you got the gist of POV-Ray yet - you're coming from another 
direction and seem to be expecting POV-Ray to work the same, but it doesn't.

If you go on like that, you /will/ be asking countless questions here 
about stuff that might all become clear while working through the 
tutorial, and you /will/ be frustrated about the responses because 
people will be unable to understand what your real problems are, and/or 
you won't be able to make much sense of their answers.

> Some time before I did exactly what you are advising me to do BUT all it does is
> growing bigger NOT MOVING PATTERN CENTER...so what you are advising me to do
> don't work as expected at all as I already try it out before as I said...but
> thanx anyway.

It does work, believe me. The reason why you couldn't get it to work 
like you expected is likely due to some other - probably rather 
fundamental - misunderstanding about POV-Ray.


Oh, and you might want to work on that attitude of yours; getting all 
upset about a neutral reply, just because it suggests stuff you think 
you already tried, won't get you anywhere. (To the contrary, you risk 
pissing off people that would otherwise be willing to continue trying to 
help you.) Remember, people can't see what you did and what you didn't, 
they can merely guess. And also there's the possibility that when you 
tried it you made some mistakes.


Post a reply to this message

From: William F Pokorny
Subject: Re: Modify already created object
Date: 31 Aug 2014 09:07:34
Message: <54031e16$1@news.povray.org>
On 08/29/2014 06:59 PM, clipka wrote:
> Am 29.08.2014 22:48, schrieb bublible:
>
> Those patterns are not starting from a corner - they're starting from
> the coordinate origin (i.e. <0,0,0>). If you want it to start at e.g.
> <X,Y,Z>, apply translate the texture using "translate <X,Y,Z>".
>
> Maybe you should read the tutorial in the docs.
>
I'll add the scenes sub directory shipped with POV-Ray contains a large 
number of working examples.

In particular for the kinds of questions being asked in this thread, 
there is a portfolio sub directory. The *.ini files must be run for the 
POV-Ray features of interest. For example, "povray allpatterns.ini" 
creates pngs for most-all of the in-built POV-Ray patterns.

After creation of the pngs, you can view an example of each feature by 
bringing up index.html in a web browser. For example, "firefox 
index.html". The *.pov files used for the portfolio provide ready 
corresponding example code for the features a basis for further 
experimentation and learning.

Running all the *.ini files takes a little time and it creates about 
20MB of data in total using the set up as shipped. I use the portfolio 
less these days, but on starting with POV-Ray, I found it very useful.

Bill P.


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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