I would like to create a plane with a grid of vertex (say 50x50) for a shader to create a wave like ocean.
It seems CardMaker will not do the work. I tried the NurbsSurfaceEvaluator class, make a flat surface and control the setNumUSubdiv and setNumVSubdiv. The result performance is very slow.
The only way left is following the procedural cube tutorial to make one for a flat plane. Is there any other ways to do it ?
Here’s what I used to do, make a lot of cards, then merge them together using flattenStrong.
This is a good idea, thank you !
In the demomaster program, under “Geometry - create various geometries”, there are function
- Create flat plane of 50x50 grids
- Create grid plane from Egg interface
The first one is created by merging of 50x50 cards, the second one is from Egg interface.
Can you advice on how to manipulate the UV coordinates of the plane from the 50x50 cards ? It is by default each cell mapped to a whole texture (0->1) but I need to map it linearly.
You can call setUvRange to set the range of uv coordinates (e.g. Point2(0.9, 0.9), Point2(1, 1))
This is all documented in the API reference:
Miss this one again ! It is working well now ! Thank you.