Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Using some of the above code changes, trying to see what is going on with the stop function. ( got it kind of fully working, without removing this earlier, but seems to be unhappy at this point again, might be intermittant )
- Implemented following debugging statements to give feedback
- mediacontroller.py
- :472
- def video_reset(self, controller):
- """
- Responds to the request to reset a loaded video
- """
- #log.debug(u'video_reset')
- print 'btm: video_reset-start'
- print 'btm: video_reset-self.set_controls_visible(controller, False)'
- self.set_controls_visible(controller, False)
- print 'btm: video_reset-for display in self.curDisplayMediaPlayer.keys():'
- for display in self.curDisplayMediaPlayer.keys():
- print 'btm: video_reset-if display.controller == controller:'
- if display.controller == controller:
- print 'btm: video_reset-display.override = {}'
- display.override = {}
- print 'btm: video_reset-self.curDisplayMediaPlayer[display].reset(display)'
- self.curDisplayMediaPlayer[display].reset(display)
- print 'btm: video_reset- self.curDisplayMediaPlayer[display].set_visible(display, False)'
- self.curDisplayMediaPlayer[display].set_visible(display, False)
- print 'btm: video_reset-display.frame.evaluateJavaScript'
- display.frame.evaluateJavaScript(u'show_video( \
- "setBackBoard", null, null, null,"hidden");')
- print 'btm: video_reset-start'
- del self.curDisplayMediaPlayer[display]
- print 'btm: video_reset-del self.curDisplayMediaPlayer[display]'
- print 'btm: video_reset-end'
- vlcplayer.py
- :226
- def reset(self, display):
- print "btm: reset display"
- print "btm: stop()" <--- this is last statement where entire app hangs, which means it's in vlc.py stop function below
- #display.vlcMediaPlayer.stop()
- print "btm: setVisible(False)"
- display.vlcWidget.setVisible(False)
- print "btm: state = MediaState.Off"
- self.state = MediaState.Off
- print "btm: done reset display"
- pass
- vlc.py
- :2419
- def stop(self):
- '''Stop (no effect if there is no media).
- '''
- return libvlc_media_player_stop(self)
- :4326
- def libvlc_media_player_stop(p_mi):
- '''Stop (no effect if there is no media).
- @param p_mi: the Media Player.
- '''
- f = _Cfunctions.get('libvlc_media_player_stop', None) or \
- _Cfunction('libvlc_media_player_stop', ((1,),), None,
- None, MediaPlayer)
- return f(p_mi)
- Tested with various vlc versions as follows, all on 10.6 mac
- vlc-2.0.3-32and64bit.dmg
- Starting on OS X now
- btm vlc_args: --no-video-title-show
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-if display.controller == controller:
- btm: video_reset-display.override = {}
- btm: video_reset-self.curDisplayMediaPlayer[display].reset(display)
- btm: reset display
- btm: stop()
- (app freezes here)
- vlc-2.0.3-intel64.dmg
- File "/Users/brianmeyerdesign/Projects/openlp/mysqlideas/build/pyi.darwin/OpenLP/out00-PYZ.pyz/openlp.core.ui.media.vlc", line 107, in find_lib
- File "/Users/brianmeyerdesign/Projects/openlp/mysqlideas/build/pyi.darwin/OpenLP/out00-PYZ.pyz/ctypes", line 365, in __init__
- OSError: dlopen(/Applications/VLC.app/Contents/MacOS/lib/libvlc.dylib, 6): no suitable image found. Did find:
- /Applications/VLC.app/Contents/MacOS/lib/libvlc.dylib: mach-o, but wrong architecture
- vlc-2.0.3-intel32.dmg
- Starting on OS X now
- btm vlc_args: --no-video-title-show
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-end
- TagLib: MP4: No audio tracks
- TagLib: MP4: No audio tracks
- btm: video_reset-start
- btm: video_reset-self.set_controls_visible(controller, False)
- btm: video_reset-for display in self.curDisplayMediaPlayer.keys():
- btm: video_reset-if display.controller == controller:
- btm: video_reset-display.override = {}
- btm: video_reset-self.curDisplayMediaPlayer[display].reset(display)
- btm: reset display
- btm: stop()
- Now used Spin Control when it dies...
- Call graph:
- 2461 Thread_1835944 DispatchQueue_1: com.apple.main-thread (serial)
- + 2461 vlc_join (in libvlccore.5.dylib) + 23 [0x1a089bd7]
- + 2461 pthread_join$UNIX2003 (in libSystem.B.dylib) + 1021 [0x915b5be8]
- + 2461 __semwait_signal (in libSystem.B.dylib) + 10 [0x91576aa2]
- 2461 Thread_1835946 DispatchQueue_2: com.apple.libdispatch-manager (serial)
- + 2461 start_wqthread (in libSystem.B.dylib) + 30 [0x9156e5c6]
- + 2461 _pthread_wqthread (in libSystem.B.dylib) + 390 [0x9156e781]
- + 2461 _dispatch_worker_thread2 (in libSystem.B.dylib) + 240 [0x9156ecfe]
- + 2461 _dispatch_queue_invoke (in libSystem.B.dylib) + 163 [0x9156ef59]
- + 2461 _dispatch_mgr_invoke (in libSystem.B.dylib) + 215 [0x9156fa9c]
- + 2461 kevent (in libSystem.B.dylib) + 10 [0x9156f382]
- 2461 Thread_1836192
- + 2461 thread_start (in libSystem.B.dylib) + 34 [0x915760de]
- + 2461 _pthread_start (in libSystem.B.dylib) + 345 [0x91576259]
- + 2461 QThreadPrivate::start(void*) (in libQtCore.4.dylib) + 381 [0x1218742b]
- + 2461 QThread::exec() (in libQtCore.4.dylib) + 203 [0x1218470d]
- + 2461 QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (in libQtCore.4.dylib) + 494 [0x12279970]
- + 2461 QEventDispatcherUNIX::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) (in libQtCore.4.dylib) + 234 [0x122aaf68]
- + 2461 QEventDispatcherUNIXPrivate::doSelect(QFlags<QEventLoop::ProcessEventsFlag>, timeval*) (in libQtCore.4.dylib) + 1180 [0x122aaaac]
- + 2461 QEventDispatcherUNIX::select(int, fd_set*, fd_set*, fd_set*, timeval*) (in libQtCore.4.dylib) + 45 [0x122a9bb1]
- + 2461 qt_safe_select(int, fd_set*, fd_set*, fd_set*, timeval const*) (in libQtCore.4.dylib) + 440 [0x122a5dc8]
- + 2461 select$DARWIN_EXTSN (in libSystem.B.dylib) + 10 [0x91567ac6]
- 2461 Thread_1836237: com.apple.CFSocket.private
- + 2461 thread_start (in libSystem.B.dylib) + 34 [0x915760de]
- + 2461 _pthread_start (in libSystem.B.dylib) + 345 [0x91576259]
- + 2461 __CFSocketManager (in CoreFoundation) + 1091 [0x95286c53]
- + 2461 select$DARWIN_EXTSN (in libSystem.B.dylib) + 10 [0x91567ac6]
- 2461 Thread_1836286
- + 2461 vlc_join (in libvlccore.5.dylib) + 23 [0x1a089bd7]
- + 2461 pthread_join$UNIX2003 (in libSystem.B.dylib) + 1021 [0x915b5be8]
- + 2461 __semwait_signal (in libSystem.B.dylib) + 10 [0x91576aa2]
- 2461 Thread_1836292
- + 2461 ff_thread_get_buffer (in libavcodec_plugin.dylib) + 284 [0x24c413fc]
- + 2461 pthread_cond_wait$UNIX2003 (in libSystem.B.dylib) + 73 [0x915783f8]
- + 2461 _pthread_cond_wait (in libSystem.B.dylib) + 1191 [0x9157675e]
- + 2461 __semwait_signal (in libSystem.B.dylib) + 10 [0x91576aa2]
- 2461 Thread_1836293
- + 2461 frame_worker_thread (in libavcodec_plugin.dylib) + 160 [0x24c41620]
- + 2461 pthread_cond_wait$UNIX2003 (in libSystem.B.dylib) + 73 [0x915783f8]
- + 2461 _pthread_cond_wait (in libSystem.B.dylib) + 1191 [0x9157675e]
- + 2461 __semwait_signal (in libSystem.B.dylib) + 10 [0x91576aa2]
- 2461 Thread_1836294
- + 2461 frame_worker_thread (in libavcodec_plugin.dylib) + 160 [0x24c41620]
- + 2461 pthread_cond_wait$UNIX2003 (in libSystem.B.dylib) + 73 [0x915783f8]
- + 2461 _pthread_cond_wait (in libSystem.B.dylib) + 1191 [0x9157675e]
- + 2461 __semwait_signal (in libSystem.B.dylib) + 10 [0x91576aa2]
- 2461 Thread_1836295
- + 2461 vlc_cond_wait (in libvlccore.5.dylib) + 23 [0x1a089e57]
- + 2461 pthread_cond_wait$UNIX2003 (in libSystem.B.dylib) + 73 [0x915783f8]
- + 2461 _pthread_cond_wait (in libSystem.B.dylib) + 1191 [0x9157675e]
- + 2461 __semwait_signal (in libSystem.B.dylib) + 10 [0x91576aa2]
- 2461 Thread_1836296
- + 2461 vlc_mutex_lock (in libvlccore.5.dylib) + 15 [0x1a089f7f]
- + 2461 pthread_mutex_lock (in libSystem.B.dylib) + 490 [0x9154e646]
- + 2461 semaphore_wait_signal_trap (in libSystem.B.dylib) + 10 [0x91548b42]
- 2461 Thread_1836298
- 2461 Open (in libvout_macosx_plugin.dylib) + 587 [0x21bdfaab]
- 2461 -[NSObject(NSThreadPerformAdditions) performSelectorOnMainThread:withObject:waitUntilDone:] (in Foundation) + 184 [0x98d2b80f]
- 2461 -[NSObject(NSThreadPerformAdditions) performSelector:onThread:withObject:waitUntilDone:modes:] (in Foundation) + 1111 [0x98d18d35]
- 2461 -[NSCondition wait] (in Foundation) + 316 [0x98d2b6b3]
- 2461 pthread_cond_wait$UNIX2003 (in libSystem.B.dylib) + 73 [0x915783f8]
- 2461 _pthread_cond_wait (in libSystem.B.dylib) + 1191 [0x9157675e]
- 2461 __semwait_signal (in libSystem.B.dylib) + 10 [0x91576aa2]
- Total number in stack (recursive counted multiple, when >=5):
- 7 __semwait_signal (in libSystem.B.dylib) + 0 [0x91576a98]
- 5 _pthread_cond_wait (in libSystem.B.dylib) + 1191 [0x9157675e]
- 5 pthread_cond_wait$UNIX2003 (in libSystem.B.dylib) + 73 [0x915783f8]
- Sort by top of stack, same collapsed (when >= 5):
- __semwait_signal (in libSystem.B.dylib) 17227
- select$DARWIN_EXTSN (in libSystem.B.dylib) 4922
- kevent (in libSystem.B.dylib) 2461
- semaphore_wait_signal_trap (in libSystem.B.dylib) 2461
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement