Announcement

Collapse
No announcement yet.

❀ DoN's Dynamic Mesh Effects ❀

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • replied
    Hey guys!
    I have some questions regarding this addon


    1) Is It possible to create a BP_projectile with multiple brush/decals ?
    For example:slash decal , bullet decal , blood and many more....

    2) Is It possible to control the opacity, size of the decal on the character once It's applied?
    For example:regeneration , getting clean.

    3) Do characters require to use Blueprint?

    Leave a comment:


  • replied
    Deep in memory stomping right now but I will give it a try later on.

    Leave a comment:


  • replied
    Originally posted by FrostyElkArne View Post
    I have activated your printouts to Log level and this is what I get on a cooked dedicated server:
    Just a sample, all materials gives this printout.
    If you are comfortable with modifying a bit of code, can you try the following:

    1. Open DonMeshPainterComponent.cpp
    2. Go to the function ResolvePaintLayer
    3. Go the if condition that reads
    Code:
    if (layerNameByUvMethod.IsEqual(DonMeshPaint::DonPaintLayer_MeshGeneric))
    4. Inside that if, replace the entire contents with the following:
    Code:
     layerParameterName = FName("DonPaintLayer_MeshGeneric_UV1_0");
    bRenderTargetParameterFound = true; // don't forget this line!
    5. Recompile the code and try now.

    This assumes that you are using the Don Mesh Paint UV1 node on Layer 0. If that is not the case, you should change the contents of the FName to match that.

    Let me know if this works and we can investigate further accordingly.

    Leave a comment:


  • replied
    I have activated your printouts to Log level and this is what I get on a cooked dedicated server:
    Code:
    [2018.08.11-13.13.09:372][837]LogDonMeshPainting: 
    [Alert] Archer_MM2_Mat - Layer 0 missing
    This material is not configured for painting on layer 0.
    You need to add the correct Don paint layer material function inside your material
    
    [2018.08.11-13.13.09:374][837]LogDonMeshPainting: 
    [Alert] claymore_Mat - Layer 0 missing
    This material is not configured for painting on layer 0.
    You need to add the correct Don paint layer material function inside your material
    
    [2018.08.11-13.13.09:504][845]LogDonMeshPainting: 
    [Alert] DOC_Mat_M - Layer 0 missing
    This material is not configured for painting on layer 0.
    You need to add the correct Don paint layer material function inside your material
    Just a sample, all materials gives this printout.

    Leave a comment:


  • replied



    Originally posted by FrostyElkArne View Post
    We have hit a problem that we can't find any solution to. When we package a dedicated server the Materials no longer passes DoNs test for a valid material. Painting on the server only gives warnings about missing support for DoN. The packaging for dedicated server has stripped out all DoN functionality.

    Running an editor-dedicated server works fine so this comes as a surprice now that we start packaging the game.

    Is there a setting somewhere that we have missed?
    Hey, can you share the server logs with the warnings about missing support?

    That will be helpful for deducing what is going on.

    ~

    Originally posted by cpenny20 View Post
    It is not a cloth asset, just a skeletal mesh. It's a pair of shorts in this case. I think trace responses to child components does not work in unreal yet, so as a workaround, i broke the hit result and re-made it but I forced the clothing component into hit result and it worked like a charm.

    And to your latest question to the rennsix about using the plug in on skeletal meshes in vr, I tried it for the bullet holes. It looks great, but unfortunately the performance hit was too great. Every time it painted a bullet hole it would hitch the performance for a split second. It was very quick but for rapid fire it definitely makes it unplayable. If we could overcome that little performance hit, there are great things that can be done.

    Also, with regards to a question I asked a while ago, I am still curious about something: I tried painting using a decal as my brush and it seems to work correctly most of the time, but the size changes sometimes. I tried it on several different skeletal meshes with clean, well proportioned UV maps, and it still would paint the decal at seemingly random sizes. Wonder if there's any way around this?
    Glad to hear the skeletal mesh/cloth is working now!

    VR performance - are you using decals? That's the most expensive flow. If you're not using decals, then lowering the values of DefaultPositionsTextureSizeX/SizeY in DonMeshPainterGlobalActor.h may help. For rapid-fire maybe you could throttle the impact holes so not every bullet is painted is every tick? Aggregating holes with some custom logic is also an option although that kind of stuff always needs a lot of tweaking to get visually acceptable results. Apart from those - if the pose of the skeletal mesh is known / mostly unvarying (eg: being struck by a bullet always puts the target into a particular animation pose) then it may be possible to cache that animation pose beforehand which would virtually eliminate any performance cost (this would be some custom coding as such a feature is not part of the plugin yet). Final option I can think of is to add support in the plugin for bone-space transformation based skeletal painting (which someone asked about earlier in this thread); less accurate but far more performant.

    For the decal brush size - Do you have pics of the varying decal brush sizes and maybe the corresponding UV map?

    ~

    Originally posted by rennsix View Post
    Yes, it is the Don Mesh Paint UV1. Here is an image of the setup. Will be doing some 'chalk' work next month.
    Thank you for sharing that! Can't wait for the chalk work

    Leave a comment:


  • replied
    We have hit a problem that we can't find any solution to. When we package a dedicated server the Materials no longer passes DoNs test for a valid material. Painting on the server only gives warnings about missing support for DoN. The packaging for dedicated server has stripped out all DoN functionality.

    Running an editor-dedicated server works fine so this comes as a surprice now that we start packaging the game.

    Is there a setting somewhere that we have missed?

    Leave a comment:


  • replied
    Originally posted by VSZ View Post
    Which Don Material node is that using?
    Yes, it is the Don Mesh Paint UV1. Here is an image of the setup. Will be doing some 'chalk' work next month.

    Click image for larger version

Name:	hazpaint.jpg
Views:	26
Size:	541.0 KB
ID:	1514914

    Leave a comment:


  • replied
    Originally posted by VSZ View Post

    Does the cloth have a physics asset to go with it? The hitresult's location needs to roughly approximate the cloth's pixels for this to work. Obviously a primitive collision shape can never approximate the rich contortions of cloth, but you need some kind of collision to occur for the paint to be projected. Cloth support was recently added in 4.19 and should work as long as your cloth mesh has a collision body.
    It is not a cloth asset, just a skeletal mesh. It's a pair of shorts in this case. I think trace responses to child components does not work in unreal yet, so as a workaround, i broke the hit result and re-made it but I forced the clothing component into hit result and it worked like a charm.

    And to your latest question to the rennsix about using the plug in on skeletal meshes in vr, I tried it for the bullet holes. It looks great, but unfortunately the performance hit was too great. Every time it painted a bullet hole it would hitch the performance for a split second. It was very quick but for rapid fire it definitely makes it unplayable. If we could overcome that little performance hit, there are great things that can be done.

    Also, with regards to a question I asked a while ago, I am still curious about something: I tried painting using a decal as my brush and it seems to work correctly most of the time, but the size changes sometimes. I tried it on several different skeletal meshes with clean, well proportioned UV maps, and it still would paint the decal at seemingly random sizes. Wonder if there's any way around this?

    Leave a comment:


  • replied
    Originally posted by rennsix View Post
    Just an update that using the plugin in VR environments works just fine.
    Thank you, that looks really neat!

    Which Don Material node is that using? Would be interesting to see a skeletal mesh usecase ("Don Mesh Paint UV1" node) as that's relatively more performance intensive (especially when decal textures are involved).

    But anyway, thank you so much for getting back on this!

    Leave a comment:


  • replied
    Just an update that using the plugin in VR environments works just fine.

    Leave a comment:


  • replied
    4.20 Project Available (Raycast Example Added!)

    Download it here!

    ~

    One Mode Only - Saw your post on the marketplace page, thought this would help!

    Leave a comment:


  • replied
    Originally posted by cpenny20 View Post
    1.) I'm not sure I understand: "the resolution of the positions texture" in your last reply, I'm curious what you mean by that?
    Originally posted by cpenny20 View Post
    2.) Also, i still see some seams between the UV islands as i paint on the mesh. Is there any way to avoid that? Thanks!
    For both questions - The quality of your seamless painting can be improved by increasing the resolution of the "positions texture" - this is a special look up texture which the plugin generates by baking the local space positions of your character's pixels.

    Currently the resolution of this look up texture is hardcoded to 512x512 inside DonMeshPainterGlobalActor.h (search for DefaultPositionsTextureSizeX and DefaultPositionsTextureSizeY).
    Try increasing this to 1024x1024 and recompile the code although keep in mind that this will have some impact on performance - but mainly for decal projection seamless painting should be mostly unaffected as that's done completely on the GPU.

    Before you do this, first try increasing the size of your UV islands for important areas. For seamless painting your UVs do not need to be uniformly sized (unlike for decals) so if some UV islands are really small then the corresponding resolution those pixels acquire in the baked position texture will also be lower and hence the accuracy.

    Originally posted by cpenny20 View Post
    3.) I am trying to paint on a skeletal mesh that is a child component (a piece of clothing, attached to the main character using the "Set Master Pose Component" node) but it's not working. It works on the main body mesh, but not on his additional pieces. Any idea why?
    Does the cloth have a physics asset to go with it? The hitresult's location needs to roughly approximate the cloth's pixels for this to work. Obviously a primitive collision shape can never approximate the rich contortions of cloth, but you need some kind of collision to occur for the paint to be projected. Cloth support was recently added in 4.19 and should work as long as your cloth mesh has a collision body.

    Originally posted by cpenny20 View Post
    4.) As I paint strokes on a character mesh, for a single frame, I see the morph targets resetting. Is there any way to avoid this?
    This is an engine bug that was reported to Epic a while ago. You can track the progress of that bug here: UE-54099. Do add vote your vote on that JIRA to show your interest!

    Leave a comment:


  • replied
    4 follow up questions when you have the time!

    1.) I'm not sure I understand: "the resolution of the positions texture" in your last reply, I'm curious what you mean by that?

    2.) Also, i still see some seams between the UV islands as i paint on the mesh. Is there any way to avoid that? Thanks!

    3.) I am trying to paint on a skeletal mesh that is a child component (a piece of clothing, attached to the main character using the "Set Master Pose Component" node) but it's not working. It works on the main body mesh, but not on his additional pieces. Any idea why?

    4.) As I paint strokes on a character mesh, for a single frame, I see the morph targets resetting. Is there any way to avoid this?
    Last edited by cpenny20; 08-01-2018, 08:25 PM.

    Leave a comment:


  • replied
    Originally posted by cpenny20 View Post
    i remade the physics asset to be much tighter and it does seem to be helping a lot. It's working well enough that I don't feel the need to make it any better for now i think!
    Glad to hear! Yes accuracy of the physics asset plays a big role as the hit location needs to be as close to the material's pixels as possible.

    Resolution of the positions texture is another factor By default its hardcoded to 512x512 for optimum performance. Increasing that should help further, but I'd only recommend that for a dedicated scenario like a painting app or a character customization screen where you're dealing with only one or few subjects.

    Leave a comment:


  • replied
    Originally posted by VSZ View Post

    I recommend using the seamless workflow for such a tiny hole (i.e. don't use decals, leave the Decal parameter empty) as that will guarantee consistency of hole size regardless of UV setup .
    Thanks for the reply, I just tried this, and the hole sizes are still a little bit different in some places. There are also places all over the model where the effect doesn't happen at all. I wonder though, is this problem possibly related to the physics asset? Also, I tried using a value of less than 1 for the brush size, like .85, and didn't see any holes at all. Is it possible to do this?

    edit: i went back and looked through the thread and it does seem that maybe i need a more accurate physics asset for a small brush such as this. not sure if it explains the differing brush sizes though.

    edit 2: i remade the physics asset to be much tighter and it does seem to be helping a lot. It's working well enough that I don't feel the need to make it any better for now i think!
    Last edited by cpenny20; 07-29-2018, 04:27 PM.

    Leave a comment:

Working...
X