SimplyMaya Forums

Welcome to the forum, feel free to ask questions here.

Home / forum / Lounges / Maya Basics & Newbie Lounge / render out z depth
Register FAQ Members List Calendar Mark Forums Read

New Thread
 
Thread Tools
Old 12-03-2007, 11:21 AM   #1
Radical Edward
Registered User
 
Radical Edward's Avatar
 
Join Date: Jan 2006
Posts: 234
Thanks: 0
Thanked 0 Times in 0 Posts
Default render out z depth

How can I render out the z-depth, i.e. closeness to the camera, as a grayscale image? I've seen it done around the place but I'm not sure how to do it.
Radical Edward is offline   Reply With Quote
Old 12-03-2007, 11:35 AM   #2
jsprogg
Lifetime Member
 
jsprogg's Avatar
 
Join Date: Feb 2004
Location: Chicago
Posts: 1,708
Thanks: 0
Thanked 85 Times in 77 Posts
Default

From the Maya docs..

To create a Depth file
Turn on Depth Channel (Z Depth) in the Render Settings window.
Open the renderable camera's Attribute Editor in which you want to create a depth file.

Select View > Camera Attribute Editor from the current view. See View > Camera Attribute Editor.
In the camera's Attribute Editor, select a Depth Type from the Output Settings section (Closest or Furthest Visible Depth).
To view depth channels
View the animation file using FCheck.

See the Overview of FCheck in the Rendering Utilities guide for information on FCheck.
Press z to see the depth channel.

FCheck does not let you view the z-depth data of an .IFF file. To view z-depth data, use a non .IFF file format and then view the z-depth data stored in the separate file.

If the output format is not IFF or RLA, Maya writes a separate depth file containing a black RGBA image with depth values.
jsprogg is offline   Reply With Quote
Old 13-03-2007, 02:04 AM   #3
farbtopf
Subscriber
 
farbtopf's Avatar
 
Join Date: Jul 2005
Location: London
Posts: 520
Thanks: 0
Thanked 1 Time in 1 Post
Default

@jsprogg

god thank you sooo much, i've been looking for an answer to that question quite a while now.
farbtopf is offline   Reply With Quote
Old 13-03-2007, 03:25 AM   #4
j5ive
Subscriber
 
j5ive's Avatar
 
Join Date: Feb 2005
Location: Sunny Ol' Wigan, UK
Posts: 752
Thanks: 0
Thanked 6 Times in 6 Posts
Default

What is this useful/purpose for?
__________________
If you believe in telekinesis, raise my right hand.
j5ive is offline   Reply With Quote
Old 13-03-2007, 03:47 AM   #5
farbtopf
Subscriber
 
farbtopf's Avatar
 
Join Date: Jul 2005
Location: London
Posts: 520
Thanks: 0
Thanked 1 Time in 1 Post
Default

it is mainly for post production. You'll need it to apply certain effects in compositors like after effects shake etc. It tells them for example how far pixels have been away from the camera, so you can do a depth of field.
farbtopf is offline   Reply With Quote
Old 13-03-2007, 06:17 AM   #6
Radical Edward
Registered User
 
Radical Edward's Avatar
 
Join Date: Jan 2006
Posts: 234
Thanks: 0
Thanked 0 Times in 0 Posts
Default

ok, well I try to follow those instructions, and I get a tower.jpg and a tower_Depth.iff. The iff I can only view in maya, and it's just a useless black square :/ any ideas what's up?

Last edited by Radical Edward : 13-03-2007 at 06:19 AM.
Radical Edward is offline   Reply With Quote
Old 14-03-2007, 04:47 AM   #7
Radical Edward
Registered User
 
Radical Edward's Avatar
 
Join Date: Jan 2006
Posts: 234
Thanks: 0
Thanked 0 Times in 0 Posts
Default

found the problem. The depth file has a black RGB channel and contains the depth information in an additional channel. To get it out in photoshop, install the IFF reader plugin (look on google) and open the channels box, on mine it was Apha 2 (I had an alpha channel as well)

Also for reference mental ray does not appear to produce a depth map at all, at least not one that gets saved anywhere.
Radical Edward is offline   Reply With Quote
Old 01-04-2007, 05:23 AM   #8
danotronXX
Subscriber
 
danotronXX's Avatar
 
Join Date: Jun 2005
Location: cleveland ohio
Posts: 313
Thanks: 0
Thanked 3 Times in 3 Posts
Default

Quote:
Originally posted by farbtopf
it is mainly for post production. You'll need it to apply certain effects in compositors like after effects shake etc. It tells them for example how far pixels have been away from the camera, so you can do a depth of field.
could u also use the zdepth file to do a faded look at the objects farthest to the camera? if so how would u do it with after effects?
tks
danotronXX is offline   Reply With Quote
Old 01-04-2007, 06:36 AM   #9
farbtopf
Subscriber
 
farbtopf's Avatar
 
Join Date: Jul 2005
Location: London
Posts: 520
Thanks: 0
Thanked 1 Time in 1 Post
Default

Quote:
Originally posted by danotronXX
could u also use the zdepth file to do a faded look at the objects farthest to the camera? if so how would u do it with after effects?
tks
I think you are talking about depth of field. The thing is I never got it to work in AEF. But somehow you can. My problem was that I was never able to get Maya to include the z-depth into my files, regardless of what I did.
You might have more luck though. You ned to render your images from maya in a format that supports zdepth. .IFF does, but unfortunately after effects doesn't recognize the z in an .IFF, so don't use it. I heard that .RLA or 16bit Tiffs work. You can check if maya included a zchannel by opening the image in photoshop and looking in the channels tab. There should be something like an alpha2 channel that looks like a ghostly grayscale version of your render.
So you import you footage into after effects make a comp and go effects>3dchanne>depth of field. And it should work.
From now on you are on your own, because as I said I never got to that stage. But if you get it to work please let me know.

good luck
farbtopf is offline   Reply With Quote
Old 29-10-2016, 11:49 AM   #10
mircbone
Registered User
 
Join Date: Oct 2016
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by jsprogg View Post
From the Maya docs..

To create a Depth file
Turn on Depth Channel (Z Depth) in the Render Settings window.
Open the renderable camera's Attribute Editor in which you want to create a depth file.

Select View > Camera Attribute Editor from the current view. See View > Camera Attribute Editor.
In the camera's Attribute Editor, select a Depth Type from the Output Settings section (Closest or Furthest Visible Depth).
To view depth channels
View the animation file using FCheck.

See the Overview of FCheck in the Rendering Utilities guide for information on FCheck.
Press z to see the depth channel.

FCheck does not let you view the z-depth data of an .IFF file. To view z-depth data, use a non .IFF file format and then view the z-depth data stored in the separate file.

If the output format is not IFF or RLA, Maya writes a separate depth file containing a black RGBA image with depth values.
how do you get the depth values from this process ?
mircbone is offline   Reply With Quote
New Thread

« Previous Thread | Next Thread »

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Batch Rending Render Layers Ozgalis Lighting & Rendering 7 07-01-2011 06:04 PM

1 Month

$34

Month-to-month billing
$34/month
Unlimited access to all videos
Project files to download
Easy to cancel at anytime
 
 

3 months

$87

Billing every 3 months
$29/month
Unlimited access to all videos
Project files to download
Easy to cancel at anytime
Save $5 per month or $15 in total compared to monthly billing with this package.

12 months

$288

Billing every 12 months
$24/month
Unlimited access to all videos
Project files to download
Easy to cancel at anytime
Save $10 per month or $120 in total compared to monthly billing with this package.

Your plan will automatically renew. You can cancel at any time via your PayPal account to avoid being charged again.

You can view the FAQ on our video plans here. You can contact us directly here. By clicking one of the buttons above, you agree to our Terms and Privacy Policy.