Announcement

Collapse
No announcement yet.

[TUTORIALS] Photons Be Free: Mini-tutorials and other curiosities

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

  • replied
    Hi, Tim Hobson

    Okay. Is possible to clearly understand their tutorials in Max. No problem


    Luny

    Leave a comment:


  • replied
    Unfortunately, I only have direct access to Max and I'm not all that familiar with Maya to be honest.

    I have, I think, three tutorials that use Max as a basis. Two of those are using plugin's that should be very similar to use in Maya.

    The APEX Cloth one should be very similar since that is just using the DCC Plugin for PhysXLab.

    The DM Animated rigid mesh is the same process in Maya. Bake the animation to a timeline and make sure to group all the chunks together. Once that is ready, export with the animation and import into UE4.

    The Collision Mesh setup, this may be different depending on a modifiers availability or not since I use a specific one to get better results. I'm just not familiar enough with Maya to say if this is the case there or not. :/

    If I missed something or you have a specific one that needs better flow let me know and I can take a look. One of the guys on our team has Maya so I can always double check things there and better explain if needed.

    Leave a comment:


  • replied
    Could have a version of these tutorials in maya also

    But do not worry, I wrote this more as a bookmark to be able to visit this thread later.


    Luny

    Leave a comment:


  • replied
    Favorite thread ever. Thx

    Leave a comment:


  • replied
    Originally posted by Tim Hobson View Post
    Hey Jps7101,

    At the moment there are no plans for Epic to integrate the full PhysX SDK into UE4 beyond what's already available for destruction. HOWEVER, one of our community developers, Backov (Jason M.) has integrated it into his own build of the engine and he does hope that when he's done with it to submit it as a pull-request so that it can be integrated.

    You can find more information and a demonstration of his work here: https://forums.unrealengine.com/show...Editor-for-UE4

    His version eliminates the need for PhysX Labs or the PhysX DCC Plugin to create destructible assets. I've got an early build of it that he demonstrates. I've talked with him and have a build of the editor to help him test it out and offer some feedback.

    Feel free to ask questions anytime. If there is a setup with Destructibles that you'd like to see just post here and I'll do what I can to get a simple example up, similar to the other ones I've got.
    Hello Tim,

    I will studied the documentation attentively. Thank you very much!

    Greetings.

    Leave a comment:


  • replied
    Destructible How-To #8: Damage Spread

    Overview:

    The goal with this "How-To" will be to take a look at how Damage Spread works with applying damage to our destructible mesh.

    Step 1: What is Damage Spread?

    Damage Spread is essentially how easy damage spreads to the other chunks in the destructible.

    If we have a wall destructible, think about the impact point being the center of a radius of damage. The damage spread will be how much damage is passed to the surrounding chunks to break them free as well.

    If we have a damage spread of 0 only the chunks that are impacted directly and receive enough damage to break free will do so.

    If the damage spread is set to 0.1 (default), if the impact force is strong enough the damage passed to surrounding chunks can be enough to break all or some of the chunks free.

    This is the formula for calculating the Damage Radius:

    Damage Radius = Damage * Damage Spread

    All chunks within the damage radius will take full damage at the point of impact. At the edge of the damage radius 0 damage will be applied.

    Demonstration

    https://www.dropbox.com/s/tjxyupepx1...sprd1.gif?dl=0


    Tips:

    If you're having trouble with setting up Damage Spread, try adjusting lower values for Impact Damage, setting a Damage Cap for damage application, and/or Increase the Damage Threshold.

    A single settings will likely not produce the results you're looking for. It will require multiple tweaks to get just right.

    Leave a comment:


  • replied
    Hey Jps7101,

    At the moment there are no plans for Epic to integrate the full PhysX SDK into UE4 beyond what's already available for destruction. HOWEVER, one of our community developers, Backov (Jason M.) has integrated it into his own build of the engine and he does hope that when he's done with it to submit it as a pull-request so that it can be integrated.

    You can find more information and a demonstration of his work here: https://forums.unrealengine.com/show...Editor-for-UE4

    His version eliminates the need for PhysX Labs or the PhysX DCC Plugin to create destructible assets. I've got an early build of it that he demonstrates. I've talked with him and have a build of the editor to help him test it out and offer some feedback.

    Feel free to ask questions anytime. If there is a setup with Destructibles that you'd like to see just post here and I'll do what I can to get a simple example up, similar to the other ones I've got.

    Leave a comment:


  • replied
    Originally posted by Tim Hobson View Post
    Destructible How-To #7: The power of World Support

    .... [Removed extraneous information]

    Amazing documentation Tim, I wanted to find information to how to implement physics calculate in UE4. Further, I also work with 3ds Max for create geometries and I was very interested to how to work with APEX PhyX plug-ing in Max. One question, It will be possible that APEX PhyX can be integrated into UE4 in the future?.

    Thanks for the documentation and greetings.
    Last edited by Tim Hobson; 04-30-2015, 08:19 AM. Reason: Removed most of quote block

    Leave a comment:


  • replied
    Destructible How-To #7: The power of World Support

    Overview:

    In this short example we'll go over the use of the "World Support" flag in the Destructible Mesh Settings.

    World Support is simply a way to enable the Destructible to be environmentally supported by any static geometry inside the level that it's in contact with so long as it has at least a Support Depth of 1.


    Setting up World Support

    The setup is fairly straight forward. There are two things that initially need to be setup to make this work. Support Depth needs to be set to the depth layer that it will be supported. If you're using the in-editor tool this will simply be 1, since there cannot be more than one depth layer created in this tool.

    The next setting is to enable "World Support" flag.

    Click image for larger version

Name:	WorldSupportDMSettings.png
Views:	1
Size:	45.9 KB
ID:	1075373

    Demonstration



    What's going on:

    By enabling World Support and using at least a Support Depth of 1 we have enabled our destructible to be supported by static geometry that it's in contact with.

    The Support Depth allows chunks to stick together without breaking apart unless they've received enough damage to do so. By enabling World Support this will keep the chunks that are in contact with static geometry that have not received enough damage to break free supported and in place.

    The outer edges in this DM are supported by the static walls because they've not received enough damage to break free yet.

    Click image for larger version

Name:	DM_Scene_worldSupported.png
Views:	1
Size:	556.4 KB
ID:	1075374

    In the video demonstration, we see the first wall does not have World Support enabled. This allows the wall to be pushed back when enough force hits it. It will bounce around since it's not supported by the environment, whereas the second wall is supported by the floor that it's in contact with causing the bottom of the mesh to be environmentally supported by the static geometry.

    Leave a comment:


  • replied
    many thanks for you

    Leave a comment:


  • replied
    Originally posted by ikifenix View Post
    The video doesn't load in the forum, I had to quote to find the link and watch it in youtube.
    Thanks for letting me know ikifenix. Fixed the link. https://forums.unrealengine.com/show...l=1#post207604

    Once 4.8 releases I plan on updating this since the car is noticeably stopped when it hits the DM and then it falls over.

    With 4.8 I'll be able to use Custom Impact Resistance to help make this better so that anything below that impact value will not cause any damage, but when I have a impact large enough it will knock it over without the stopped of the vehicle.

    Leave a comment:


  • replied
    Originally posted by Luftbauch View Post
    What is with the performance inside UE, if you make massive use of auto-convex?
    In what regards? Using too many collision hulls for more accuracy?

    Are you experiencing any issues with auto-convex collision causing performance issues? It seems to imply this in your question.

    Let me know what your use with it is and I can do some of my own tests and see if I take a look.

    Leave a comment:


  • replied
    Originally posted by Tim Hobson View Post
    Destructible How to #1: Effectively using "Import FBX Chunks" for Destructible Meshes

    In this setup I'll be using a parking meter as an example.
    etc,etc...
    The video doesn't load in the forum, I had to quote to find the link and watch it in youtube.

    Leave a comment:


  • replied
    Originally posted by Tim Hobson View Post
    ......
    Auto Convex is getting a good update in 4.8 that will make it much more accurate when generating collision via this method. ...
    Ty very much, for this Thread.
    What is with the performance inside UE, if you make massive use of auto-convex?
    Best regards Stefan

    Leave a comment:


  • replied
    Other How-To #5: Custom Collision Beginning to End

    Other How-To #5: Custom Collision Demonstration - Beginning to End


    Overview:

    This will be a demonstration of the concepts put forth in the documentation for FBX Static Mesh Pipeline.

    Documentation: https://docs.unrealengine.com/latest...html#collision

    Step 1: Collision Shapes

    There are three types of custom collision that can be used when creating your own custom collision.

    Click image for larger version

Name:	Types of Collision.png
Views:	1
Size:	216.1 KB
ID:	1074976

    When making convex collision shapes it’s best to avoid shapes that are like this:



    Click image for larger version

Name:	Types of Collision_No1.png
Views:	1
Size:	66.8 KB
ID:	1074978]

    A mesh that is too accurate like this will not be considered as a single convex hull. See Step 3 for examples of why this will not work well as a convex hull.


    Step 2: Naming

    Box = UBX_[MeshName]_XX

    Sphere = USP_[MeshName]_XX

    Convex = UCX_[MeshName]_XX

    When creating your custom collision mesh it is important that the mesh name of the collision mesh match the mesh you’re creating for collision. If you’re going to use more than one collision mesh you will simply need to add numbers to each collision mesh. If you're using a single collision hull, there is no need to use "_XX" after the mesh name.

    For example:

    Mesh name: Statue

    I want to add three collision spheres to my mesh.

    I create the three spheres and name each one.

    USP_Statue_00, USP_Statue_01, and USP_Statue_02

    GIF demonstration
    http://imgur.com/gallery/YuVBZMx


    Step 3: Import Options

    Click image for larger version

Name:	Import Options.png
Views:	1
Size:	68.9 KB
ID:	1074981

    There are two options here that we need to be aware of when importing custom collision.

    Auto Generate Collision: If there is no collision hulls detected with your mesh using the prefix UCX, USP, or UBX the editor will generate basic collision on import. If these prefixes are detected this option will be ignored on import.

    One Convex Hull Per UCX: This option when disabled will import more accurate collision, but it will generate multiple convex hulls rather than a single convex hull. See the example below with this disabled. This can sometimes produce errors with collision hulls that are generated though.
    __________________________________________________________________________________________________________________________________________________________________________________________________________________


    Box Collision – UBX

    Click image for larger version

Name:	UBX_BoxCollisionUE4.png
Views:	1
Size:	163.7 KB
ID:	1074983

    __________________________________________________________________________________________________________________________________________________________________________________________________________________


    Sphere Collision – USP

    Click image for larger version

Name:	USP_SphereCollisionUE4.png
Views:	1
Size:	162.7 KB
ID:	1074984

    __________________________________________________________________________________________________________________________________________________________________________________________________________________


    Convex Collision – UCX

    Click image for larger version

Name:	UCX_ConvexCollisionUE4.png
Views:	1
Size:	171.9 KB
ID:	1074985

    __________________________________________________________________________________________________________________________________________________________________________________________________________________


    Convex Collision that is too accurate

    Accurate Collision Mesh

    Click image for larger version

Name:	accurateCollisionMesh.png
Views:	1
Size:	30.9 KB
ID:	1074986


    Results with Import options One Convex Hull Per UCX: Enabled

    Click image for larger version

Name:	Convex_1Hull_Enabled.png
Views:	1
Size:	353.1 KB
ID:	1074987

    In this image you will see that with the option enabled in the import options the collision that is imported does not look like the more accurate collision mesh we have. This is because that would not be able to make a single convex collision hull.

    Think about this like a barrel with the inside hollowed out. A single convex collision hull would not be able to provide accurate collision for the interior of the mesh. The collision would simply be a cylinder that is around the barrel as a single collision hull.
    __________________________________________________________________________________________________________________________________________________________________________________________________________________


    Results with Import options One Convex Hull Per UCX: Disabled

    Click image for larger version

Name:	Convex_1Hull_Disabled.png
Views:	1
Size:	375.9 KB
ID:	1074988

    Now that we've disabled the option for one convex hull we can see that our mesh has more accurate collision that represents the original mesh above. This is done by creating multiple collision hulls from the more accurate collision mesh we tried to import.

    Click image for larger version

Name:	Convex_1Hull_Enabled_IndividualHulls.png
Views:	1
Size:	392.0 KB
ID:	1074989

    As you can see in this image with some of the collision hulls pulled off to the side we now have multiple hulls that comprise our collision for the mesh. If you look at the indicated of primitives on the top left of the viewport in the Static Mesh Editor you will see that there is a number referencing how many collision hulls were created.

    This is not necessarily the best option and it's always better to use lower collision primitive counts where possible.

    ____________________________________________________________________________________________________________________________________________________________________________________________________________

    BONUS: Creating Collision in UE4 Static Mesh Editor with AUTO-CONVEX Collision

    In the Static Mesh Editor go to Menu > Collision > Auto Convex Collision

    This will open this tab:

    Click image for larger version

Name:	AutoConvexCollisionTab.png
Views:	1
Size:	22.3 KB
ID:	1074993

    There are two options here.

    Accuracy: This will determine how accurate the collision hulls that are generated are to the mesh.

    Max Hull Verts: This will determine the number of vertices that should be used for each collision hull that is generated.


    Examples using Auto Convex Collision

    Accuracy: 0.5
    Max Hull Verts: 16
    Num of Hulls: 3

    Click image for larger version

Name:	AutoCollision1.png
Views:	1
Size:	131.4 KB
ID:	1074996
    _____________________________________________________________

    Accuracy: 0.75
    Max Hull Verts: 16
    Num of Hulls: 5

    Click image for larger version

Name:	AutoCollision2.png
Views:	1
Size:	127.8 KB
ID:	1074997

    _____________________________________________________________

    Accuracy: 1.0
    Max Hull Verts: 32
    Num of Hulls: 24

    Click image for larger version

Name:	AutoCollision3.png
Views:	1
Size:	132.8 KB
ID:	1074998

    _____________________________________________________________

    Auto Convex is getting a good update in 4.8 that will make it much more accurate when generating collision via this method.

    As you can also see from the number of collision hulls generated, even making out the auto-convex collision settings gives us much less than the 162 by generating our own collision that does not use a single convex hull.

    The best choice here is to find a balance for what works best for your collision while retaining a more true collision response to your mesh. For objects that need it this would be a good way to get more accurate collision. For objects that don't need accurate collision I would suggest using the box or sphere primitives where needed.
    Attached Files

    Leave a comment:

Working...
X