Unreal Engine 5.2 PCG Plugin - Ep 3 - Mesh sampler, Density filtering and Subgraphs

Поделиться
HTML-код
  • Опубликовано: 15 ноя 2024
  • ИгрыИгры

Комментарии •

  • @GhostBingo
    @GhostBingo 11 месяцев назад +17

    For anyone who is looking for Density noise with newer engine release for instance 5.3 it is called Attribute Noise (Density Noise).

    • @Magnacraft
      @Magnacraft 9 месяцев назад +1

      People like you are the secret linchpin of the gamedev community

    • @fahimjaowad8717
      @fahimjaowad8717 7 месяцев назад +1

      makes so much sense naming it attribute instead of density

  • @TechArtAid
    @TechArtAid Год назад +20

    Thanks for the whole series 💚Your intro to PCG is as smooth to follow as it can be, given how advanced the system is

  • @sergeyfilin5204
    @sergeyfilin5204 2 месяца назад

    I finally realized what input and output nodes are for! Thank you!

  • @florianschmoldt8659
    @florianschmoldt8659 Год назад +2

    Fantastic, much needed tool and great tutorial. Would be great if a future episode could cover more advanced topics as well. Maybe a small town with more structured elements. Either way, thanks a lot for your work !

  • @Flipside3D
    @Flipside3D Год назад

    Thank you for developing this tool and the in depth explanation videos. This is a great basis for artists to start learning how to manipulate the tool

  • @evelynschwab7436
    @evelynschwab7436 Год назад

    Thanks for this series Adrien, loving the new tools and your teaching style! Excited for the next episode.

  • @pugmanvfx
    @pugmanvfx 6 месяцев назад

    Really awesome tutorial. Thank you for providing us your knowledge. Quick question, have you ever encountered a method that you can sample Base Color or any texture data of static mesh's material by any chance?

  • @BetaraptorLP
    @BetaraptorLP Год назад +2

    This looks very very cool, however could you please share graphs of some more complicated PCGs, like the one shown in the demo? This already looks surprisingly complicated for such a "simple" result, i can imagine something like the demo assembly can look worse than some of the most complex materials out there.

    • @adrien_logut
      @adrien_logut  Год назад +3

      I can't disclose the graph from the demo unfortunately since it has not been made public. We'll get to more complex graphs pretty quickly I think!

  • @icarosh1
    @icarosh1 Год назад

    Amazing! Thanks and I hope you can keep on uploading tutorials since pcg is a really mesmerising topic. Since you mentioned you will be talking about splines, I noticed the plugin doesn't support spline meshes, I was hoping you could give a short mention on how to utilize the plugin to crate procedural roads for example, and if mesh deformation along the spline is even possible with it. Lastly would be nice talk about blueprint compatibility and exposed properties. Regards

    • @adrien_logut
      @adrien_logut  Год назад +1

      SplineMesh is just a spline right? You can then use other techniques to do you road and set this spline to be excluded from your rule.
      For BP it is planned to talk about it! That's a lot to cover :)

  • @DmitrySinditskiy
    @DmitrySinditskiy Год назад

    Thank you f
    or this tutorial, I got stuck on sampling on smth different than landscape, hope to see the next episode soon. thank you for your work!

  • @dreambadger
    @dreambadger Год назад +1

    Thanks for the new episode.

  • @StrayVertex
    @StrayVertex Год назад

    Oh, goody! Going through this one over the weekend. Thx! :)

  • @marosvaryd
    @marosvaryd Год назад +1

    This whole PCG thing is really awsome, I just wonder if we are/will be able to manipulate somehow only one point at a time, for example delete or reposition one selected tree for finetuning the final layout? Anyway merci for the videos Adrien, really useful :)

  • @williamlacrosse9389
    @williamlacrosse9389 Год назад

    Super intéressant! Et vraiment très utile. Merci pour le partage.

  • @samuwhale410
    @samuwhale410 Год назад

    Hey Adrien, thanks for this series. I was wondering how one goes about learning all this by themselves, it seems as if there's no clear documentation available on PCG, do you just manually inspect the code base/blueprints? What are best practices?

    • @adrien_logut
      @adrien_logut  Год назад +1

      I'm a dev on the project at Epic so I know about it a bit :)
      But yeah for now it's mostly tutorials and looking at existing projects. We're still experimental and things are changing quickly. Even my tutorials are a bit outdated with 5.3 incoming

    • @samuwhale410
      @samuwhale410 Год назад

      @@adrien_logut Ah alright, makes sense! Thanks for the reply

  • @22vortex22
    @22vortex22 Год назад +1

    This series is awesome! Subscribing to keep up to date with any new videos

  • @amrumjul
    @amrumjul 8 месяцев назад

    Hey thanks for your great tutorials. I have one question: I tried both the mesh sampler method and the world query method on a static mesh landscape in UE 5.32. In editor both approaches work but in a packaged build the mesh samplers nodes don't seem to do anything. Is there currently no way to have the mesh sampler / pcg interop plugin working in a packaged build or do i need to adjust any settings for building?

    • @amrumjul
      @amrumjul 8 месяцев назад

      haha so to answer my own question: I looked at your newest video where you said to activate CPU ACCESS on static meshes for the mesh sampler to work. And that was totally it! thank you again!

  • @rainbowcatcher
    @rainbowcatcher Год назад

    Great Adrien, it s a bit too high level for me but you're a great teacher! Je vais m'accrocher 🤘. Merci et continue

  • @ibrahimahmed2821
    @ibrahimahmed2821 Год назад

    Thank for this series.
    I've a question let's say i have array of mesh in static mesh spawner is there anyway i can make mesh sampler use this array so when static mesh generate different mesh it can generate correct point from the mesh instead of i add them manually?
    Sorry for my English, hope you understand my question

  • @oskarwallin8715
    @oskarwallin8715 Год назад

    Looking forward watching!

  • @Dhieen
    @Dhieen 2 месяца назад

    Merci pour ces tutos de malade!!

  • @필살마그마웨이브
    @필살마그마웨이브 6 месяцев назад

    감사합니다.
    5.4 버전에서도 잘 작동합니다.

  • @gillgonzalez8479
    @gillgonzalez8479 Год назад

    I need some serious help here or maybe this is a bug. Ive followed your steps exactly but every time i drag in a log with mushrooms it resets the bounds back to being huge and the log is floating in mid air. No matter the times I try to save it or resize.

  • @biancabia6871
    @biancabia6871 Год назад

    Would it be possible to add elements use the procedural generation plugin on ProceduralMeshComponent?

  • @olodum111
    @olodum111 Год назад

    Hello Adrien, Is there a way I can ask you for help with your PCG #3 tutorial? I would like to send you screenshots so you can see my issue more clearly.

  • @mugiwaraneo6445
    @mugiwaraneo6445 Год назад

    Hi Adrien, thank you very much for this series of videos, absolutely clear and useful! 😊
    Also, I have a question about mesh sampling (and because most PCG info is about Landscape).
    Let's say I generate 50 meshes with an Editor tool, and they are created with a PCG component attached. I want my meshes to use MeshToPoints in their PCG graph, but MeshToPoints requires manually specifying the « Static Mesh » variable it will use... I can't find any way to expose that Static Mesh variable to the Editor, or to script something to access MeshToPoints variables to set tge Static Mesh one. Is there a way to do this?
    Perhaps via the Custom pin input on the PCG Inputs ? However, these custom inputs never show up in the Editor either, so I find it a lot more difficult to sample a Static Mesh than a Landscape…
    Thank you very much if you enlighten me on this!

    • @adrien_logut
      @adrien_logut  Год назад +1

      If the static mesh component and the pcg component are all on the same actor, you can use `PropertyToParamData` node to get the static mesh path from the component. From there, you will have an AttributeSet with the path to the mesh as an attribute, that you can plug in the Mesh Sampler under StaticMesh. That way each actor will use its own mesh.
      At stated in this video, MeshSampler is the native version of MeshToPoints, and is in another plugin, that you need to enable.
      All in all, you should have something like this: imgur.com/6CpicO2

  • @niklaslongen3526
    @niklaslongen3526 Год назад

    Hey, Thanks for the nice Tutorial.
    Is there any way to use a UDynamicMesh with its BHV to sample Points onto?
    I have procedurally generated Terrain with Dynamic Meshes and i want to use those bounds and bhv for the Foliage Generation.
    Would be cool if you could give me a start, where to look. Im pretty stuck with this, since there is no real documentation.
    Thanks in advance :D

  • @kuadiyuxianzhi
    @kuadiyuxianzhi Год назад

    Can the PCG spline walk and can it achieve animation of moving, rotating, scaling along the spline path and then restoring to its original position under custom walking

  • @haneetkhanna1883
    @haneetkhanna1883 Год назад

    how to get Meshtopoints node in 5.2 version. it doesnt show it. only mesh socket to points is available. can you plz help. i am stuck

  • @zeon3d755
    @zeon3d755 Год назад

    MeshSampler is not showing any points when I inspect. Any idea

  • @sanjitdaniel4588
    @sanjitdaniel4588 Год назад

    Amazing!! Thank you Adrien.

  • @libortelupil7647
    @libortelupil7647 Год назад

    How to do something similar with road mesh that is later used as spline mesh on the landscape? I presume I should not create those first 4 nodes, and connect something else (what?) to the "copy points" node and then add PCG component with that graph to the LandscapeSplineActor?

  • @macxike
    @macxike Год назад

    Another great tutorial. Thank you

  • @TheLazyFinn
    @TheLazyFinn Год назад

    So if I was to use this system to add moss to dungeon walls, how could I do it? Does the system need to be setup before I start placing the walls or can I do it after? What nodes would I need to use?

  • @plopyy
    @plopyy Год назад +1

    Est ce qu'on peut spawn un actor à la place d'un static mesh ?
    Je développe actuellement un jeu de survie, et j'ai besoin que la majorité des arbres et rocher sois des ressources récoltable et donc des actors avec du code d'ou ma question.

    • @jean-sebastienguay8912
      @jean-sebastienguay8912 Год назад

      Oui cependant spawné des actors a un coût plus grand en performance. Une logique plus avancée serait idéale pour remplacer des SM de loin pour des actors de proche si fait at gametime, si tout est spawné a la creation du level ou au load, les performances sont moins problématiques. Il faut seulement bien évaluer.

    • @adrien_logut
      @adrien_logut  Год назад

      Pour compléter la réponse de JS, tu peux utiliser SpawnActor pour spawn des acteurs!

    • @plopyy
      @plopyy Год назад

      @@jean-sebastienguay8912 Hum pas faux, mais au moins c'est possible, a moi de gérer donc pour l'optimisation :p.

  • @TriInfinity
    @TriInfinity Год назад

    Is it possible to only spawn certain meshes taking in consideration the ground material? Green=spawn grass, brown = spawn stones etc.? Could not figure that out yet, any hints?

    • @adrien_logut
      @adrien_logut  Год назад +1

      If you have landscape blend layers, when sampling the landscape (with the landscape pin, not landscape height) you will have those layers as attribute. You can then do a PointFilter to get only the one you desire :)
      Or you could do a MatchAndSet to set a different mesh given the attribute

    • @TriInfinity
      @TriInfinity Год назад

      @@adrien_logut 😎 thanks for the help. That seems to be what I need. Will try.

    • @tenzinlundberg8039
      @tenzinlundberg8039 Год назад

      @@adrien_logut Could you please make a tutorial on this? or add it into your next tutorial? I need this functionality badly, Thanks so much!!

  • @VLRN_
    @VLRN_ Год назад

    Hey thanks for the infos ! I may have missed it, but the log is coming from megascans. Does it mean this works with nanite meshes ? Because with foliage mode you can't paint on nanite meshes, but PCG can ?

    • @adrien_logut
      @adrien_logut  Год назад +1

      We can spawn Nanite meshes indeed! The log and mushrooms have Nanite enable.

  • @gulagwarlord
    @gulagwarlord Год назад

    Thanks so much for these videos! Can you please explain the Texture Sampler? I have masks that I use in my landscape material and I would like to use them to scatter with PDG in those different masked areas. Will that node allow for that? Another question I have... I see that you are mentioning 50k points as being a lot, but how can this be scaled up to km sized maps and still maintin interactivity like we saw in the demo? Cheers.

    • @adrien_logut
      @adrien_logut  Год назад

      I said it was a lot for my usecase ! I didn't want to spawn 10k mushroom meshes on one log :D
      You can imagine the number of points used in the Electric Dreams demo, it's a lot :P also for big maps with World Partition we have another mode that seperate our volume onto multiple ones, on a grid, to be nicer with streaming.
      For the texture sampler, I need to look at it a bit more, I haven't used it that much.

  • @CRETEGAME
    @CRETEGAME Год назад

    Beautiful framework. Really exciting! I have a question. Does the system work at runtime and seeded? i.e in a multiplayer game feed a seed from the GameState for example, and both listen server and client generate the same world?

    • @adrien_logut
      @adrien_logut  Год назад +1

      It is working at runtime, support seeding on the component, and generate calls are replicated! Most nodes are deterministic, so you will have the same result on server and client.

    • @CRETEGAME
      @CRETEGAME Год назад

      @@adrien_logut That is really amazing. Do you mind if I ask you something else, since our team is really considering jumping in?
      We are working on CRETE which is a procgen world rogue-lite. We build first our world mazes and that give us a 32x32 grid with solved paths. Each cell has a struct of borders, paths, rocks, spawners, settlements, etc, etc. The scale of a cell is 33x33 meters.
      We have a second pass where we take the foliage candidate cells and subdivide them 6-7 iterations which gives us a good grass distance. Then we do 16-32 multithread tasks driven by a seeded noise to linetrace and "paint" our biomes.
      My question is. Can I use this point cloud (6-12 million) to define the inputs in your system tasks? Or do you think your system could integrate earlier in this process? i.e giving the centres of the bigger cells and scattering within a square of each one.
      Is the generation multithread?
      Apologies for the long text and many questions! Exciting!

    • @adrien_logut
      @adrien_logut  Год назад +1

      Please keep in mind that the plugin is still experimental and it can be rough around the edges in certain cases.
      We have multithreading support, all points processings are done on multiple threads if there are enough points.
      I worked recently on a more robust API that will allow to also timeslice any processing on multiple threads, and we also plan to have not frame bounded tasks (right now, each "task" has to finish within the same frame).
      It seems to me that your rules would be feasible in PCG from the beginning, which might avoid dealing with 10M points.
      One limitation that we have right now is that we often copy the points from one node to the other. The more points you have for a long time, the slower it gets.

    • @CRETEGAME
      @CRETEGAME Год назад

      @@adrien_logut Ah, thanks for the in-depth explanation. Indeed, we don't have plans on jumping into experimental features, but this indeed has our attention and we can't wait to see how it evolves.
      Having exposed how tasks are created, also by available threads/specs, etc is incredibly valuable for loading screens.
      i.e We are finding chopping audio issues most likely due to queued tasks using the same thread, etc, so this control is always great.
      Thanks for bringing such a beautiful framework to Unreal.

  • @jooe100
    @jooe100 Год назад

    Super good thanks so much can't wait for more tutorial ! Also is there a documentation with the plugin ? Merci a toi !

    • @adrien_logut
      @adrien_logut  Год назад

      Not yet, but we should have some doc with the final release of 5.2

  • @KaelthasProductions
    @KaelthasProductions 10 месяцев назад

    is it possible to sample directly from an actor and no need to connect to the static mesh spawner?

    • @adrien_logut
      @adrien_logut  10 месяцев назад

      Depends on what you want. You can't sample directly on a mesh, you'll have to use either the Mesh Sampler or the World Ray Hit Query node (I have another video for that node).
      And yeah if you don't want to connect it to the static mesh spawner you can :)

  • @Vode1234
    @Vode1234 Год назад

    Is there a way to do this based off a texture? I have flow maps from world creator and I'd like to use that as a mask for where to spawn specific assets.

    • @adrien_logut
      @adrien_logut  Год назад

      The mesh sampler can also sample the mesh texture if I remember correctly and store it in the density. With that you can do some logic on the density (pretty much the same as in the video) to control your spawning :)

  • @TechForgeEmmad
    @TechForgeEmmad Год назад

    Isn't PCG supposed to work on rough terrain? all the meshes hide beneath the landscape even if we change the terrain even a little bit.

    • @adrien_logut
      @adrien_logut  Год назад

      It is working on the landscape, sampling the landscape will not place the points below the landscape.

  • @deuuss1
    @deuuss1 Год назад

    Hi! Great resource. I've been trying something like this also hard coding the mesh on the node. (Using mesh to points since I'm with preview). I'm using 'points from actor with tag' and tagging my rock mesh. Then with the mesh to points and copypoints I move the points to the different rocks on the scene. But again this is very limiting... How would you go about exposing the mesh parameter on the mesh to points and instead of 1 mesh having an array of all the meshes in the scene? Hope I make sense haha. Awesome video and I'll be waiting for the next one!

    • @adrien_logut
      @adrien_logut  Год назад +3

      Yes it will be possible with the use of attributes. Unfortunately in preview 1, it is not possible to override the static mesh with attributes, but it will be possible with the MeshSpawner in 5.2.

    • @deuuss1
      @deuuss1 Год назад +1

      @@adrien_logut Great! And thank you for your answer.

  • @Dhieen
    @Dhieen 2 месяца назад

    About grass, what if i spawn them with the landscape grass thing? should i undo that and spawn it with pcg only? because its colliding with all the pcg elements

    • @adrien_logut
      @adrien_logut  2 месяца назад +1

      We don't interact with the landscape system, so you won't be able to remove intersection with PCG. You'll have to do all in PCG. But grass (or any highly tight and dense mesh placement like foliage) is not fully ready with PCG as it generates a lot of points and can quickly reach Out of Memory or tank your framerate.

    • @Dhieen
      @Dhieen 2 месяца назад

      @@adrien_logut oooh ok so pcg is not perfect yet lol, but if its a grass clump (multiple blades in one mesh, nanite), its ok no?

    • @adrien_logut
      @adrien_logut  2 месяца назад +1

      The main issue comes to the fact that each grass position will be a point, on the CPU that would then be added into an instanced static mesh component. But the first phase of creating the point might overload your RAM (depending on how you do the generation, you will need to partition the component to be sure you don't get OOM and benefit naturally of the streaming system).
      But try it, that's the best way to verify :D

  • @hydeman75
    @hydeman75 10 месяцев назад

    amazing content , thanks a lot 🙌

  • @777Darker777
    @777Darker777 Год назад

    Is there a posibility to sample landscape layers, to spawn assets on specific landcape layer ?

    • @adrien_logut
      @adrien_logut  Год назад

      Yes using the landscape pin instead of the landscape height pin, you will have the layers weights as attributes for each point sampled.

    • @Jsfilmz
      @Jsfilmz Год назад

      ​@@adrien_logutwill blocking volumee eventually work with pcg or do we have to use difference node to not spawn in some areas?thanks dude

    • @adrien_logut
      @adrien_logut  Год назад

      Not sure I understand your concern. The difference node is exactly what you need to not spawn in some area.

    • @tenzinlundberg8039
      @tenzinlundberg8039 Год назад

      @@adrien_logut Could you please make a tutorial on this? or add it into your next tutorial? I need this functionality badly, Thanks so much!!

  • @jenipring
    @jenipring Год назад

    Loving the tutorials however when following the github link for the extra plugin i just get 404 page not found

    • @adrien_logut
      @adrien_logut  Год назад +1

      You need to be registered to the Epic Games' group on GitHub first!

    • @jenipring
      @jenipring Год назад +1

      @@adrien_logut ahh that wld explain that ty :D

  • @tayhwang3653
    @tayhwang3653 Год назад

    THANK YOU SO VERY MUCH SIR!!!!!!!!!!!!!

  • @fbi555
    @fbi555 Год назад

    Great tutorial! Is it possible to generate a procedural landscape sculpt with pcg?

    • @adrien_logut
      @adrien_logut  Год назад

      AFAIK you cannot modify the landscape with PCG

    • @fbi555
      @fbi555 Год назад

      @@adrien_logut Oh ok, thanks for the answer. Do you know whether PCG will be compatible with voxel?

    • @adrien_logut
      @adrien_logut  Год назад

      We never try anything internally with voxels, but if you have collision on your voxelized world, you can try with World Ray Hit. We have a node for that. It will probably be costly though.

    • @fbi555
      @fbi555 Год назад

      @@adrien_logut Thanks for the hint. I am searching for a method to edit a landscape realtime. Is there anything like this available in unreal engine?

    • @adrien_logut
      @adrien_logut  Год назад

      I don't think it is possible to do it at runtime. Landscape edition is only in editor IIRC

  • @peterallely5417
    @peterallely5417 Год назад

    This is great, thanks!

  • @modz7014
    @modz7014 Год назад

    👏👏👏👏

  • @PP-qi4fp
    @PP-qi4fp Год назад

    Can it generate at realtime in packaged game?

  • @oskarwallin8715
    @oskarwallin8715 Год назад

    Sadly I cant get the mesh sampler node :( im guessing i just have to wait until the launcher updates.

    • @adrien_logut
      @adrien_logut  Год назад

      As stated in the video you can use MeshToPoints ;)

    • @oskarwallin8715
      @oskarwallin8715 Год назад

      @@adrien_logut that only works with a chosen mesh from the asset browser, looking for a way to sample static mesh terrains :)

    • @adrien_logut
      @adrien_logut  Год назад

      MeshSampler will probably not help you with that one either, since you need to select the asset also.
      I'm not familiar with the specificities of static mesh terrains, but perhaps you can look into the World Query nodes (World Ray Hit Query and World Volumetrix Query)

    • @oskarwallin8715
      @oskarwallin8715 Год назад +1

      @@adrien_logut Yeah, the world ray is the only way ive found to recognize a static mesh in the world so far (that wasnt added by the PCG itself).

  • @loiccaval7150
    @loiccaval7150 Год назад

    Big thanks

  • @follentass932
    @follentass932 Год назад

    I dont have procedural content generation framework geometry interop (

    • @adrien_logut
      @adrien_logut  Год назад

      Only in final version of 5.2

    • @follentass932
      @follentass932 Год назад

      @@adrien_logut So we'll have to wait for it to come out?!

    • @adrien_logut
      @adrien_logut  Год назад

      To use the MeshSampler yes, but in the mean time you can use MeshToPoints, which is the Blueprint version of the MeshSampler, and has analog options.

  • @guilloisvincent2286
    @guilloisvincent2286 Год назад

    Thanks a lot :D

  • @Lv7-L30N
    @Lv7-L30N Год назад

    gracias

  • @ConfusionWood
    @ConfusionWood Год назад

    Great

  • @vanadot
    @vanadot Год назад

    Anyone lazyly duplicated the grass nodes and accidentally add thousands of mushroom-in-a-log? Go apologize and hug your PC...

  • @王叶军-g9m
    @王叶军-g9m Год назад

    cool!