GLTFExporter unsupported bufferAttribute component type!

GLTFExporter unsupported bufferAttribute component type!
In the past, my model was compressed with draco, and it was displayed on the web page normally, and it was also normal to export the file with GLTFExporter. However, due to the draco compressed model, the decompression speed is relatively slow, and the display is no problem if it is changed to GLTFPACK compression. But when I want to export the page, I am prompted that the bufferAttribute component type is not supported. Has anyone encountered such a problem? How to solve it?

Do you mind modifying GLTFExporter at the place where the exception is thrown? Please add the following log:

console.log( attribute.array.constructor ); // new line
throw new Error( 'THREE.GLTFExporter: Unsupported bufferAttribute component type.' );

Can you please share the information of the log? It might be also helpful to share a complete live example demonstrating the issue.

This is my code:

var loader = new THREE.GLTFLoader();
loader.load(model_path, function(gltf) {
theModel = gltf.scene;
theModel.position.y = -1.2;
var urlsave = ‘’;
var qhxhr = new XMLHttpRequest();‘POST’, urlsave, true);
var blobfile = null;
var fdata = new FormData();

var btnsave = document.getElementById(‘savejm’);
btnsave.addEventListener(‘click’, saves);
function saves() {
var exporter3D = new THREE.GLTFExporter();
exporter3D.parse(modelg, function(glbfile) {
if (glbfile instanceof ArrayBuffer) {
saveArrayBuffer(glbfile, ‘customize1.glb’);
} else {
var scenejson = JSON.stringify(glbfile, null, 2);
saveString(scenejson, ‘customize.glb’);
}, binary = true, onlyVisible = true );
function saveString(text, filename) {

  save(new Blob([text], {
  	type: 'text/plain'
  }), filename);

function saveArrayBuffer(buffer, filename) {
save(new Blob([buffer], {
type: ‘application/octet-stream’
}), filename);
function save(blob, filename) {
fdata.append(‘file’, blob, ‘customize.glb’);
qhxhr.upload.addEventListener(“progress”, function(result) {
if (result.lengthComputable) {
var percent = (result.loaded / * 100).toFixed(2);
}, false);

Please help me find out where the problem is, thanks!

Do you have an example of a glTF model that fails to export correctly? If so, I would recommend opening a new issue on the three.js repository, including the model. I suspect what’s happening here is that GLTFExporter cannot export models that require KHR_mesh_quantization.

Can you give me a link?

Bugs can be reported here:

Thank you!

Problem is not solved. I got the GLTFExporter file from here.

No, sorry, no changes have been made yet — please report the bug to the three.js issue tracker at the link above. These are just the forums; we use GitHub to track bug reports.

Ok, i will.

This is my glb.