Jump to content


Photo

3D Grass Tutorial


116 replies to this topic

#61 DPRoberts

DPRoberts

    Advanced Member

  • Members
  • PipPipPip
  • 1,610 posts

Posted 17 September 2019 - 11:59 PM

If you have issues, I can try and Skype screen share with you if needed.



#62 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 18 September 2019 - 12:18 AM

Grrrr, maybe it was the Apply Experimental Transform check box???  While you were typing I tried it a 3rd time and it worked.  I feel like I did it the same what each time, but maybe I didn't  :boggle:

Another question and then I am going to stop asking so many questions lol

Should I be concerned when all tris are not highlighted in blender?

i-vP3Rskr-X3.jpg


i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#63 DPRoberts

DPRoberts

    Advanced Member

  • Members
  • PipPipPip
  • 1,610 posts

Posted 18 September 2019 - 12:25 AM

Grrrr, maybe it was the Apply Experimental Transform check box??? While you were typing I tried it a 3rd time and it worked. I feel like I did it the same what each time, but maybe I didn't :boggle:
Another question and then I am going to stop asking so many questions lol
Should I be concerned when all tris are not highlighted in blender?
i-vP3Rskr-X3.jpg


No worries on questions. Helps others that may pass through here as well.

You are good there on the selection. The "active" face will always be that way. You know it's selected because its edges are still orange. If you are worried, hit "A" to deselect all and then "A" again to reselect all.
  • jspirate likes this

#64 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 19 September 2019 - 12:20 PM

So… I am trying to understand the 3DG magic a little better. Please help me connect the dots if you can…

Questions:

Course forge splines are basically meshes with a material applied (and physics, but that is not my confusion ATM)?

Adding another mesh to add 3DG is basically making a 2nd identical mesh (except that each uses a different material)?

The shader contains LOD settings that control draw distance and thus provide some level of performance control?

Does Unity still see and draw the 2nd mesh when the 3DG blades aren’t rendered due to the LOD settings chosen in the shader/material?

Sorry… I am sure I butchered some terminology, but is my thought flow above anywhere near accurate? Maybe I don’t know what I don’t know and I am therefor too clueless to ask coherent questions lol

i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#65 Birdie

Birdie

    Advanced Member

  • Members
  • PipPipPip
  • 456 posts

Posted 19 September 2019 - 02:50 PM

You can define a LOD for the grass blade's mesh itself in the grass shader, so not for the surface mesh(copied spline mesh...). And also the LOD distance controls only the blade's mesh detail at a distance.

#66 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 19 September 2019 - 03:18 PM

You can define a LOD for the grass blade's mesh itself in the grass shader, so not for the surface mesh(copied spline mesh...). And also the LOD distance controls only the blade's mesh detail at a distance.


Thanks for the response. Is the surface mesh also getting drawn? I am guessing its not?

i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#67 Birdie

Birdie

    Advanced Member

  • Members
  • PipPipPip
  • 456 posts

Posted 19 September 2019 - 03:53 PM

Thanks for the response. Is the surface mesh also getting drawn? I am guessing its not?


Good question...
I really don't know how this all works under the hood.
On my course I retopologized some of the duplicated meshes in Instant Meshes to get a more even looking and higher resolution field of faces, for example on a rough which surrounds six holes. Then I knife cutted this very complex mesh in Blender in maybe hundred smaller meshes and imported it as an object group back to Unity. I don't know if it's better to do so and I can't prove it but I just have the feeling Unity handles these smaller meshes better than one very big one.
So it somehow feels the meshes are still getting drawn or are in calculation somehow. But as I said I can't prove this.

#68 Stingreye

Stingreye

    Advanced Member

  • Members
  • PipPipPip
  • 341 posts
  • LocationSouthern California

Posted 19 September 2019 - 04:54 PM

JSPirate, I think you will be surprised at the performance with the 3dgrass. Unless you go crazy with density, on modern 3d cards, it really doesn’t affect FPS as much as poorly optimized LOD’s on densely planted speedtrees or overplanted billboard grass. This is much more efficient than that it seems. Probably the direct x 11 thing.

#69 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 19 September 2019 - 05:07 PM

The single hole that I did didn’t see any FPS losses. I just like to have some sense of what is going on in the background.
  • Stingreye likes this

i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#70 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 22 September 2019 - 07:20 PM

Just for kicks, I tried a new blade of grass and it causes some flashing.  I made it by duplicating a mat that was working fine and then I replaced the blade with the one I an messing around with.  I like the new one, but I am getting flashing that appears to occur because a few blades flash the background on/in the blade of grass itself.

 

It does it with dynamic sky on or off. 

 

I appreciate any thoughts/ideas anyone might have.  Here is a pic to help show whats happening:

i-XtGWg3m-X3.jpg

 


i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#71 DPRoberts

DPRoberts

    Advanced Member

  • Members
  • PipPipPip
  • 1,610 posts

Posted 22 September 2019 - 07:56 PM

Are you using a texture atlas?
Can you also snip your settings around the top 1/3 of the shader.

I want to see what boxes you do and don't have checked and what shader variant you are using.

#72 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 22 September 2019 - 09:29 PM

Are you using a texture atlas?
Can you also snip your settings around the top 1/3 of the shader.

I want to see what boxes you do and don't have checked and what shader variant you are using.

 

Its not an atlas. 

 

i-dvnJFdj-X3.jpg


i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#73 DPRoberts

DPRoberts

    Advanced Member

  • Members
  • PipPipPip
  • 1,610 posts

Posted 22 September 2019 - 10:27 PM

Hmm, I guess show me the rest of the material setup.

You have that darker blade not showing the texture correctly. I also see minimal color variety happening. Do you really want to use 3 texture variant? At least from the 1 image, it seems like you might do better with less in this case.

Lastly, since you are using 3 textures and in texture density mode, I'm assuming you're using an RGBA map as well?

#74 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 22 September 2019 - 10:41 PM

Hmm, I guess show me the rest of the material setup.

You have that darker blade not showing the texture correctly. I also see minimal color variety happening. Do you really want to use 3 texture variant? At least from the 1 image, it seems like you might do better with less in this case.

Lastly, since you are using 3 textures and in texture density mode, I'm assuming you're using an RGBA map as well?

Yeah, I really haven't messed with color at all.  I just loaded it to see what I had and I found that I had flashing lol

 

Yes, I am using the RGBA map that you provided.


i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#75 DPRoberts

DPRoberts

    Advanced Member

  • Members
  • PipPipPip
  • 1,610 posts

Posted 22 September 2019 - 10:52 PM

One of your textures must not be set up correctly. Could you share them so I could load them and see what's happening?

I usually use PSDs with an alpha layer for transparency.

Or, at least show me the lower section snip of your material.

#76 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 22 September 2019 - 10:56 PM

One of your textures must not be set up correctly. Could you share them so I could load them and see what's happening?

I usually use PSDs with an alpha layer for transparency.

Or, at least show me the lower section snip of your material.

 

I just noticed that the tiling for grass blades was set to 2 X 2, so I changed that and I am rendering. 

 

Here is the pic for the rest of the mat:

i-mmPmtDN-X3.jpg


i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#77 Justin9926

Justin9926

    Advanced Member

  • Members
  • PipPipPip
  • 760 posts

Posted 22 September 2019 - 11:00 PM

Did you change the script to lower the mesh .15?  Because your picture looks like you have Dynamic Sky on


Asus ROG G751JT-CH71 Gaming Laptop

2.5 GHz Intel Core i7– 4710HQ

Nvidia GTX 970M 3GB GDDR5

16 GB DDR3

Windows 10 64-bit


#78 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 22 September 2019 - 11:03 PM

Did you change the script to lower the mesh .15?  Because your picture looks like you have Dynamic Sky on

 

I did.  I assume you only have to do that once right? After its changed, that script is what gets used whenever you run the stix grass shader regardless of what mat you use?

 

Also, changing the tiling didn't help...


i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#79 jspirate

jspirate

    Advanced Member

  • Members
  • PipPipPip
  • 487 posts

Posted 22 September 2019 - 11:10 PM

Its odd because as you move the camera, the effect takes place on different blades of grass.  It seems to be happening on less than 15% of the blades.  Could it be z-fighting or something similar?  It flashes sort of like that.

 

Maybe I should try dropping max density back and spacing the grass out some more to see what happens...


i7-8700K
GIGABYTE Z390 AORUS Pro
64 GB DDR4 3200
MSI GeForce GTX 1080 Ti Gaming X
LG 32GK850G
Win 10 Home Premium on 1TB SSD

 

Courses:

Bradford Links - released

Ironwood - released

Cypress Landing - released (also available in a 3DG version)

Crow's Nest - released


#80 DPRoberts

DPRoberts

    Advanced Member

  • Members
  • PipPipPip
  • 1,610 posts

Posted 22 September 2019 - 11:12 PM

Just trying to figure out that one blade that has textures stretched on it.

Is it assigned to a certain texture slot? Make all of one bright green, one bright magenta and one bright blue.

Although, it seems like you're using the same texture for all 3... Set the texture to "Clamp" maybe in the inspector instead of repeat



Reply to this topic



  


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users