Skip to content

Dracoloader + Blender Compression DataCloneError #31310

@jadamus-block

Description

@jadamus-block

Description

I'm getting the following error using the default setup of the Dracoloader and cube modal out of Blender with the compression turned on. The cube is a plain cube and exported as a .glb.

DataCloneError: Failed to execute 'postMessage' on 'Worker': #<Object> could not be cloned. at three_examples_jsm_loaders_DRACOLoader__js.js?v=3c21d5ba:224:17

Reproduction steps

  1. Setup the default Draco loader
  2. Import basic model with Draco compression
  3. The model fully gets fetch but fails with it needs to get cloned in the worker

Code

// Instantiate a loader
const loader = new GLTFLoader();

// Optional: Provide a DRACOLoader instance to decode compressed mesh data
const dracoLoader = new DRACOLoader();
dracoLoader.setDecoderPath( '/examples/jsm/libs/draco/' );
loader.setDRACOLoader( dracoLoader );

// Load a glTF resource
loader.load(
	// resource URL
	'models/gltf/duck/duck.gltf',
	// called when the resource is loaded
	function ( gltf ) {

	},
	// called while loading is progressing
	function ( xhr ) {

		console.log( ( xhr.loaded / xhr.total * 100 ) + '% loaded' );

	},
	// called when loading has errors
	function ( error ) {
                 console.log('error: ', error)
		console.log( 'An error happened' );

	}
);

Live example

Screenshots

No response

Version

0.1777

Device

No response

Browser

No response

OS

No response

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions