Hi all. Which lights work best for a car headlights I have created a basic scene where a truck travels on a road… i am struggling in creating lights for headlights… I have tried recArealights … Pointlight and spotlight
Pointlight and spotlight fail… because they don’t point to the new target you set instead they end up pointing to the origin. so you end up with lights pointing in the correct direction before the origin and pointing backwards after the origin
This is a problem in your code since you can change the target for SpotLight. Check out SpotLight.target. In any event, using an instance of SpotLight seems the right approach. Ideal for stuff like headlights or flashlights.
BTW: A PointLight is omnidirectional and has no target.
Using SpotLight.target is a bit hard… But if you attach the light target to the car as a sibling to the light, the light will point at the local position, following the motion of the car.
That is a nice collection! Almost all of them seem to work too. I only miss a reference to the original context/question where each example is posted. I think that would be useful.
On the selection page per year it also says. en/de
As you can see in the index file, I only copy one schema there.
As I wrote, I must absolutely minimize the effort for me. There is still enough work to view all contributions and copy the examples.
That’s why there are some basic examples in the extended ones as well. Copying it was too complex for me for various reasons.
Extended ones are only links. Whether they will work forever is open.
With the copies of the basic examples are perhaps only some resources later no longer available.
I only copy HTML, CSS and JS, replace important external scripts like three.js OrbitControls … by the ones on my server with the appropriate version (which is static then!) and paste
// @author … in the main script.
Enough work.
The example page itself is usually not changed in the layout. Who only looks at it does not need a source, who has interest looks into the source text and finds all information.
No worries. I understand that your time is valuable, and that I cannot dictate how you should spend it. I appreciate the collection of the examples, and now also see that you have provided references to the original context, although “hidden” in the sources.