proposed feature: interpreting view names in rad

A view file is supposed to represent one (1) view. The last line of the view file is considered to be the view spec. Considering a view file to be a collection of multiple views is counter productive.

It seems to me that there are a few ways to do what you want:

   1. create multiple rif files with each one representing a "view
      group" and containing multiple "view=" lines, note this is really
      one of the things that rif file is for, that is to create coherent
      groupings of views with respect to a set of
      geometry/materials/lighting as defined in an octree....
   2. enhance your script to include a separate "view group" file, the
      script can parse the view group file and pass the relevant views
      to the rif file, in essence building a rif file on the fly....
   3. ranimate, as Thomas suggests, you could probably do something with
      the ANIMATE parameter for ranimate pointing to a script to produce
      the correctly modified octree and use a VIEWFILE with all your
      views in it.

-Jack

Thomas Bleicher wrote:

···

Have you considered using ranimate here?

Thomas

On Wed, Jul 22, 2009 at 9:05 AM, Lars O. Grobe<[email protected]> wrote:
  

Hi,

I am not sure whether this would break anything, but it would be a rather
useful way of organizing renderings:

At the moment, I can pass a view name to rad using the -v parameter, and
this will cause exactly one view to be rendered, which must have been named
in the view= line in the rif file.

Now, this view= line can point to a view file, which may contain more then
one view. I would have expected rad to render all the views in that file,
but as -v is defined to render exactly one view, rad takes only one of the
views defined in the view file and ignores the others.

I would propose to change this behaviour. If I call rad e.g. as

rad -v myview myoctree.oct

it would be very useful if rad would look whether it finds a view= line for
myview. If it finds one defining one view, render that. If it finds one
pointing to a view file, render all the views in that view file. If I call
rad as

rad -v anotherview -v myview myoctree.oct

it should render all views defined in the view= lines for anotherview and
myview, be it view files or view definitions inside the rif.

One reason this would be helpful is as such: I am currently working on a
scene, which needs some view-dependent processing. So I have a script which
does some work, cleans up, creates an octree, creates photon maps, and then
calls rad. Now I would like to call the same rif-file for all of these, as
it eventually contains the same information for all renderings except the
views. And I cannot render all views at once, as I have to modify the octree
before moving to the next "view group" (this translates to rooms in my
example).

I am sure that there are other uses for this. What do you think? Is there
any way people may have used the -v parameter that could imply the risk of
breaking compatibility by introducing such a change?

Cheers Lars.

--
Lars O. Grobe (Mr) :: Research Fellow, Solar Energy Research Institute of
Singapore SERIS :: National University of Singapore :: 7 Engineering Drive
1, Block #E3A-06-35, Singapore 117576 :: 65-6516 5816(Tel) :: 65-6775 1943
(Fax) :: [email protected] (E) :: www.seris.sg (W) :: Company Registration
No: 200604346E

Important: This email is confidential and may be privileged. If you are not
the intended recipient, please delete it and notify us immediately; you
should not copy or use it for any purpose, nor disclose its contents to any
other person. Thank you.

_______________________________________________
Radiance-general mailing list
[email protected]
http://www.radiance-online.org/mailman/listinfo/radiance-general

_______________________________________________
Radiance-general mailing list
[email protected]
http://www.radiance-online.org/mailman/listinfo/radiance-general
  
--
# Jack de Valpine
# president
#
# visarc incorporated
# http://www.visarc.com
#
# channeling technology for superior design and construction

Hi Thomas, hi Jack!

Thomas wrote:

Have you considered using ranimate here?

Yes, I have used it for all kind of stuff before. But in my case, I
would have to add configuration files for ranimate additionally to the
rif. And all I want to do is rendering three groups of views. I know
that there are work-arounds, but I cannot imagine any case where one
would need the current behaviour of rad to render only the first view of
a viewfile, as in that case one would not have added other views to the
same file (or had commented them out.

Jack wrote:

A view file is supposed to represent one (1) view. The last line of
the view file is considered to be the view spec. Considering a view
file to be a collection of multiple views is counter productive.

Regarding the idea, that there should always be only one view per view
file, this is a contradiction to the behaviour of core radiance tools.
rvu e.g. appends views to an existing view file, and I can cat a view
file with hundreds of views into rpict, which will happily render one by
one. I cannot use these view-files only in rad, as (only) this tool
reads only the last line of a view file.

At the moment I am using a "<myview.vf" at the end of the render= line
in my rif file. This is a work-around, but not a nice one, as it
disables filtering and naming.

BTW, we should also change the default extension for filtered frames to
hdr in rad, now that there is a mime-type registred.

Cheers, Lars.

Hi Lars,

Jack wrote:
  

A view file is supposed to represent one (1) view. The last line of
the view file is considered to be the view spec. Considering a view
file to be a collection of multiple views is counter productive.
    
Regarding the idea, that there should always be only one view per view
file, this is a contradiction to the behaviour of core radiance tools.
rvu e.g. appends views to an existing view file, and I can cat a view
file with hundreds of views into rpict, which will happily render one by
one. I cannot use these view-files only in rad, as (only) this tool
reads only the last line of a view file.
  
I think that we have some disagreement here. Rpict reads a view file and takes the last line of the file and uses that as the view parameters to render. Rad is designed to pass named view parameters or view files to rpict, if you want rad to do multiple views you can input multiple "view=" lines in the rif file. By using "cat" you are using a unix tool (outside the Radiance toolbox) to output each line of the file to stdout, this is different than what rad does, and creates a different expectation for what a viewfile contains, eg mapping of one view file to one camera location vs mapping of one view file to many camera locations.... Effectively a rif file serves as a way to group multiple views to a particular octree definition, thus resulting in a mapping of one file (a rif file) to many views by means of the rad tool.

If you have only three groupings of views why not just create three separate rif files?

-Jack