Sunday, August 6, 2017

Tutorial Post 18: Exporting as interactive HTML pages.

You can export your data to HTML page with interactive presentation of your  3D design in browsers with WebGL enabled. (Most of the modern browsers on modern devices have WebGL enabled.) You can rotate the object by mouse dragging and perform some other actions.

CLICK HERE TO SEE EXPORTED EXAMPLE.




On the File Menu (invoked with key sequence: 'QF') you may notice the following fragment:



Notice the 'NOTE ON EXPORTING'.  The exported HTML pages contain the data, but they also need a script  mki3d_view.js to be placed in the same folder. (Any folder with a collection of exported pages needs to contain one copy of this script.)

If you press the 'E' key  on the file menu,  then mki3d starts exporting.
Exporting is similar to ordinary saving:
  • If you are using mki3d as a Chrome application, then you are presented with file chooser for saving the exported page.
  • If you are using mki3d in a browser, then you are presented with with a Text Save Page where the text of the exported page is placed in OUTPUT TEXT AREA, but you can also save the file with file chooser by using artificial DOWNLOAD LINK TO SAVE DATA:







The script mki3d_view.js has been updated recently to handle touch events,  so the exported designs can be interactively viewed also on the mobile devices.
Exporting of the stereoscopic views is not implemented yet. (It is a 'future work' ;-)
In the current version (since 2017.08.11)  you can also export in the red-blue stereoscopic mode.



No comments:

Post a Comment