src/loaders/support/LoaderWorkerDirector.js
function ( globalCallbacks, maxQueueSize, maxWebWorkers ) {
		if ( THREE.LoaderSupport.Validator.isValid( globalCallbacks ) ) this.workerDescription.globalCallbacks = globalCallbacks;
		this.maxQueueSize = Math.min( maxQueueSize, THREE.LoaderSupport.WorkerDirector.MAX_QUEUE_SIZE );
		this.maxWebWorkers = Math.min( maxWebWorkers, THREE.LoaderSupport.WorkerDirector.MAX_WEB_WORKER );
		this.maxWebWorkers = Math.min( this.maxWebWorkers, this.maxQueueSize );
		this.objectsCompleted = 0;
		this.instructionQueue = [];
		this.instructionQueuePointer = 0;

		for ( var instanceNo = 0; instanceNo < this.maxWebWorkers; instanceNo++ ) {

			var workerSupport = new THREE.LoaderSupport.WorkerSupport();
			workerSupport.setLogging( this.logging.enabled, this.logging.debug );
			workerSupport.setForceWorkerDataCopy( this.workerDescription.forceWorkerDataCopy );
			this.workerDescription.workerSupports[ instanceNo ] = {
				instanceNo: instanceNo,
				inUse: false,
				terminateRequested: false,
				workerSupport: workerSupport,
				loader: null
			};

		}
	}
function ( globalCallbacks, maxQueueSize, maxWebWorkers ) {
		if ( THREE.LoaderSupport.Validator.isValid( globalCallbacks ) ) this.workerDescription.globalCallbacks = globalCallbacks;
		this.maxQueueSize = Math.min( maxQueueSize, THREE.LoaderSupport.WorkerDirector.MAX_QUEUE_SIZE );
		this.maxWebWorkers = Math.min( maxWebWorkers, THREE.LoaderSupport.WorkerDirector.MAX_WEB_WORKER );
		this.maxWebWorkers = Math.min( this.maxWebWorkers, this.maxQueueSize );
		this.objectsCompleted = 0;
		this.instructionQueue = [];
		this.instructionQueuePointer = 0;

		for ( var instanceNo = 0; instanceNo < this.maxWebWorkers; instanceNo++ ) {

			var workerSupport = new THREE.LoaderSupport.WorkerSupport();
			workerSupport.setLogging( this.logging.enabled, this.logging.debug );
			workerSupport.setForceWorkerDataCopy( this.workerDescription.forceWorkerDataCopy );
			this.workerDescription.workerSupports[ instanceNo ] = {
				instanceNo: instanceNo,
				inUse: false,
				terminateRequested: false,
				workerSupport: workerSupport,
				loader: null
			};

		}
	}
function ( globalCallbacks , maxQueueSize , maxWebWorkers ) { if ( THREE . LoaderSupport . Validator . isValid ( globalCallbacks ) ) this . workerDescription . globalCallbacks = globalCallbacks ; this . maxQueueSize = Math . min ( maxQueueSize , THREE . LoaderSupport . WorkerDirector . MAX_QUEUE_SIZE ) ; this . maxWebWorkers = Math . min ( maxWebWorkers , THREE . LoaderSupport . WorkerDirector . MAX_WEB_WORKER ) ; this . maxWebWorkers = Math . min ( this . maxWebWorkers , this . maxQueueSize ) ; this . objectsCompleted = 0 ; this . instructionQueue = [ ] ; this . instructionQueuePointer = 0 ; for ( var instanceNo = 0 ; instanceNo < this . maxWebWorkers ; instanceNo ++ ) { var workerSupport = new THREE . LoaderSupport . WorkerSupport ( ) ; workerSupport . setLogging ( this . logging . enabled , this . logging . debug ) ; workerSupport . setForceWorkerDataCopy ( this . workerDescription . forceWorkerDataCopy ) ; this . workerDescription . workerSupports [ instanceNo ] = { instanceNo : instanceNo , inUse : false , terminateRequested : false , workerSupport : workerSupport , loader : null } ; } }
Create or destroy workers according limits. Set the name and register callbacks for dynamically created web workers.

@param {THREE.OBJLoader2.WWOBJLoader2.PrepDataCallbacks} globalCallbacks  Register global callbacks used by all web workers
@param {number} maxQueueSize Set the maximum size of the instruction queue (1-1024)
@param {number} maxWebWorkers Set the maximum amount of workers (1-16)
Create or destroy workers according limits . Set the name and register callbacks for dynamically created web workers .