Issues on Linux - designs not rendering in html viewers

  • I have just downloaded a new version of OpenJSCAD onto a recently upgraded Archlinux distribution. I last used OpenJSCAD - on this same system, but an earlier version - about a year ago. However now I have a minor, but annoying, issue. I can view designs in the index.html page by dragging and dropping the jscad script into it. So my browser indeed supports both JavaScript and WebGL.

    But what I can't do is view a design in either of the two html viewers. In fact opening up either viewer shows a blank area except for the openjscad xy plane. In neither viewer is the design rendered. I've checked the source for min.js and min.css and they're both there, and being pointed to correctly by the viewer's html code.

    Clearly I'm either missing something obvious, or I need to add something else to my system for this to work. In any case I want to use the viewers as tests for adding some of my shapes to webpages.

    What might be going wrong that a shape is not being rendered in an html viewer?

  • @Alasdair-McAndrew sure.

    check out the recent post by @crysislinux

    i haven't seen anyone embed V2 into a web page yet, but that will happen soon.

  • @z3dev Thanks - but can it be embedded somehow in another webpage?

  • @Alasdair-McAndrew super.

    only the main web page is available as this time, demo.html. the other web pages have not been ported to V2 yet.

  • @z3dev Thank you again! The web demo works very nicely, and I can pull examples into it and play around with them. It seems much faster than V1, although the scripting seems significantly different - although maybe that's just my lack of experience with V2.

    However - the viewer-minimal.html file still refuses to render anything, even when I update the design-url to point to an existing file... I'll do a bit more reading and searching. Again, many thanks.

  • @Alasdair-McAndrew Sorry. i forgot to provide the help page for installing V2 locally.

    Please install as a normal 'user' account.

    If you want to go further then please see the README file for the WEB UI. There should be some guidance on how to set up the WEB UI as part of a webserver.

  • @z3dev Thanks very much - I'll give that a go (when I've finished a current round of marking - I'm a university academic). Do you recommend installing as a user or as root? Like most Linux users, I'm the only non-root user on my system, but on the other hand I like to separate all my personal files (which are in the /home folder) from system files, which includes applications and libraries, most of which are under /usr.

  • @Alasdair-McAndrew here's some thoughts.

    For a local installation of OpenJSCAD, be sure to run the following commands.

    npm install
    npm run bootstrap

    This is true for both V1 and V2.

Log in to reply