WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

 
 
Thread Tools Rating: Thread Rating: 2 votes, 5.00 average. Display Modes
Prev Previous Post   Next Post Next
  #4  
Old 04-13-2011, 10:21 AM
Zhi Zhi is offline
Member
 
Join Date: Mar 2011
Posts: 49
I do not use any shell technique. I simply found a very nice seamless grass texture (as attached) and applied it to the ground. To get rid of the regular pattern due to the repeated tiling of the grass patch (which gives a strong linear perspective cue). I 'blend' the detailed grass ground with a huge noise texture surface. The visual effect of such a grass field looks pretty good, even though it is still 2D textured. Here is the code:

grass = viz.addTexture('Grass.jpg') #Create the detailed grassland with about 100 m in diameter
for x in range(-51, 52, 2):
for z in range(-51, 52, 2):
if (x*x + z*z) < 52*52:
ground = viz.addTexQuad()
ground.setScale([2,2,1])
ground.setPosition([x, 0, z])
ground.setEuler([0, 90, 0])
ground.texture(grass) # Wrap texture on quad

BK = viz.addTexture('Noise.jpg') #Blend the detailed grassland with a low frequency noise map 100 m x 100 m
BKGrnd = viz.addTexQuad()
BKGrnd.setScale([100,100,1])
BKGrnd.setPosition([0, 0, 0])
BKGrnd.setEuler([0, 90, 0])
BKGrnd.texture(BK)
BKGrnd.zoffset(-1)
BKGrnd.alpha(0.2)
Attached Thumbnails
Click image for larger version

Name:	Grass.jpg
Views:	27699
Size:	1.05 MB
ID:	416   Click image for larger version

Name:	Noise.JPG
Views:	4121
Size:	768.7 KB
ID:	417  
Reply With Quote
 

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to make a nice grass field? Xianshi Xie Vizard 1 07-01-2009 12:26 PM
Multiple Textures for Diffuse and Specularity Shader Issue shivanangel Vizard 1 05-11-2009 10:44 AM


All times are GMT -7. The time now is 10:21 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC