@@ -44,6 +44,26 @@ var CUSTOM_CLASSES = [
44
44
'objects/Blackbox.js' ,
45
45
] ;
46
46
47
+ var IGNORE_FILES = [
48
+ '**/Three.Legacy.js' , // Don't support legacy interface (deprecation should be done python side)
49
+ '**/Three.js' , // Don't process aggregrate file
50
+ '**/polyfills.js' , // Polyfill of JS methods, nothing to export
51
+ '**/utils.js' , // Utility functions, no objects to export
52
+ '**/constants.js' , // Processed into enums in separate script
53
+ '**/animation/KeyframeTrackConstructor.js' , // Sub-part of one object, ignore
54
+ '**/animation/KeyframeTrackPrototype.js' , // Sub-part of one object, ignore
55
+ '**/audio/AudioContext.js' , // JS API for audio, nothing to expose
56
+ '**/geometries/Geometries.js' , // index.js like file, nothing new here
57
+ '**/materials/Materials.js' , // index.js like file, nothing new here
58
+ '**/renderers/WebGLRenderer.js' , // For now, the internals of the webgl
59
+ '**/renderers/WebGL2Renderer.js' , // render is not exposed.
60
+ '**/renderers/webgl/**' ,
61
+ '**/renderers/shaders/**' ,
62
+ '**/extras/core/Interpolations.js' , // Only functions, nothing to export
63
+ '**/extras/core/PathPrototype.js' , // Sub-part of one object, ignore
64
+ '**/textures/CanvasTexture.js' // Canvases are not referenceable from python
65
+ ]
66
+
47
67
48
68
//
49
69
// Templates
@@ -157,10 +177,10 @@ function relativePathToPythonImportPath(relativePath) {
157
177
if ( tokens . length <= 0 ) { return '.' ; }
158
178
159
179
var result = '' ;
160
- if ( firstToken == '.' ) {
180
+ if ( firstToken === '.' ) {
161
181
tokens = tokens . slice ( 1 ) ;
162
182
result = '' ;
163
- } else if ( firstToken == '..' ) {
183
+ } else if ( firstToken === '..' ) {
164
184
tokens = tokens . slice ( 1 ) ;
165
185
result = '.' ;
166
186
}
@@ -243,24 +263,7 @@ function mapPromiseFnOverThreeModules(mapFn) {
243
263
return mapPromiseFnOverGlob ( '**/*.js' , mapFn , {
244
264
cwd : threeSrcDir ,
245
265
nodir : true ,
246
- ignore : [
247
- '**/Three.Legacy.js' , // Don't support legacy interface (deprecation should be done python side)
248
- '**/polyfills.js' , // Polyfill of JS methods, nothing to export
249
- '**/utils.js' , // Utility functions, no objects to export
250
- '**/constants.js' , // Processed into enums in separate script
251
- '**/animation/KeyframeTrackConstructor.js' , // Sub-part of one object, ignore
252
- '**/animation/KeyframeTrackPrototype.js' , // Sub-part of one object, ignore
253
- '**/audio/AudioContext.js' , // JS API for audio, nothing to expose
254
- '**/geometries/Geometries.js' , // index.js like file, nothing new here
255
- '**/materials/Materials.js' , // index.js like file, nothing new here
256
- '**/renderers/WebGLRenderer.js' , // For now, the internals of the webgl
257
- '**/renderers/WebGL2Renderer.js' , // render is not exposed.
258
- '**/renderers/webgl/**' ,
259
- '**/renderers/shaders/**' ,
260
- '**/extras/core/Interpolations.js' , // Only functions, nothing to export
261
- '**/extras/core/PathPrototype.js' , // Sub-part of one object, ignore
262
- '**/textures/CanvasTexture.js' // Canvases are not referenceable from python
263
- ] ,
266
+ ignore : IGNORE_FILES ,
264
267
} ) ;
265
268
}
266
269
0 commit comments