Grass with 2D picture possible?

Hello,
is grass possible in UE4 with a 2D picture (in the attachment) like in Unity?
If yes, how can i do it?


Kind regards,
Andreas

Of course it is possible ^^

?v=Pqb76OXSQSY

e.g that the grass that my team and I will use in our game

e35f72b5430ae28f3d08058f03f6eb169d17101e.jpeg

Hi Halobungie,

I would certainly think it possible. If you are trying to create it with a 2D plane you could mask out the white to bring the grass to the forefront, Which would give you a defined grass shape without the rest of the texture block. I was able to do so with your texture as a very rough image, but you will probably want to get the background color to as close of a color to the grass as possible, save that as an alpha, and then use it for a mask in the editor instead of doing what I did for a quick test (plug the texture sample into a 1-x and plug that into an opacity mask. If you ensure that your texture is two sided (in the details panel of the material) it will show up, but have incredibly unseemly lines around the grass as well). Have a great day!

Hello ,
can you show me please a picture from your 2D-Grass?
Kind regards,
Andreas

Hi HaloBungie,

Here is a simple setup for how to achieve the grass. This is, as said, just a rough quick and dirty way to get something quickly. You would want to use a 3D modeling software to make some planes for this image to be applied to.

Since the image was a .png file I just used the alpha channel of that to mask out the grass. In the editor viewport I’ve enabled the meshes to show the wireframe so that you could see how the image is applied to a plane but is masking out the areas that need to be transparent. I’ve done the same for the . It’s a simple 2d plane static mesh that has a masked image applied to it. In the viewport I simply made a box brush and applied the gras material to it.

For the material you will need to check a couple of things. You will want to make the grass plane 2-sided so that you can see it from any angle (I did not have this checked to more easily show the grass opacity). you’ll also change the blend mode to “Masked.” This will enable to you plug into the ‘opacity mask’ channel on the attributes tab.

You can find more information about Opacity Maps in our documentation.

If you are having trouble with creating alpha maps, there are plenty of tutorials available via or by doing a Google search.

I hope this helps you!

Thanks!

^ His way is definitely better than mine. The image didn’t import correctly when I did it the first time. Your image should come in with an alpha channel that looks like green streaks. When it does, just plug the alpha of that into the opacity mask and you will get a clean grass line.