jrlazz
December 30, 2022, 7:29am
1
Hi Three.js followers,
Pinus tree made only with Three.js and a texture
Unsatisfied with trees texturized with png image on big leaves. With objects inside the tree, the big leaves appear.
Here is the result made only with Three.js tools.
PS: Shadows take some time to be computed.
the link without shadows:
https://jrlazz.eu5.org/anim/pinus_noSh.html
the link with shadows:
https://jrlazz.eu5.org/anim/pinus_Sh.html
Again, Thanks for the great Three.js Team!
José Roberto Lazzareschi
5 Likes
anidivr
December 30, 2022, 1:00pm
2
Trees are difficult. Nice work! can your approach be used as source of an instance mesh?
2 Likes
jrlazz
December 30, 2022, 3:30pm
3
Thank You!
Sorry about the instance mesh.
I have no knowledge about it.
Merging of geometries is an option for better performance too
jrlazz
December 30, 2022, 8:12pm
5
I always look for clone() option, and do the rotations and positions by the hard way.
And use a small cube (and add the mesh to it ) to fix the position and rotating point of the mesh (hard way too).
I will look for examples of merging meshes.
Thank You!
Kind of a fir tree of 20K of rounded boxes (InstancedMesh).
Picture:
Demo:
https://codepen.io/prisoner849/pen/wvxGRvw
5 Likes
makc3d
December 30, 2022, 11:22pm
7
I waited a minute or two, but they still looked the same as right after the page loaded
1 Like
Usnul
December 31, 2022, 2:52am
8
You, sir, have a beautiful Pinus. Thank you for sharing the picture with us.
2 Likes
jrlazz
December 31, 2022, 4:06am
9
Thank You, very very much…
jrlazz
December 31, 2022, 4:09am
10
Yes, the code is the same… A friend of mine asked me to create a version with shadows.
Shadows make a magical effect on the scene.
jrlazz
January 2, 2023, 3:59am
11
I applied merging in the formation of the leaves…
Thank You for the sugestion.
1 Like
makc3d
January 2, 2023, 7:22pm
12
the shadow became pixrlated now
jrlazz
January 2, 2023, 8:31pm
13
pointLight.shadow.mapSize were 1024,
passed to 2048!