Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #38387

Re: Monitoring updating directory for image for GUI

Path csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!newsfeed.eweka.nl!feeder3.eweka.nl!81.171.88.15.MISMATCH!eweka.nl!lightspeed.eweka.nl!194.134.4.91.MISMATCH!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <ciscorucinski@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.002
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'preferred.': 0.04; 'filename': 0.07; 'finished,': 0.07; '(same': 0.09; 'least)': 0.09; 'to:addr:comp.lang.python': 0.09; 'cc:addr:python-list': 0.10; 'gui': 0.11; 'thread': 0.11; '(just': 0.16; '(when': 0.16; 'class)': 0.16; 'command)': 0.16; 'linux)': 0.16; 'subject:GUI': 0.16; 'subject:image': 0.16; 'directory.': 0.17; 'creates': 0.18; 'windows': 0.19; 'define': 0.20; 'java': 0.21; 'displayed': 0.22; 'ones.': 0.22; 'cc:2**0': 0.23; 'mention': 0.23; 'cc:no real name:2**0': 0.24; 'command': 0.24; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'older': 0.27; '(as': 0.27; 'newer': 0.27; 'replace': 0.27; 'class': 0.29; 'asking': 0.32; 'spread': 0.32; 'real-time': 0.33; 'monitor': 0.33; 'another': 0.33; 'received:google.com': 0.34; 'received:209.85': 0.35; 'there': 0.35; 'really': 0.36; 'created': 0.36; 'but': 0.36; 'should': 0.36; 'why': 0.37; 'received:209': 0.37; 'subject:: ': 0.38; 'mean': 0.38; 'object': 0.38; 'possible.': 0.38; 'think': 0.40; 'from:no real name:2**0': 0.60; 'most': 0.61; 'latest': 0.61; 'close': 0.63; 'skip:n 10': 0.63; 'here': 0.65; 'music': 0.79; 'much,': 0.84; 'analyzed': 0.91
X-Received by 10.49.39.99 with SMTP id o3mr336010qek.14.1360284480554; Thu, 07 Feb 2013 16:48:00 -0800 (PST)
Newsgroups comp.lang.python
Date Thu, 7 Feb 2013 16:48:00 -0800 (PST)
In-Reply-To <mailman.1440.1360218333.2939.python-list@python.org>
Complaints-To groups-abuse@google.com
Injection-Info glegroupsg2000goo.googlegroups.com; posting-host=155.92.68.198; posting-account=Nf-8OgoAAACfxrvtm6NEcWRhvoTaS5A2
References <8a572770-9cc1-4b65-9053-10fd6c2f543b@googlegroups.com> <mailman.1440.1360218333.2939.python-list@python.org>
User-Agent G2/1.0
X-Google-Web-Client true
X-Google-IP 155.92.68.198
MIME-Version 1.0
Subject Re: Monitoring updating directory for image for GUI
From ciscorucinski@gmail.com
To comp.lang.python@googlegroups.com
Content-Type text/plain; charset=ISO-8859-1
Content-Transfer-Encoding quoted-printable
Cc python-list@python.org
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Message-ID <mailman.1461.1360284489.2939.python-list@python.org> (permalink)
Lines 25
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1360284489 news.xs4all.nl 6877 [2001:888:2000:d::a6]:56567
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:38387

Show key headers only | View raw


Real-time...as close to real-time as possible. That is why I did not really want to use a queue. That is because if a bunch of the thread that create the images finish really close to one another (when they should be spread out based on how the music is played), then there would be a larger "lag" in the display. So displaying only the most recent image is preferred. 

That is why I though Stack...but then that might mean that older images will replace newer ones.

The Workflow is as such:

1) Music is analyzed and streamed to the program. Note-by-Note.
2) The note is grabbed (same way as a Java Scanner class)
3) A new thread is created to call an OS command (Lilypond command)
   a) Thread waits until command is finished, and Lilypond creates an image that I can define the filename for in a directory.

>From here I want only the latest one (as close to the latest one at least) to be displayed to the gtkImage object in the GUI

I set up a class that would act as a directory monitor (just stubbed)...that would do all the work I am asking for here

Also, don't think this matters much, but I am using Windows (I seen someone mention Linux)

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Monitoring updating directory for image for GUI ciscorucinski@gmail.com - 2013-02-06 14:02 -0800
  Re: Monitoring updating directory for image for GUI Chris Angelico <rosuav@gmail.com> - 2013-02-07 17:25 +1100
    Re: Monitoring updating directory for image for GUI ciscorucinski@gmail.com - 2013-02-07 16:48 -0800
      Re: Monitoring updating directory for image for GUI Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-02-08 02:01 +0000
        Re: Monitoring updating directory for image for GUI ciscorucinski@gmail.com - 2013-02-08 09:09 -0800
          Re: Monitoring updating directory for image for GUI Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-02-09 00:53 +0000
          Re: Monitoring updating directory for image for GUI Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-02-08 20:32 -0500
        Re: Monitoring updating directory for image for GUI ciscorucinski@gmail.com - 2013-02-08 09:09 -0800
    Re: Monitoring updating directory for image for GUI ciscorucinski@gmail.com - 2013-02-07 16:48 -0800
  Re: Monitoring updating directory for image for GUI Alain Ketterlin <alain@dpt-info.u-strasbg.fr> - 2013-02-07 11:25 +0100
  Re: Monitoring updating directory for image for GUI Piet van Oostrum <piet@vanoostrum.org> - 2013-02-07 18:11 +0100
  Re: Monitoring updating directory for image for GUI ciscorucinski@gmail.com - 2013-02-11 14:50 -0800
    Re: Monitoring updating directory for image for GUI MRAB <python@mrabarnett.plus.com> - 2013-02-11 23:50 +0000
    Re: Monitoring updating directory for image for GUI Piet van Oostrum <piet@vanoostrum.org> - 2013-02-13 17:09 +0100

csiph-web