Three.js: Proposal: Rename AxesHelper, GridHelper, PolarGridHelper

Created on 27 Mar 2019  路  7Comments  路  Source: mrdoob/three.js

AxesHelper, GridHelper, and PolarGridHelper are not actually helpers, since they are not dependent on another object.

Is there support for renaming these objects to THREE.Axes, THREE.Grid, and THREE.PolarGrid?

Once concern is the axes helper is very limited, so removing the 'helper' nomenclature may be misleading to some users. (Users may expect more features, such as tick-marks and labels.)

ArrowHelper is also not dependent on another object. Maybe it could become THREE.Arrow.

Suggestion

Most helpful comment

Late feedback... 馃槄

I see these as helpers really, as they're helping to visualise the 3d world. I think the naming sets the right expectations compared to THREE.Water, THREE.Sky, etc

All 7 comments

IMO, helpers, which depend on other objects, and expect another object as a constructor arg, should not support clone(). Instead, they can optionally have an update() method.

This comment was my motivation to work at the helpers: https://github.com/mrdoob/three.js/issues/13565#issuecomment-372160160

If you call scene.clone(), then things might break if helpers are part of the scene graph. I think all objects derived from Object3D should support copy() and clone(). Besides, I would not differentiate between helpers that depend on another object and "independent" helpers.

Because of this, I'm not sure the renaming would add much benefit. The current names are actually nice descriptive.

If you call scene.clone(),...

As I have stated previously, IMO only the math objects (_maybe_) should support clone. Clone should be removed from Object3D(). That is the source of all the problems with clone.

Add clone support only to the objects for which it makes sense. It does not make sense to clone a camera helper, for example. It does make sense to update a camera helper with a different camera.

I would not differentiate between helpers that depend on another object and "independent" helpers.

The classes listed above are not helpers in the first place. What does a grid helper help?

The classes listed above are not helpers in the first place. What does a grid helper help?

Um, yeah I have to admit that a different nomenclature would be valid. But if you think of these classes as "scene helpers", the names do make sense^^

Clone should be removed from Object3D().

Is this being proposed elsewhere? I'd like to find out how would Object3D be cloned without a clone method.

Closing due to lack of support.

Late feedback... 馃槄

I see these as helpers really, as they're helping to visualise the 3d world. I think the naming sets the right expectations compared to THREE.Water, THREE.Sky, etc

Was this page helpful?
0 / 5 - 0 ratings

Related issues

makc picture makc  路  3Comments

jack-jun picture jack-jun  路  3Comments

yqrashawn picture yqrashawn  路  3Comments

filharvey picture filharvey  路  3Comments

akshaysrin picture akshaysrin  路  3Comments