Skip to content
This repository has been archived by the owner on Oct 20, 2020. It is now read-only.

The problem for loading zip #1012

Open
DengCun opened this issue Nov 11, 2019 · 0 comments
Open

The problem for loading zip #1012

DengCun opened this issue Nov 11, 2019 · 0 comments

Comments

@DengCun
Copy link

DengCun commented Nov 11, 2019

I can not load zip file by using under code.

var modelURL = 'character.zip';
var request = osgDB.readNodeURL(modelURL);

request
    .then(function(model) {
        var mt = new osg.MatrixTransform();
        osg.mat4.rotateZ(mt.getMatrix(), mt.getMatrix(), -Math.PI);

        mt.addChild(model);

        rootNode.addChild(mt);
        viewer.getManipulator().computeHomePosition();

        var loading = document.getElementById('loading');
        document.body.removeChild(loading);
    })
    .catch(function() {
        osg.warn('cant load ' + modelURL);
    });
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant