On Monday 01 February 2016 13:44:16 Fox Mulder wrote:

> Am 01.02.2016 um 18:32 schrieb Gene Heskett:
> > On Monday 01 February 2016 05:46:16 Fox Mulder wrote:
> >> Am 31.01.2016 um 23:49 schrieb Gene Heskett:
> >>> On Sunday 31 January 2016 11:34:46 Fox Mulder wrote:
> >>>> Am 31.01.2016 um 16:19 schrieb Gene Heskett:
> >>>>> On Sunday 31 January 2016 07:48:43 Fox Mulder wrote:
> >>>>>> Am 30.01.2016 um 02:10 schrieb Gene Heskett:
> >>>>>>> On Friday 29 January 2016 16:52:58 Gene Heskett wrote:
> >>>>>>>> On Friday 29 January 2016 15:01:16 Fox Mulder wrote:
> >>>>>>>>> Am 29.01.2016 um 04:49 schrieb Gene Heskett:
> >>>>>>>>>> On Tuesday 26 January 2016 14:16:03 Gene Heskett wrote:
> >>>>>>>>>>> On Tuesday 26 January 2016 12:41:26 Fox Mulder wrote:
> >>>>>>>>>>>> Am 26.01.2016 um 18:00 schrieb Gene Heskett:
> >>>>>>>>>>>>> On Tuesday 26 January 2016 09:55:33 Fox Mulder wrote:
> >>>>>>>>>>>>>> Am 26.01.2016 um 13:20 schrieb Gene Heskett:
> >>
> >> You can try the relevant lines in an interactive python shell to
> >> see if they work. Just start "python" (for python 2) or "python3"
> >> and try the following lines (change the picture and path to an
> >> existing one):
> >>
> >> from PIL import Image as pilimg
> >> from PIL import ImageTk
> >> from tkinter import *
> >
> > Fails here
> > gene@GO704:~/linuxcnc/configs/GO704fast$ python
> > Python 2.7.3 (default, Mar 14 2014, 11:57:14)
> > [GCC 4.7.2] on linux2
> > Type "help", "copyright", "credits" or "license" for more
> > information.
> >
> >>>> from PIL import Image as pilimg
> >>>> from PIL import ImageTk
> >>>> from tkinter import *
> >
> > Traceback (most recent call last):
> >   File "<stdin>", line 1, in <module>
> > ImportError: No module named tkinter
> >
> > But
> > from Tkinter import *
> > works
>
> Sorry i forgot that it is "import Tkinter" for your version.
>
> >> root = Tk()
> >
> > But fails here:
> >>>> root Tk()
> >
> >   File "<stdin>", line 1
> >     root Tk()
> >           ^
> > SyntaxError: invalid syntax

python and python3 gets to the root = Tk(), has same error. The rebuilt 
P3 pillow, duh, rebuild the P2 version too dummy.  And it works, I have 
video from the camera! in python2!

But the bottom of the image is clipped at aproximately the 5cm mark on 
the vertical ruler.  The window is bigger, but the image is still 
clipped.  The crosshair target is at
nominally 8.2 vertically and the horizontal ruler is off screen due to 
the clipped bottom.  The only mode that is centered if 640x480.  
Everythng else is clipped to some degree.  I will probably make 640x480 
the default in that case.
Even at 640x480, the reported FPS is .5, pretty slow.  I'll go see how it 
works with the machine live. I have another edgeing strip to put on a 
panel anyway.
>
> Sounds like the Python Tkinter package is missing (python-tk or
> python3-tk).

Both versions are installed.

> Also you must have the Tk package installed for it to 
> work. But when installing python-tk the dependency for tk should
> automatically be selected.

So is Tk.

> > No use continueing, try python3
> >
> >> img = pilimg.open('/temp/picture.png')
> >> imgtk = ImageTk.PhotoImage(img)
> >
> > When running python3 shell:
> > gene@GO704:~/linuxcnc/configs/GO704fast$ python3
> > Python 3.2.3 (default, Feb 20 2013, 17:02:41)
> > [GCC 4.7.2] on linux2
> > Type "help", "copyright", "credits" or "license" for more
> > information.
> >
> >>>> from PIL import Image as pilimg
> >
> > Traceback (most recent call last):
> >   File "<stdin>", line 1, in <module>
> > ImportError: No module named PIL
> >
> > I THOUGHT pillow built and installed itself in both paths.  But from
> > locates response, only for 2.6 and 2.7.  I'll google for it again,
> > and see if there is a pip3 utility.  Humm, but first, need pip3. But
> > its pip-3.2, not pip3, so its munching its way thru a python3
> > install of pillow.
>
> Pip only installs python2 packages, for python3 you need pip3.2.
> Just do "pip3 install Pillow" and you should have the python3 version
> of it. But with the error from python2 i don't think you will get any
> further. You need the line root = Tk() to initialize the Tk Framework
> before the other commands can be executed.

And that fails, I think from the pillow install message, it needs 
TclTk-8.5 and wheezy only has 8.4.  I'll re-enable backports and see if 
it shows up. Except I must have clean house in that list.  Then Tk IS 
8.5 but the devel stuff wasn't, installing now.  Aha, that was the magic 
twanger!

>
> > Now it should be there, but again the install bitched about a
> > missing tkinter, needs Tcl/Tk-8.5 libraries and wheezy only has 8.4.
> > This is wearing thin...
>
> Hmm that's no good news. One thing you can try is to install the
> wheezy version of the python pil packages (apt-get install
> python-imaging python-imaging-tk) which should work with the local Tk
> version. But before you have to uninstall pillow (pip uninstall
> Pillow) because they don't work together.
>
> Ciao,
>      Rainer

Thanks Rainer, progress.  Is that out most important product? :)
>
> ----------------------------------------------------------------------
>-------- Site24x7 APM Insight: Get Deep Visibility into Application
> Performance APM + Mobile APM + RUM: Monitor 3 App instances at just
> $35/Month Monitor end-to-end web transactions and take corrective
> actions now Troubleshoot faster and improve end-user experience.
> Signup Now!
> http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
> _______________________________________________
> Emc-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/emc-users


Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>

------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to