Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

RealToon (An AAA Toon/Anime Shader and Stylized)

Discussion in 'Assets and Asset Store' started by MJQStudioWorks, Jun 30, 2016.

  1. JanKrocak

    JanKrocak

    Joined:
    Jul 11, 2021
    Posts:
    13
    Perfect, thank you!
     
    MJQStudioWorks likes this.
  2. Dirrogate

    Dirrogate

    Joined:
    Feb 18, 2014
    Posts:
    157
    @MJQStudioWorks This asset , from the output images and videos I'm seeing looks stellar and just might be what I want for a project (Graphic novel).
    I've been researching options via Blender, Daz and Unity.
    I searched this thread for cross-hatch / sketch/ Hatch but found nothing.

    Before I buy the asset, I wanted to know :
    - Can it do "hatching" similar say to this from Unity (https://assetstore.unity.com/packages/vfx/shaders/toonsketch-core-128224#description) I like that the hatch pattern is not just 'camera projected' but actually part of the texture
    - Or something like from Daz - Sketchy https://www.daz3d.com/sketchy-toon-edge-and-art-style-shaders-for-iray

    From watching the Realtoon youtube tutorials, I see the answer might be somewhere in using the shadowT textures?
    Not sure but would like to have your take on this.

    (also when would you be releasing the perspective foreshortening your working on? that video looked promising)
    Best wishes and hoping to get this asset soon if it can do cross-hatching in some way.
     
  3. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi Dirrogate,
    About cross hatching or sketch or even halftone you can do that my using the feature "PTexture" / "Patterned Texture"

    Here's a video how to make a manga look with the use of PTexture:


    *You can use any texture as pattern.

    About perspective foreshortening, my implementation of it is not that user friendly,
    so i cant really include it yet. I need to find or do more research about it and find a away to make it easy to use.

     
    Dirrogate likes this.
  4. Dirrogate

    Dirrogate

    Joined:
    Feb 18, 2014
    Posts:
    157
    oh thanks! I'm going to be a happy new client of Realtoon.
     
    MJQStudioWorks likes this.
  5. Dirrogate

    Dirrogate

    Joined:
    Feb 18, 2014
    Posts:
    157
    @MJQStudioWorks I dived in and bought this excellent asset. It's already looking great and is really intuitive in usage.

    I'm facing a problem though.
    I installed it in my HDRP project using Unity 2020 LTS. Now on upgrading the project to Unity 2021 latest build
    and then installing the Realtoon HDRP 12 package. everything looks fine, but the drop-down UI won't open up for materials that has Realtoon shader on it.

    - If I delete the Assets/RealToon/Editor/RealToonShaderGUI_HDRP_SRP I can then see the Material UI as regular unity sliders/tickboxes etc.

    Can you help fix this?
    I've also tried completely deleting the RealToon folder and re-importing the whole package (and reinstalling HDRP 12 version of the package)

    Attached error screenshot Capture.PNG
     
  6. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi Dirrogate,
    Thank you :)

    *Try to delete the "RealToon" folder then Import/unpack "RealToon" again and then unpack "RealToon (HDRP 12)" package.
    Be sure the "RealToon" folder is in the Root folder "Asset" don't put it in a folder.

     
    Dirrogate likes this.
  7. Dirrogate

    Dirrogate

    Joined:
    Feb 18, 2014
    Posts:
    157
    This is exactly what I've already done. No luck, unfortunately
    *edit: @MJQStudioWorks Could there be a clue in the error line its showing in the Realtoon_Shader_Gui_Hdrp script? (raytrace== true) Maybe the script is getting stuck there for some reason and not launching the UI/interface?
     
    Last edited: Mar 31, 2022
  8. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Thanks for the update,

    May i know what unity 2021 version are you using? And what HDRP 12 version too.
    Did you try in a empty new project?

    **I'll look into that line of code, thanks.

     
  9. Dirrogate

    Dirrogate

    Joined:
    Feb 18, 2014
    Posts:
    157
    @MJQStudioWorks
    Here's my setup
    - Unity 2021.2.17f1
    - latest Hdrp 12.1.6 (release March 22 - could this be the problem?)

    I tried everything in a blank Unity Hdrp template project and also with Raytracing turned on, yes, it is working.

    For my own not-working project I even deleted the Library folder and reimported everything - but no luck.
    Something must be interfering with the script?
    I wish Unity made a straightforward way of disabling Raytracing to check things out.
     
    Last edited: Mar 31, 2022
  10. Dirrogate

    Dirrogate

    Joined:
    Feb 18, 2014
    Posts:
    157
    @MJQStudioWorks
    I seem to have narrowed down the problem.
    If I comment out the line that checks for RayTracing, then everything works.
    I commented out the checks on these lines in the RealToonShaderGUI_HDRP_SRP.cs:
    line 1046
    line 1134
    line 2688

    Now I'm no coder, so I don't know what this will do going forward (and I do want to use Raytracing for the characters) but for now, at least it will let me build the scene.

    Can you suggest a fix? Maybe would be a good time to update the UI too
    thanks\
    Capture.PNG
     
  11. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Thanks for the update.

    *Yes i remember it now, there is also a realtoon user has this problem.
    Current solution is to comment that out.

    The purpose of that line of code is to hide those RayTracing option if RayTracing is not enabled on the project.
    I already planned to fix it on the next patch #5.

    Maybe unity did change something on their API again.

     
    Last edited: Mar 31, 2022
    Dirrogate likes this.
  12. Dirrogate

    Dirrogate

    Joined:
    Feb 18, 2014
    Posts:
    157
    Ok, understood.
    Just for further troubleshooting if you like, On a new project in 2021 with latest HDRP it works fine both, without raytracing and with Raytracing enabled.

    The problem seems to be on projects that are upgraded from Unity 2020 Raytracing, to Unity 2021. (and thus using the realtoon hdrp_12 package)
    Something then interferes. Even deleting the entire Realtoon folder are re-importing as well as deleting the entire Library folder did not solve it.

    I can't think where else some left-over settings might be lurking in a Unity project.
     
  13. Outrun-Yonn

    Outrun-Yonn

    Joined:
    Mar 21, 2022
    Posts:
    1
    Hello, I'm fairly new to Unity but I wanted to ask how one would go about changing the texture - Main color or the main color of a material via script. I looked through the document and tried using a public material variable and then making its color value the hexadecimal value of my color picker, which works for normal URP objects but when I turn on the Realtoon shader it doesn't seem to work anymore.
     
  14. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi, sorry for the late reply,
    I checked here, it work fine specially on a new project.
    Maybe there is something in your project that making that error or interfere like you said.
    Maybe check your project for some other error other than the RealToon Inspector script.

     
  15. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi keyonisawesome,
    To change the Color and Main Texture in the shader by script.
    Use these code:

    *For Color
    *Material.SetColor("_MainColor", the value or color);

    *For Texture
    *Material.SetTexture("_MainTexture", the value or texture);

    **Material is the material on the object that has the RealToon Shader.
    **_MainColor is the RealToon shader property for the main color.
    **_MainTexture is the RealToon shader property for the main texture.


     
  16. JanKrocak

    JanKrocak

    Joined:
    Jul 11, 2021
    Posts:
    13
    Hello. Does shader already support decals please?
     
  17. bc25252

    bc25252

    Joined:
    May 28, 2017
    Posts:
    13
    Any update with multiple overlay textures support?
     
  18. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi bc25252, currently none yet.

     
  19. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi, JanKrocak
    What version?
    Built-In? URP? or HDRP?

     
  20. JanKrocak

    JanKrocak

    Joined:
    Jul 11, 2021
    Posts:
    13
    In HDRP.
     
  21. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    About Decals on RealToon HDRP,
    Currently not supported yet.

     
  22. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
  23. akent99

    akent99

    Joined:
    Jan 14, 2018
    Posts:
    588
    I am using Realtoon **(5.0.8p2 [Patch#2] - August 2021)** with 2022.1.0b12. All up it is working well, I am using it with VRoid Studio created characters, running the script I found to replace the material shaders with RealToon.

    The problem I am having is when using the outline around the mouth. It does not do a very consistent job to get a line all the way around the mouth, or it is thin and pixelated at times.
    upload_2022-4-7_0-19-14.png

    (More examples: https://extra-ordinary-episodes--staging-gfyzb7g1.web.app/)

    The wrinkles around the mouth can be funny at times.

    upload_2022-4-7_0-20-34.png

    I tried setting the outline width to zero for the mouth, which gets rid of the black line around the mouth, but the lips apparently are not touching so you can see the white teeth through the mouth (not a RealToon problem, but a problem solved with the outline width set to 0.05 to 0.1).

    upload_2022-4-7_0-23-15.png

    Here is an example with the mouth outline turned off (width set to zero). The teeth can be seen, and its not very nice.
    upload_2022-4-7_0-25-8.png

    QUESTION: Any suggested way to get the outline around the mouth, but have it more consistently drawn? A thin consistent line would be good. The current result is okay, but a few people said "boy that smile is more creepy".

    Thanks!
     
  24. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi, akent99 thank you for using RealToon.
    I noticed that you are using the beta, which the Inspector GUI has an issue or problem.
    It is still best to use the LTS or Tech Stream version.

    About the Outline, i recommend you to use the Width Control option, this will let you adjust the outline by texture,
    This will also allow to make a certain part of the object to don't have outline.
    Black color means 0 value while White is 1.
    Be sure the main Outline Width option is not equal to 0.

    Use the face texture of your character as a reference.


     
  25. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    Hi, I seem to be getting an error after importing the toon package for HDRP:

    upload_2022-4-7_17-23-10.png

    upload_2022-4-7_17-24-1.png
     
  26. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi newguy123,
    Yes on Unity 2022.2.0a HDRP, i already fixed this and it will be included on the next patch #5.
    I recommend to use the LTS or Tech Stream version of unity.

     
  27. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    Thanks for the quick patch #5. When do you estimate it will be available/released?
     
  28. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    No problem :)
    Any day this month april.
    I'll post some announcement on my YouTube, Facebook page and Twitter.

     
  29. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    Is it possible you could share just that shader here please so I have a fix in the meantime, or the issue is much wider than just that shader?
     
  30. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Just send an email and I'll give you the quick fix for it.
    You can see it on the RealToon (User Guide).pdf

     
    newguy123 likes this.
  31. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    Thanks. Mail sent
     
  32. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    No problem, i replied to your email.

     
    newguy123 likes this.
  33. akent99

    akent99

    Joined:
    Jan 14, 2018
    Posts:
    588
    Thanks, but I am using Unity Sequences and Animation Rigging packages, and they only fixed it in the beta. So I will have to put up with RealToon GUI issues for now.

    Yes, I set the outline width to 0.1 for the face, check "output width affected by view distances", and set the "Far distance for view width" to 0.2. But I cannot find values that work well at all camera distances. The mouth screenshot I provided for example has outline around outside edge of mouth, but not middle.

    Here is an example where I turned outline off for the mouth, but left it on for the face skin. You can see the teeth in the mouth above and below the black line across the mouth (drawn for top lip). I assume a maths issue because I am very close to the face. But I want to do both distant shots and close ups - trying to find settings that work well across all distances. I was hoping "oh, just set this other value and outlines work better"! I can always hope! ;-)
    upload_2022-4-7_18-20-59.png
     
  34. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Did you try to use the "Width Control"?
    Can you send to me the "Width Control" texture you made by message.

    You can also do gradient or use gradient texture. (From Black to Gray to White)

     
  35. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    Struggling to get this right. I dont want any shadow on the object. If I rotate the view slightly, some things seem to appear thicker. If I only slightly angle the viewport, things appear/disappear or appears thinner/thicker

    Here's an example of 1 angle: (see wall on right)
    upload_2022-4-8_12-28-14.png

    Then I rotate the view a little, and the front wall suddenly becomes darker: (see same wall on right)
    upload_2022-4-8_12-28-52.png

    Also I dont seem to be able to get the outline to work. I want a colored outline, but that adjusting the outline color just seems to adjustt he overrall color.

    Here's an example that was done with a traditional DCC and offline rendering. I'm trying to match this kind of look, or there abouts...(almost like a wireframe type thing, but not exactly)
    upload_2022-4-8_12-33-49.png
     
  36. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi, i noticed that your object is cube type.

    This can be achieved using a Screen Space.
    Something similar to DeNorSob Outline included on the RealToon HDRP
    You can try to use the On Shader Screen Space Outline.

    About the shadow, just disable the Self Shadow feature.

     
  37. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    On a simple cube I get that. How can I also get the lines in the red area?

    EDIT: Forgot to add screenshot:
    upload_2022-4-8_13-4-42.png
     
  38. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    Or actually, even better, if I can get this kind of look:
    upload_2022-4-8_13-6-0.png
     
  39. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
  40. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    You can do that using the On Shader Screen Space Outline/DeNorSob Outline Post Processing, take note when using it, if the object is transparent, the outline will be visible,
    This is the current issue.

     
  41. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    You can achived that using RimLight feature plus the Outline/On Shader Screen Space Outline/DeNorSob Outline Post Processing (Sobel Enables and Mix)

     
  42. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    adjusting any of these settings in any direction does not appear to affect the cube at all:
    upload_2022-4-8_13-24-13.png

    Any suggestions for these settings?
    upload_2022-4-8_13-26-3.png
     
  43. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi, Here's my result.

    (Using "On Shader Screen Space Outline")
    11.png

    (Using "DeNorSob Outline Post-Processing")

    22.png

    (All are default values except the "Outline Width")

     
    newguy123 likes this.
  44. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    The De Nor Sob Outline works great, however...
    If I enable transparent, the internal outline goes away and only the outer remain

    Transparent off:
    upload_2022-4-8_22-25-52.png


    Transparent On:
    upload_2022-4-8_22-26-45.png

    Is it possible to keep the outlines everywhere, with transparent on?
     

    Attached Files:

  45. SpawnOfLinkTIS

    SpawnOfLinkTIS

    Joined:
    Jul 3, 2013
    Posts:
    9
    I have an issue where the inspector previews are far to dark. They have almost no illumination when properly lit in the scene.
    Here is an imgur link for a lot more detail:
    https://imgur.com/gallery/xYFw9ac

    The first set of pictures are the baseline. HDRP Lit shader. It clearly shows the model in the scene and preview windows. When I try to get RealToon's shader to be similarly lit in the scene (second batch of images), the preview windows are nearly invisible. This is a problem since I like to see what I'm dragging into the scene instead of memorizing wall_01_a is a short wall, and wall_02 is different, etc.

    In the third set, I raise the Main Color Power and Highlight Color Power to make the preview windows look much more like the baseline test (HDRP Lit). However this drastically over powers the coloring in the scene view.

    The sample scene includes a basic cube with a material using the RealToon shader, a wall object with the same material, and a plain cube using the DefaultHDMaterial.

    This is in Unity 2020.3.30f1 using RealToon 5.0.8 and HDRP 10.8.1

    What am I doing wrong here?
     
  46. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Sorry for the late reply,
    When the object is transparent it will not render the Screen Space Outline/DeNorSob Outline (Normals), this is the current issue on HDRP.

     
  47. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi SpawnOfLinkTIS,
    Thank you for using realtoon. :)

    About the material previews (Project Panel/Window and Inspector), it is still not yet fixed this is due to Unity HDRP made the previews, it is complex and currently messy
    but i already planned to fix it soon, for now use the scene or game view o use a unity sphere to preview the material.

     
  48. StriderRouga

    StriderRouga

    Joined:
    May 11, 2021
    Posts:
    18
    Hi there! i am using real toon on all of the assets in my level with everything lit by a real time directional light. in the editor everything is lit but when i build for android and try it on my phone everything is dark like its all in shadow. i put a sphere in the scene with a regular unity lit shader on it and that object shows up lit in the build. is there a setting in the real toon material that could be causing this issue?
     
  49. MJQStudioWorks

    MJQStudioWorks

    Joined:
    Oct 12, 2012
    Posts:
    655
    Hi StriderRouga,
    Thank you for using RealToon :)
    May i know what Rendering Pipeline is your project?
    Built-In? URP? or HDRP?

     
  50. StriderRouga

    StriderRouga

    Joined:
    May 11, 2021
    Posts:
    18
    Absolutely, im using URP