On Sun, Feb 28, 2010 at 9:44 PM, Jonathan Thomas <[email protected]> wrote: > Dan, > I am having 1 issue with the "sdl_preview" consumer, that I did not have > with the "sdl" consumer. When I set the speed of the producer to 0, and > then seek, it always seeks back to the consumers previous position, as > opposed to where I am trying to seek to. In OpenShot, when you are > previewing (speed = 1) the project, and then click somewhere on the timeline > ruler, it always jumps back to the original position of the consumer. If I > click again on the ruler, it will then correctly seek (because the speed is > now set to 0). Any ideas?
I found your code for this in sequence.on_ruler_press. First, you have to pause before you seek. Ideally, you pause, wait for it to pause because these transport control commands are asynchronous, and then seek. However, there is not an easy way right now to wait for the pause. I can add an event, but it will make it dependent on a forthcoming mlt release. However, I found a small sleep works for me after first reordering pause and seek. === modified file 'openshot/classes/sequences.py' --- openshot/classes/sequences.py 2010-02-21 07:27:02 +0000 +++ openshot/classes/sequences.py 2010-03-01 23:55:15 +0000 @@ -16,7 +16,7 @@ # You should have received a copy of the GNU General Public License # along with OpenShot Video Editor. If not, see <http://www.gnu.org/licenses/>. -import os, sys +import os, sys, time import gtk, goocanvas import xml.dom.minidom as xml @@ -417,11 +417,12 @@ # move playhead self.project.form.MyVideo.move_play_head(self.play_head_position) - # update video frame - self.update_video() - # pause video self.project.form.MyVideo.pause() + time.sleep(0.2) + + # update video frame + self.update_video() -- +-DRD-+ ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Mlt-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mlt-devel
