More render scripts. (object masks and depth maps)

TheNathanParableTheNathanParable Posts: 1,046
edited December 1969 in Product Suggestions

I would really like it if someone were to create some more scripts for the 3Delight Scripted Renderer. In particular, i'd like a script that would render black and white masks of particular objects for postworking later on, as well as perhaps a basic depth map one (based on the focal settings of an existing camera). I know there are already products available that do similar things, but as far as I know they only work in older versions of Daz Studio. That and having them as render scripts rather than special cameras would make them easier to use.

Comments

  • JaderailJaderail Posts: 0
    edited December 1969

    The atmospheric cameras for DS (works in ds4.5 and ds4.6) has a depth camera in it.

  • adamr001adamr001 Posts: 1,322
    edited December 1969

    I'm toying around with Scripts for creating surface/object masks for postwork right now. Funny you should bring it up.

  • TheNathanParableTheNathanParable Posts: 1,046
    edited December 1969

    If you fancy a beta tester, well... ;)

  • adamr001adamr001 Posts: 1,322
    edited December 1969

    I'm still a fair bit away from needing another tester. If I get there and feel it's needed I'll consider it. :)

  • adamr001adamr001 Posts: 1,322
    edited December 1969

    Making progress. :)

    Currently does/supports:
    - Hides standard lights (those that show on the Lights pane)
    - Positive Masks
    - Negative Masks
    - Opacity Maps
    - EHSS/USS/USS2/DzDefault Material Displacement Maps

    Still to do:
    - Support Tiling Textures (required for full displacement map support)
    - Optionally Automatically render the results to the default render settings setup
    - Optionally Automatically UNDO the surface changes after automatic render
    - Optionally Automatically UNDO the lighting changes after automatic render
    - Support for Furify/SuperSuit Fur displacement textures.

    Right now it works like this. Select your surfaces, run the script, choose the map type (positive or negative). Then YOU have to trigger the render process. After rendering you can "UNDO" the changes using DS built-in UNDO commands (CTRL+Z, or the back arrow on the nav bar, etc.)

    Some sample masks :)

    cthulu-positive-map-test.jpg
    1000 x 1000 - 129K
    cthulu-negative-map-test.jpg
    1000 x 1000 - 132K
    transmaptest2.jpg
    1000 x 1000 - 36K
    transmaptest.jpg
    2000 x 2000 - 194K
  • adamr001adamr001 Posts: 1,322
    edited December 1969

    Oh and the cthulu scene without masks so you can see :)

    cthulhu02_zpw.jpg
    2000 x 2000 - 661K
  • adamr001adamr001 Posts: 1,322
    edited December 1969

    And interesting note... the DoF camera used in the original render was also used in the mask renders, so you still get that same fuzzy focus bit goign on.

  • TheNathanParableTheNathanParable Posts: 1,046
    edited December 1969

    Oh, so they're normal scripts that change the surfaces and not actual 3Delight Scripted Renderers?

  • adamr001adamr001 Posts: 1,322
    edited December 1969

    Yes, that's what they are. There are advantages and disadvantages to both approaches.

  • adamr001adamr001 Posts: 1,322
    edited December 1969

    Tiling is now supported.

    However, Furify/Supersuit Fur (which are the same shader btw) are unsupportable. They're simply not documented/labelled well enough for me to be able to make it happen. The scripts currently flatten these to default and ignore displacement. Sorry. :(

  • scorpioscorpio Posts: 8,418
    edited December 1969

    Oh this will be SOOOO good to have.

  • Lissa_xyzLissa_xyz Posts: 6,116
    edited June 2013

    Thought I'd post here as I just found this out: if you render your image to a *.TIF file, you have a black/white mask/alpha channel in your channels list when you open the image up in an editor.

    TIF carries a larger file size, and JPG/GIF/PNG cannot save alpha channel info. You'll need to re-save the TIF as a PSD (smaller file size depending on layers/data) if you don't want to keep the TIF.

    If you want to keep the alpha mask as a jpg, click your alpha channel to turn it into a selection (ctrl-click for photoshop), make a new layer and fill it with white, inverse the selection and fill the inverse with black. You can now save that layer as it's own image.

    Post edited by Lissa_xyz on
  • SzarkSzark Posts: 10,634
    edited December 1969

    adamr001 said:
    Tiling is now supported.

    However, Furify/Supersuit Fur (which are the same shader btw) are unsupportable. They're simply not documented/labelled well enough for me to be able to make it happen. The scripts currently flatten these to default and ignore displacement. Sorry. :(

    I am looking forward to replacing Surface mask Creator as it isn't up to the job now in DS4.5/6, yes it still works after a fashion but very limited. Will this be a store product Adam?
  • agent unawaresagent unawares Posts: 3,513
    edited December 1969

    If you care to do a bit of fiddling in the Shader Mixer, I have a snippet here, no restrictions on use, which allows surface-based depth shaders.

  • adamr001adamr001 Posts: 1,322
    edited December 1969

    @Szark: Undecided. I've approached DAZ to discuss several ideas with them.

    @Agent: Cool, I may take a look. i still have a couple of bugs to work out in my rendering process for the surface scripts at this point, but after that I'll think about digging into the surface-based depth shaders.

  • adamr001adamr001 Posts: 1,322
    edited December 1969

    Vaskania said:
    Thought I'd post here as I just found this out: if you render your image to a *.TIF file, you have a black/white mask/alpha channel in your channels list when you open the image up in an editor.

    TIF carries a larger file size, and JPG/GIF/PNG cannot save alpha channel info. You'll need to re-save the TIF as a PSD (smaller file size depending on layers/data) if you don't want to keep the TIF..

    PNG also carries alpha. I use them that way all the time.
  • SzarkSzark Posts: 10,634
    edited December 1969

    adamr001 said:
    @Szark: Undecided. I've approached DAZ to discuss several ideas with them.
    Either way I am looking forward to this. :)
  • Lissa_xyzLissa_xyz Posts: 6,116
    edited June 2013

    adamr001 said:
    Vaskania said:
    Thought I'd post here as I just found this out: if you render your image to a *.TIF file, you have a black/white mask/alpha channel in your channels list when you open the image up in an editor.

    TIF carries a larger file size, and JPG/GIF/PNG cannot save alpha channel info. You'll need to re-save the TIF as a PSD (smaller file size depending on layers/data) if you don't want to keep the TIF..

    PNG also carries alpha. I use them that way all the time.

    Does it? Photoshop removes the option to save the alpha channel when you use PNG. The option only lights up for me on TIF. Hrmph. =/

    Even if I uncheck "as a copy" it still doesn't preserve the alpha.

    Also, I'm not meaning just creating a transparent png (that I can do via save for web). I'm talking an actual separate alpha channel in the channels tab. Apparently Photoshop merges the alpha in with the RGB rather than preserving the channel separately.

    Post edited by Lissa_xyz on
  • ChoholeChohole Posts: 33,604
    edited June 2013

    Although there isn't an option to save an alpha channel when saving as a png in PS I find that all my pngs can be used in my program of choice with the alpha intact as long as i have made an alpha layer (ie a black and white one), and I use a very old version of PS.

    Post edited by Chohole on
  • 3dOutlaw3dOutlaw Posts: 2,471
    edited December 1969

    Was just looking for something like this, are you still working on it?

Sign In or Register to comment.