LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Python Flask Script With GUI in WebPage (https://www.linuxquestions.org/questions/programming-9/python-flask-script-with-gui-in-webpage-4175735947/)

jttolleson 04-12-2024 01:55 PM

Python Flask Script With GUI in WebPage
 
Hello all - Jayson here and I am designing a program to make a 3d solid and view it in browser, with Python on my Virtual Machine running Debian.

I have had many issues with the GUI aspect of my program, in browser ...and will continue to post updates here soon... also any help or change in direction of this code would be greatly appreciated.

Code:

[code moderated]
stl-viz.py
Code:

rom solid2 import *
from jupyterscad import view
from simple_3dviz import Mesh
from simple_3dviz.window import show
from simple_3dviz.utils import render
d = cube(5) + sphere(5).right(5) - cylinder(r=2, h=6)
scad = (scad_render(d))
view(scad, outfile='/var/www/design.stl')
m = Mesh.from_file('/var/www/design.stl', color=(0.1,0.5,0.1))
show(m, camera_position=(-60., -160, 120), camera_target=(0., 0, 40), light=(-60, -160, 120))

when i run:
Code:

sudo python3 console-stl-viewer.py
I get a browser window @ my [link moderated] that refreshes an iframe that doesent have [link moderated] in 'er.

so.....if i go there on the web when its running its not working either..

The page does connect, and there seems to be a transmission issue ...now

Must be my GUI Command?

astrogeek 04-14-2024 12:43 AM

Welcome to LQ!

The forum rules do not permit advertising, which includes promotion of personal blogs and programming projects. Please visit http://www.linuxquestions.org/advertising/ for more information on advertising. Feel free to contact the forum admin if you have any questions about this policy.

Your initial post incuded links and code which appeared to violate this policy, so those have been moderated and this thread has been closed as it had not yet gathered any replies.

You are invited to post your question in a new thread, but please avoid including links which might be considered spammy, and limit code to a minimal example which demonstrates your specific problem so that others may reproduce it and offer help.

Good luck!


All times are GMT -5. The time now is 02:34 PM.