Re: 16bit Zdepth?

Date : Fri, 23 Feb 2007 23:49:27 +0100
To : <XSI(at)Softimage.COM>
From : "Tim Leydecker" <BauerOink(at)gmx.de>
Subject : Re: 16bit Zdepth?
Coming back to the original question (even thought my head aches, too).

How about the Softimage renderer? Given that mR is not so effective
when trying to render without any AA, how´s the old renderer doing?

I know, I´m not supposed to mention M**a again and again, it´s just
that I (finally) realized it has this other software renderer that is really
fast without AA. I´m currently rendering Tif16 (as suggested) using
a ramp/gradient projection perpendicular and attached to the camera.

Is simple enough and it works quite well to modulate the gradient to
have the fallof desired, e.g. either linear or more exponential, in case
one would directly want to (not accurately) mimic different focal lengths
and their expected sharp zone (fallof). I´m just using linear to play later, tho...

Cheers

tim


----- Original Message ----- From: "André Adam" <a_adam(at)49games.de>
To: <XSI(at)Softimage.COM>
Sent: Friday, February 23, 2007 9:18 AM
Subject: Re: 16bit Zdepth?



Now, that was my setup yesterday, except for the beer exchanged with Gin-Tonic. Ahh, where is that box of Aspirin when you really need it...

;)


Halfdan Ingvarsson wrote:

Low lights, smoky room, and a pint of beer.


- ½


------------------------------------------------------------------------

*From:* owner-xsi(at)Softimage.COM [mailto:owner-xsi(at)Softimage.COM] *On Behalf Of *Kris Rivel
*Sent:* 22-Feb-07 13:47
*To:* XSI(at)Softimage.COM
*Subject:* Re: 16bit Zdepth?



You are all going to be dreaming of samples tonight if this thread continues....ugh. Look, I just want to know one thing.......what setting makes my render look best :-)


Kris Rivel
3D Artist
kris(at)krisrivel.com <mailto:kris(at)krisrivel.com>
www.krisrivel.com <http://www.krisrivel.com>



André Adam wrote:

The if(allsamples=0){} idea is a good explanation why both mechanisms seem to work. Thanks for the input! :)

   -André


Halfdan Ingvarsson wrote:

A) Triangle filter of size 1 will have zero weights on the edges. So in the case of 1/1 samples, the middle sample will have a weight of 1.0 while the rest (which are all on the edges of the pixel) will have a weight of 0.0. Therefore the middle pixel is the only one sampled.

B) I'm guessing from the couple of tests that I did that in the case of a combined weight of zero over all samples covered by the filter, mental ray will simply pick a single, unweighted sample to use. Possibly, the lower-left pixel sample. In this case the image shifts, compared to the center-sample case.

The filter is always rectangular, not elliptical.

 - ½


-----Original Message-----
From: owner-xsi(at)Softimage.COM <mailto:owner-xsi(at)Softimage.COM> [mailto:owner-xsi(at)Softimage.COM] On Behalf Of André Adam
Sent: 22-Feb-07 12:45
To: XSI(at)Softimage.COM <mailto:XSI(at)Softimage.COM>
Subject: Re: 16bit Zdepth?


That doesn't seem to work for my logic; what happens when rendering Sampling 0/0 with a Triangle or Gauss Filter set to 1?

A) If the filter size is a radius in pixel length, and the filter works from the pixel's center rather from than the corners, then four samples will be hit by the filter. Five in case of a Sampling 1/1. Should therefore show an aa effect.

B) If the filter size is a diameter in pixel length, and the filter works from the pixel's center rather than from the corners, while four samples are hit by the filter, all of their values are multplied by a zero weight and the result should be a pitch black picture. Certainly doesn't work this way.

Looking at the empirics, I get perfectly non-aa pictures with both techniques, sampling 1/1 and sampling 0/0 combined with either triangle or gaussian filter set to 1. Though the pictures differ a bit.

What's the missing piece in the puzzle now? :)

Cheers!

    -André


Halfdan Ingvarsson wrote:

Mental ray samples on pixel corners but filters from the pixel centre.

With that in mind, the only way to get a non-shifted, non-blurred, point-sampled image is to render with sampling at 1/1 and using a triangle filter at 1. This ensures that only the center sample is used in the final output, with the rest thrown out.

Unfortunately, it is also hideously expensive.

 - ½

-----Original Message-----
From: owner-xsi(at)Softimage.COM <mailto:owner-xsi(at)Softimage.COM> [mailto:owner-xsi(at)Softimage.COM] On Behalf Of André Adam
Sent: 22-Feb-07 11:54
To: XSI(at)Softimage.COM <mailto:XSI(at)Softimage.COM>
Subject: Re: 16bit Zdepth?


The minimum filter range is 1 pixel (radius), and since the samples are shot in a one-sample-per-pixel raster, the filter will *always* reach the neighbouring samples. The trick is to use a filter with a zero-weight at the maximum extent, like triangle or gauss. Box will have a 1 weight throughout the whole distance, therefore combining the original pixel's sample value with the neighbouring ones.

Oh, and I guess the jitter option should be turned off for all of this to work; haven't tried that, but it should cause problems due to the need for an even sampling raster (see above).

Cheers!

    -André

Daniel Rind wrote:

It's Sampling at 0 / 0, and filter size at 1 (the minimum).
Each pixel is sampled at least 2^2/min/ times and at most 2^2/max/ times in each direction.
So for 0 / 0 this means 1 x 1, and for 1 / 1 it would mean 4 x 4, or 16 samples per pixel.
The filter /shouldn't/ make any difference, but oddly it does. Box filtering adds blur and shifts the whole image down and left by half a pixel (really odd), so take triangle filtering.
Ciao, Daniel!


2007/2/22, Tim Leydecker <BauerOink(at)gmx.de <mailto:BauerOink(at)gmx.de> <mailto:BauerOink(at)gmx.de>>:

    Hey,

    thanks alot guys! I´ve had great success with a projection
    of a gradient piped into a constant shader and that one
    assigned the partition (like it simple, the backroundpartition).

    It´s just that rendering bit that puzzles me. To rinse and repeat,
    I use Filtering set to 0/0, or is it 1/1?

    That´s the bit I don´t get, how to make sure I have no AA at all.

    From there it´s still somewhat challenging to get the correct
    mapping (e.g. linear instead of gamma corrected) out of XSI
    but that one I should get together by rendering to float/linear.

    I can´t test the above today since I´m still working in Maya
    but allready do most of my personal stuff in XSI (at home) it
    would be great to also optimize that in depth once and for all.

    The more I have the chance to compare the apps, the less
    satisfied I am with Maya, btw. Especially when shading and
    rendering with passes in mind. Oh, boy. Additionally, it´s Maya8...

    Cheers

    tim


----- Original Message -----
From: "Joe Laffey" <joe(at)laffey.tv <mailto:joe(at)laffey.tv> <mailto:joe(at)laffey.tv> >
To: <XSI(at)Softimage.COM <mailto:XSI(at)Softimage.COM> <mailto:XSI(at)Softimage.COM>>
Sent: Thursday, February 22, 2007 4:18 PM
Subject: RE: 16bit Zdepth?



> On Thu, 22 Feb 2007, Kim Aldis wrote:
>
>>> -----Original Message-----
>>> From: owner-xsi(at)Softimage.COM <mailto:owner-xsi(at)Softimage.COM> <mailto:owner-xsi(at)Softimage.COM>
[mailto:owner-xsi(at)Softimage.COM <mailto:owner-xsi(at)Softimage.COM>] On
>>> Behalf Of Andreas Bystrom
>>> Sent: 22 February 2007 13:25
>>> To: XSI(at)Softimage.COM <mailto:XSI(at)Softimage.COM> <mailto:XSI(at)Softimage.COM>
>>> Subject: Re: 16bit Zdepth?
>>>
>>> grab a scalar-state, plug that into a change_range node and
finally
>>> plug the change_range into the surface port, leave the
scalar-state
>>> settings as it is and set the "new range start" to 0 and "new
range
>>> end" to 1 in the change range node, your old and new-range
parameters
>>> should be set to the distance where you want the depth-pass to
start
>>> and end, you can link these 2 values to nulls with an
expression and
>>> use those to control the depth-pass
>
>
>> You may also find that a linear falloff isn't necessarily what
you need.
>> Plugging the output of the change range into a grad will allow
you to tweak
>> it, if you need to.
>>
>
> I think the non-linear mapping would be better done in the
compositor, though. That
> way you have the option of linear or putting a curve on it.
>
> --
> Joe Laffey | Visual Effects for Film and Video
> LAFFEY Computer Imaging | -------------------------------------
> St. Louis, MO | Show Reel http://LAFFEY.tv/?e04685
> USA | -------------------------------------
> . | -*- Digital Fusion Plugins -*-
>
--------------------------------------------------------------------------


    > Mail here will be rejected --> "Real Trap" <


---
Unsubscribe? Mail Majordomo(at)Softimage.COM with the following text in body:
unsubscribe xsi


---
Unsubscribe? Mail Majordomo(at)Softimage.COM with the following text in body:
unsubscribe xsi


Search the XSI List archives here or use the advanced search form to search across mailing lists. Searching help is available.
This site supposedly brought to you by Benjamin Grosser and the Imaging Technology Group.