From 4065b1730358bae70cd210863bc4a735d72511e4 Mon Sep 17 00:00:00 2001 From: leduc Date: Fri, 28 Dec 2018 11:25:21 +0100 Subject: [PATCH] webui fixs --- LJ.conf | 14 +++++++------- clients/laserglyph.py | 15 +++++++++------ tracer.py | 2 +- webui/index.html | 3 +++ 4 files changed, 20 insertions(+), 14 deletions(-) diff --git a/LJ.conf b/LJ.conf index c65d41d..9287c28 100644 --- a/LJ.conf +++ b/LJ.conf @@ -1,7 +1,7 @@ [General] set = 5 curve = 0 -lasernumber = 1 +lasernumber = 2 debug = 2 ljayserverip = 127.0.0.1 nozoscip = 127.0.0.1 @@ -28,12 +28,12 @@ warpdest = [[-1500., 1500.], [laser1] color = -1 -ip = 192.168.1.5 +ip = 192.168.1.4 kpps = 25000 centerx = 506 centery = 413 -zoomx = 30 -zoomy = 30 +zoomx = 30.0 +zoomy = 30.0 sizex = 32000 sizey = 32000 finangle = 0.0 @@ -41,9 +41,9 @@ swapx = -1 swapy = -1 lsteps = [ (1.0, 8),(0.25, 3), (0.75, 3), (1.0, 10)] warpdest = [[-1500., 1500.], - [ 1500., 1500.], - [ 1500.,-1500.], - [-1500.,-1500.]] + [ 1500., 1500.], + [ 1500.,-1500.], + [-1500.,-1500.]] [laser2] color = -1 diff --git a/clients/laserglyph.py b/clients/laserglyph.py index 51685ae..bd12d95 100644 --- a/clients/laserglyph.py +++ b/clients/laserglyph.py @@ -95,7 +95,7 @@ def Proj(x,y,z,angleX,angleY,angleZ): -def Draw3PL(): +def Draw2PL(): Shape = [] Left = [] @@ -103,7 +103,9 @@ def Draw3PL(): counter =0 while 1: - + Shape = [] + Left = [] + Right = [] for fa in faces: #print "" #print "face",fa @@ -119,11 +121,11 @@ def Draw3PL(): #print "right",x+RightShift(z*25),y,z, Proj(x+RightShift(z*25),y,z) - Shape.append(Proj(x,y,z,0,0,counter)) + #Shape.append(Proj(x,y,z,0,0,counter)) Left.append( Proj(x+LeftShift(z*5),y,z,0,0,counter)) Right.append(Proj(x+RightShift(z*5),y,z,0,0,counter)) - framy.PolyLineOneColor(Shape, c = white, PL = 0, closed = False) + #framy.PolyLineOneColor(Shape, c = white, PL = 0, closed = False) framy.PolyLineOneColor(Left, c = red, PL = 1, closed = False) framy.PolyLineOneColor(Right, c = green, PL = 2, closed = False) ''' @@ -171,8 +173,9 @@ def Draw1PL(): Right.append(Proj(x+RightShift(z*25),y,z,0,0,counter)) #framy.PolyLineOneColor(Shape, c = white, PL = 0, closed = False) - framy.PolyLineOneColor(Left, c = rgb2int(0,155,0), PL = 0, closed = False) - framy.PolyLineOneColor(Right, c = rgb2int(0,0,155), PL = 0, closed = False) + framy.PolyLineOneColor(Left, c = red, PL = 0, closed = False) + framy.PolyLineOneColor(Right, c = green, PL = 0, closed = False) + ''' framy.rPolyLineOneColor(Shape, c = white, PL = 0, closed = False, xpos = 200, ypos = 250, resize = 1, rotx =0, roty =0 , rotz=0) framy.rPolyLineOneColor(Left, c = red, PL = 1, closed = False, xpos = 200, ypos = 250, resize = 1, rotx =0, roty =0 , rotz=0) diff --git a/tracer.py b/tracer.py index 0577024..e6663ea 100644 --- a/tracer.py +++ b/tracer.py @@ -48,7 +48,7 @@ import homographyp import numpy as np black_points = [(278.0,225.0,0),(562.0,279.0,0),(401.0,375.0,0),(296.0,454.0,0),(298.0,165.0,0)] -grid_points = [(300.0,200.0,0),(500.0,00.0,65280),(500.0,400.0,65280),(300.0,400.0,65280),(300.0,200.0,65280),(200.0,100.0,0),(600.0,100.0,65280),(600.0,500.0,65280),(200.0,500.0,65280),(200.0,100.0,65280)] +grid_points = [(300.0,200.0,0),(500.0,200.0,65280),(500.0,400.0,65280),(300.0,400.0,65280),(300.0,200.0,65280),(300.0,200.0,0),(200.0,100.0,0),(600.0,100.0,65280),(600.0,500.0,65280),(200.0,500.0,65280),(200.0,100.0,65280)] r = redis.StrictRedis(host=gstt.LjayServerIP, port=6379, db=0) diff --git a/webui/index.html b/webui/index.html index 78cb79d..b69f9c1 100644 --- a/webui/index.html +++ b/webui/index.html @@ -72,6 +72,8 @@
+
+