Core vs examples

Hi there,
I often find very interesting modules in example javascript code and I wonder what can lead them to be integrated into src/ directory and who decides. This would be much easier to maintain projects built on top of THREE to have such modules part of the core source code on updates.

For example this morning I found THREE.CombinedCamera to be very useful. THREE.EffectComposer and passes is also a terrific addition to the core source.

This is a decision for the community. If there is a good argument that the use goes beyond a specific user’s case, and it does not add too many kbs to the builds, then it is added.

If those things are useful to you, then you can always include them in your projects as separate files or build your own version of three.js that includes those.

In my case, I use OrbitControls, but I have other javascript files as well. What I do is I combine all of the pertinent javascript files into one .js file to run with my app. So, I have OrbitControls.js, Detector.js, and three.js as separate files that get combined when I distribute my app to users. During development I keep them as separate files.

All of this is automated through npm and gulp tasks.

I also include these files as separated scripts and gather them into one JS at build time. My question was more about what makes maintainers decide to migrate some example code into src/ folder. Your first answer sounds fair.

I saw many projects on the web embedding effect composer and passes and I guess it’s a good argument to decide to migrate it into the core. And it’s about ~150KB.

Combined camera is also interesting, first it’s a tiny addition, and it allows user to switch from orthographic to perspective with a good conservation of user interface parameters. Really useful for aerial content/map display.