Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Join us on Thursday, June 8, for a Q&A with Unity's Content Pipeline group here on the forum, and on the Unity Discord, and discuss topics around Content Build, Import Workflows, Asset Database, and Addressables!
    Dismiss Notice

VertExmotion [Released]

Discussion in 'Assets and Asset Store' started by kalagaan, Oct 30, 2014.

  1. dzft3w

    dzft3w

    Joined:
    Apr 4, 2020
    Posts:
    13
    Hello!
    Is there a setting for inertia to stop objects from deforming when in uniform motion like in elevator?
     
    Last edited: Jul 28, 2022
  2. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    You could try to add the inverse motion vector to the sensors. There's a custom world force in the sensors' parameters.
    There's different samples using custom forces by script in the package.
     
  3. CoolCat518

    CoolCat518

    Joined:
    Feb 4, 2015
    Posts:
    18
    Hi, I used vert exmotion on the skin mesh, the effect is good when the scale value is 1, but when I set the scale of the character larger at runtime, vert exmotion has no effect, how can I solve this problem? Thank you!
     
  4. CoolCat518

    CoolCat518

    Joined:
    Feb 4, 2015
    Posts:
    18
    Unity version: 2022.1.8 vertExmotion vertion:1.10.2

    In your demo scene to adjust the scale value of those characters, the effect is good, but using my own characters, scale larger will have no effect
     
  5. sii-018

    sii-018

    Joined:
    Aug 22, 2022
    Posts:
    2
    Hello.

    I tried applying it to poiyomi as per page 22 of the document, but I can't paint on the vertices.
    gradient doesn't seem to work either.

    Is there any solution?
     
  6. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    What is your version of unity?
    Do you use the latest version of Vertexmotion ?
     
  7. sii-018

    sii-018

    Joined:
    Aug 22, 2022
    Posts:
    2
    I am using unity 2020.3.30f1
    The version of vertexmotion uses the latest 1.10.2
     
  8. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    Does the model has the Read/Write parameter enabled in the import settings?
    If it doesn't work, could you send me your model and your invoice number (contact@kalagaan.com)
    I'll help you to fix it.

    Note : With Unity 2021 you can use the Vertex Buffer mode, so you don't have to convert the shader.
    You'll have to download the package again using the package manager in Unity 2021.
     
    sii-018 likes this.
  9. xueqing0622

    xueqing0622

    Joined:
    Apr 8, 2020
    Posts:
    12
    Hi, kalagaan

    Could you upload a scene example for this script! Thanks a lot!
     
  10. adamz

    adamz

    Joined:
    Jul 18, 2007
    Posts:
    1,187
    @kalagaan Hi, I'm running Unity 2022.1.17f1, HDRP, with your latest update. Is there a way to show the entire mesh when painting with the vertex buffer mode? It seems to disappear when orbiting around in the scene view. GPU Compute Skinning is enabled.Thanks.
     

    Attached Files:

  11. EvalDaemon

    EvalDaemon

    Joined:
    Aug 8, 2013
    Posts:
    107
    I found that the hdrp vert lit shader was giving an error and doing the same thing because it calls vertmesh that was looking for vertexmotion.cginc down one folder when it was actually down two. So I changed the shader to look for it like this.

    #include "../../VertExmotion.cginc"
     
  12. Desertleaf

    Desertleaf

    Joined:
    Dec 15, 2013
    Posts:
    11
    Unity 2021.3.11f [ VertExmotion implementation in Amplify Shader Editor].

    When i add the additional directive for Vertexmotion.cgnic, i get a redefinition error for _Time.

    I don’t know HLSL so i don’t know what to do.
    //EDIT - upgraded to 2021.3.13F - problem still exists.

    ///EDIT

    Shader error in 'VerExmotion/Basic_AmplifiedVersion_Converted': redefinition of '_Time' at 2019_4/2021.3.13f1/Editor/Data/CGIncludes/UnityShaderVariables.cginc(40) (on d3d11)

    I notified Amplify shader team but they are busy with other things.
     
  13. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    Oops, I was really busy these months and I didn't see this notification :(
    I'll have a look, thank you for the feedback
     
  14. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    Thank you, for the feedback! ;)
     
  15. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    I'll check that! ;)
     
  16. Setmaster

    Setmaster

    Joined:
    Sep 2, 2013
    Posts:
    221
    Getting this error with the Unlit URP shader:

    invalid subscript 'normalOS'
    Compiling Subshader: 0, Pass: DepthNormalsOnly, Vertex program with <no keywords>
    Platform defines: SHADER_API_DESKTOP UNITY_ENABLE_DETAIL_NORMALMAP UNITY_ENABLE_REFLECTION_BUFFERS UNITY_LIGHTMAP_FULL_HDR UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BLENDING UNITY_SPECCUBE_BOX_PROJECTION UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS
    Disabled keywords: DOTS_INSTANCING_ON INSTANCING_ON SHADER_API_GLES30 UNITY_ASTC_NORMALMAP_ENCODING UNITY_COLORSPACE_GAMMA UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_DXT5nm UNITY_NO_FULL_STANDARD_SHADER UNITY_NO_SCREENSPACE_SHADOWS UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_UNIFIED_SHADER_PRECISION_MODEL UNITY_VIRTUAL_TEXTURING


    invalid subscript 'normalOS'
    Compiling Subshader: 0, Pass: Unlit, Vertex program with <no keywords>
    Platform defines: SHADER_API_DESKTOP UNITY_ENABLE_DETAIL_NORMALMAP UNITY_ENABLE_REFLECTION_BUFFERS UNITY_LIGHTMAP_FULL_HDR UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BLENDING UNITY_SPECCUBE_BOX_PROJECTION UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS
    Disabled keywords: DEBUG_DISPLAY DOTS_INSTANCING_ON FOG_EXP FOG_EXP2 FOG_LINEAR INSTANCING_ON SHADER_API_GLES30 UNITY_ASTC_NORMALMAP_ENCODING UNITY_COLORSPACE_GAMMA UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_DXT5nm UNITY_NO_FULL_STANDARD_SHADER UNITY_NO_SCREENSPACE_SHADOWS UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_UNIFIED_SHADER_PRECISION_MODEL UNITY_VIRTUAL_TEXTURING
     
    Last edited: Jan 27, 2023
  17. Graham-B

    Graham-B

    Joined:
    Feb 27, 2013
    Posts:
    319
    I'm trying to use VertExmotion along with HBAO, but the HBAO post process is producing a strange outline which shows the mesh both before and after deformations from VertExmotion. Any idea how I can work around this?

    Was wondering if it could be something simple like an ordering issue, but tried setting HBAO higher in the script execution order and no luck.

    There seems to be an incompatibility between the two assets. I contacted the HBAO developer and he replied with a tidbit of information that may be useful to you.

    "Like most SSAO solutions, HBAO require 2 inputs: depth and normals textures that Unity provides to shaders"

    Any idea how I can work around this?
     
  18. Graham-B

    Graham-B

    Joined:
    Feb 27, 2013
    Posts:
    319
    I tried out Amplify Occlusion since I saw another post saying it is compatible, however it has the exact same issue as HBAO, the strange ghosting between the mesh before and after VertExmotion deformation.



    The only way around this that I can find is to set the "Per Pixel Normals" to "None," but unfortunately this leaves the mesh looking pretty bad without normals in the AO calculation.

    Any ideas?
     
  19. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    On the latest version of Unity you can use the vertex buffer mode instead of the shader mode,
    it will work with any shader.
     
  20. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    Hello,
    Did you try the Vertex Buffer mode ?
     
  21. Graham-B

    Graham-B

    Joined:
    Feb 27, 2013
    Posts:
    319
    Where do I find Vertex Buffer mode?

    Edit: Found it, and it works perfectly!


    Thanks! This will make my life a lot easier since I no longer need to manual update my custom shaders.
     
    Last edited: Jan 29, 2023
    kalagaan likes this.
  22. Rabadash8820

    Rabadash8820

    Joined:
    Aug 20, 2015
    Posts:
    76
    Hi @kalagaan, this looks like an incredible asset, and I'm super impressed that you've maintained it since 2014! I'm currently evaluating it for use in a game about cells, where I was going to represent the cell membranes as softbodies to give them some fluidity and deformability. One other critical requirement is to be able to merge other small softbodies (vesicles) with this membrane, or pinch them off. Your push and pull interactions look promising, but does your asset provide a way to actually "merge" two softbody meshes into one, or split one apart?
     
  23. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    VertExmotion doesn't modify the original geometry, it's a way to deform existing meshes.
    The sensors are spheres (or cylinder) where you can modify the vertices with some settings (offset, inflate, jiggle...)
    You can share them between different objets, so if the vertex density is the same, both surfaces could be modified in the same way in worldspace.
    Not sure that it will feet exactly what your need, but it could help to have nice interactions.
     
  24. Rabadash8820

    Rabadash8820

    Joined:
    Aug 20, 2015
    Posts:
    76
    Cool, thank you for clarifying. Looks like I'll need to find a good asset for combining meshes or write something crude myself. VertExmotion should be great for the fluidity part though. Thanks again!
     
  25. unity_9GrkBK6e9MmiSg

    unity_9GrkBK6e9MmiSg

    Joined:
    Nov 3, 2019
    Posts:
    3
    Hi @kalagaan, this asset is really nice. Is there any tutorial for collisions?
    For example at this demo(http://www.kalagaan.com/VertExmotion/Demos/Collisions/) and in general for simple collisions can be done only with sensors or there's a script needed? If there's a script needed do you have a tutorial or example?
     
  26. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    A default collision system is included in the sensor's settings, there's some informations in the documentation.
    https://www.kalagaan.com/VertExmotion/Doc/VertExmotion_doc.pdf

    There's some examples in the package for using the collision system and some scripts for advanced collisions based on procedural sensor spawn and control, it really depends of the effect you need.
     
  27. unity_9GrkBK6e9MmiSg

    unity_9GrkBK6e9MmiSg

    Joined:
    Nov 3, 2019
    Posts:
    3
    Thank you very much!
     
  28. Hummy91

    Hummy91

    Joined:
    Jun 7, 2017
    Posts:
    53
    Does this asset work with HDRP and also with Skinned Meshes that use/manipulate Blendshapes at runtime?
     
  29. kalagaan

    kalagaan

    Joined:
    May 27, 2012
    Posts:
    1,479
    Yes it works with all render pipelines and blendshapes.
     
    Hummy91 likes this.
  30. Hummy91

    Hummy91

    Joined:
    Jun 7, 2017
    Posts:
    53
    Thought I would just share this small bit of info here as I was struggling with syncing up my character mesh soft body with attached clothing and couldn't find any solid answers in this thread. What ended up working best for me was to programmatically copy the sensors and sensor links from the VertExmotion component on my character to the one on my clothing item. The important part was copying the sensor LINKS as well as the sensor itself.

    This + ensuring that the vertex painting on your base mesh and on your attachment/clothing is similar (in my case I just fully painted (red) the animated areas on my base mesh and clothing) and you can get it basically 100% accurate. I have a extremely thin, tightly wrapped bandage on my characters leg which is now simulating perfectly.
     
    kalagaan likes this.