opensourceBIM / BIMsurfer

The latest version of the BIM Surfer WebGL viewer for IFC
MIT License
384 stars 132 forks source link

How to view model without BIMServer #49

Closed Moult closed 5 years ago

Moult commented 5 years ago

I have gotten BIMsurfer working with BIMServer when it was automatically installed during the BIMServer installation.

When I clone the latest BIMsurfer and attempt to run minimal.html, I adjust my server address, username, password, and project ID as necessary, I get this in the console:

[default] Getting server info bimserverclient.js:56:14
[default] Trying to login bimserverclient.js:56:14
[default] Login successful bimserverclient.js:56:14
Connecting websocket bimserverapiwebsocket.js:22:11
[default] Getting user details bimserverclient.js:56:14
[default] Getting project details bimserverclient.js:56:14
TypeError: canvas.style is undefineddefaultcss.js:7:3

No model is shown. Most likely due to the TypeError. I assume this error is due to version mismatches between the bleeding edge BIMsurfer git clone, and the one installed by default on my BIMserver.

How can this be fixed?

Alternatively, is there a way to get BIMsurfer running without a BIMserver? Just a stock standard IFC?

huangsn10 commented 5 years ago

the process is that, IFC--》BIMServer--》converted geo data--》BIMSurfer, if no BIMserver, no data converted, and nothing to show in the BIMSurfer, is that right?

hlg commented 5 years ago

I saw a similar error in BIMsurfer 0.0.252 which was installed with BIMserver 1.5.162. The BIMserver Javascript API of these two versions matches. However there were some parameters shuffled around between different BIMsurfer API methods and the demo minimal.js had not been updated. Maybe you caught one of these inconsistent BIMsurfer versions at the time. Look at the BimServerViewer constructor and the BimServerViewer.loadModel method if you want to quick-fix this.

Just realized it's not fixed in master.