Skip to content

Commit

Permalink
Merge branch 'dev' of https://github.com/mrdoob/three.js into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
linbingquan committed Feb 1, 2019
2 parents 510468f + edaceba commit ad1c992
Show file tree
Hide file tree
Showing 49 changed files with 1,136 additions and 983 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Please also include a live example if possible. You can start from these templat
##### Three.js version

- [ ] Dev
- [ ] r100
- [ ] r101
- [ ] ...

##### Browser
Expand Down
54 changes: 29 additions & 25 deletions build/three.js

Large diffs are not rendered by default.

953 changes: 477 additions & 476 deletions build/three.min.js

Large diffs are not rendered by default.

54 changes: 29 additions & 25 deletions build/three.module.js

Large diffs are not rendered by default.

143 changes: 0 additions & 143 deletions dist/Three.d.ts

This file was deleted.

15 changes: 15 additions & 0 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ <h1><a href="http://threejs.org">three.js</a> / docs</h1>

language = value;
createNavigation();
updateFilter();
autoChangeUrlLanguage( language );

}

Expand Down Expand Up @@ -226,6 +228,19 @@ <h1><a href="http://threejs.org">three.js</a> / docs</h1>

}

// Auto change language url. If a reader open a document in English, when he click "zh", the document he read will auto change into Chinese version

function autoChangeUrlLanguage( language ) {

var hash = location.hash;
if ( hash === '' ) return;
var docType = hash.substr( 0, hash.indexOf( '/' ) + 1 );
var docLink = hash.substr( hash.indexOf( '/' ) + 1 );
docLink = docLink.substr( docLink.indexOf( '/' ) );
location.href = docType + language + docLink;

}


// Filtering

Expand Down
1 change: 1 addition & 0 deletions examples/js/nodes/Nodes.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export { NodeBuilder } from './core/NodeBuilder.js';

// inputs

export { BoolNode } from './inputs/BoolNode.js';
export { IntNode } from './inputs/IntNode.js';
export { FloatNode } from './inputs/FloatNode.js';
export { Vector2Node } from './inputs/Vector2Node.js';
Expand Down
2 changes: 2 additions & 0 deletions examples/js/nodes/THREE.Nodes.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import {

// inputs

BoolNode,
IntNode,
FloatNode,
Vector2Node,
Expand Down Expand Up @@ -132,6 +133,7 @@ THREE.NodeBuilder = NodeBuilder;

// inputs

THREE.BoolNode = BoolNode;
THREE.IntNode = IntNode;
THREE.FloatNode = FloatNode;
THREE.Vector2Node = Vector2Node;
Expand Down
4 changes: 2 additions & 2 deletions examples/js/nodes/accessors/CameraNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ CameraNode.prototype.getType = function ( builder ) {

};

CameraNode.prototype.isUnique = function ( builder ) {
CameraNode.prototype.getUnique = function ( builder ) {

switch ( this.scope ) {

Expand All @@ -116,7 +116,7 @@ CameraNode.prototype.isUnique = function ( builder ) {

};

CameraNode.prototype.isShared = function ( builder ) {
CameraNode.prototype.getShared = function ( builder ) {

switch ( this.scope ) {

Expand Down
2 changes: 1 addition & 1 deletion examples/js/nodes/accessors/NormalNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ NormalNode.prototype = Object.create( TempNode.prototype );
NormalNode.prototype.constructor = NormalNode;
NormalNode.prototype.nodeType = "Normal";

NormalNode.prototype.isShared = function ( builder ) {
NormalNode.prototype.getShared = function ( builder ) {

switch ( this.scope ) {

Expand Down
2 changes: 1 addition & 1 deletion examples/js/nodes/accessors/PositionNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ PositionNode.prototype.getType = function ( ) {

};

PositionNode.prototype.isShared = function ( builder ) {
PositionNode.prototype.getShared = function ( builder ) {

switch ( this.scope ) {

Expand Down
2 changes: 1 addition & 1 deletion examples/js/nodes/core/FunctionNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ FunctionNode.prototype.nodeType = "Function";

FunctionNode.prototype.useKeywords = true;

FunctionNode.prototype.isShared = function ( builder, output ) {
FunctionNode.prototype.getShared = function ( builder, output ) {

return ! this.isMethod;

Expand Down
16 changes: 12 additions & 4 deletions examples/js/nodes/core/InputNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,15 @@ function InputNode( type, params ) {
InputNode.prototype = Object.create( TempNode.prototype );
InputNode.prototype.constructor = InputNode;

InputNode.prototype.isReadonly = function ( builder ) {
InputNode.prototype.setReadonly = function ( value ) {

this.readonly = value;

return this;

};

InputNode.prototype.getReadonly = function ( builder ) {

return this.readonly;

Expand Down Expand Up @@ -48,7 +56,7 @@ InputNode.prototype.generate = function ( builder, output, uuid, type, ns, needs
type = type || this.getType( builder );

var data = builder.getNodeData( uuid ),
readonly = this.isReadonly( builder ) && this.generateReadonly !== undefined;
readonly = this.getReadonly( builder ) && this.generateReadonly !== undefined;

if ( readonly ) {

Expand All @@ -60,7 +68,7 @@ InputNode.prototype.generate = function ( builder, output, uuid, type, ns, needs

if ( ! data.vertex ) {

data.vertex = builder.createVertexUniform( type, this, ns, needsUpdate );
data.vertex = builder.createVertexUniform( type, this, ns, needsUpdate, this.getLabel() );

}

Expand All @@ -70,7 +78,7 @@ InputNode.prototype.generate = function ( builder, output, uuid, type, ns, needs

if ( ! data.fragment ) {

data.fragment = builder.createFragmentUniform( type, this, ns, needsUpdate );
data.fragment = builder.createFragmentUniform( type, this, ns, needsUpdate, this.getLabel() );

}

Expand Down
Loading

0 comments on commit ad1c992

Please sign in to comment.