| Issue 216: | gst.ElementNotFoundError: appsink when try to run video.py in example | |
| 1 person starred this issue and may be notified of changes. | Back to list |
I run video.py by using python 2.6 on ubuntu and caught the error.
[INFO ] PyMT v0.4
[DEBUG ] [Config ] Upgrading from 8
/usr/lib/python2.6/site-packages/OpenGL/platform/__init__.py:20:
UserWarning: Module OpenGL was already imported from
/usr/lib/python2.6/site-packages/OpenGL/__init__.py, but
/usr/lib/python2.5/site-packages is being added to sys.path
import os, sys, pkg_resources
[INFO ] [Camera ] using <gstreamer> as camera provider
[INFO ] [Logger ] Record log in /home/bunthidj/.pymt/logs/pymt_10-02-
22_1.txt
[INFO ] [Text ] using <pygame> as text provider
[INFO ] [Video ] using <gstreamer> as video provider
[INFO ] [OSC ] using <multiprocessing> for socket
[INFO ] [Loader ] using <pygame> as thread loader
[INFO ] [Window ] use Pygame as window provider.
[WARNING] [WinPygame] Video: failed (multisamples=2)
[WARNING] [Video ] trying without antialiasing
[INFO ] [Window ] OpenGL version <1.4 (2.1.8087 Release)>
Traceback (most recent call last):
File "video.py", line 15, in <module>
video = MTVideo(filename='super-
fly.avi',on_playback_end='loop',volume=0.1, autostart=True)
File "/usr/lib/python2.6/site-
packages/pymt/ui/widgets/composed/video.py", line 94, in __init__
super(MTVideo, self).__init__(**kwargs)
File "/usr/lib/python2.6/site-
packages/pymt/ui/widgets/composed/video.py", line 37, in __init__
self.player = pymt.Video(filename=filename)
File "/usr/lib/python2.6/site-
packages/pymt/core/video/video_gstreamer.py", line 41, in __init__
super(VideoGStreamer, self).__init__(**kwargs)
File "/usr/lib/python2.6/site-packages/pymt/core/video/__init__.py", line
49, in __init__
self.filename = kwargs.get('filename')
File "/usr/lib/python2.6/site-packages/pymt/core/video/__init__.py", line
68, in <lambda>
lambda self, x: self._set_filename(x),
File "/usr/lib/python2.6/site-packages/pymt/core/video/__init__.py", line
66, in _set_filename
self.load()
File "/usr/lib/python2.6/site-
packages/pymt/core/video/video_gstreamer.py", line 99, in load
self._videosink = gst.element_factory_make('appsink', 'videosink')
gst.ElementNotFoundError: appsink
PS. Most of other pymt examples work well and I've already installed
gstreamer, pygst on my machine (and it's work well with other python
application too).
Apr 5, 2010
Project Member
#1
txprog
Jul 5, 2010
Ok, no information from the user since 3 month, closing this bug;
Status:
Invalid
Aug 18, 2010
same issue with win32 portable package on win7 (x64)
botstrapping PyMT @ C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\
Setting Environment Variables:
#################################
GST_PLUGIN_PATH:
C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\gstreamer\lib\gstreamer-0.10
---------------
PATH:
C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\;C:\Users\remi\Desktop\pymt-0.5-
w32\pymt-0.5-w32\Python;C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\gstreame
r\bin;C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\MinGW\bin;C:\Program Files
\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\
Microsoft Shared\Windows Live;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Co
mmon;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32
\WindowsPowerShell\v1.0\;C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-St
atic;C:\Program Files\jEdit;C:\Python26;C:\MinGW\bin;C:\Program Files\TortoiseSV
N\bin;C:\Program Files (x86)\QuickTime\QTSystem\;C:\Program Files (x86)\Windows
Live\Shared;C:\Program Files\Satsuki Decoder Pack\Filtres
----------------------------------
PYTHONPATH:
C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt;
----------------------------------
##################################
done bootstraping pymt...have fun!
running "python.exe C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\example
s\apps\videoplayer\video.py"
[INFO ] PyMT v0.5
[INFO ] [Core ] Using accelerate module
[INFO ] [Logger ] Record log in C:\Users\remi/.pymt/logs\pymt_10-0
8-18_6.txt
[INFO ] [No OpenGL_accelerate module loaded] No module named OpenGL
_accelerate
[INFO ] [Unable to load registered array format handler numeric]
Traceback (most recent call last):
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\Python\lib\site-packages
\OpenGL\arrays\formathandler.py", line 44, in loadPlugin
plugin_class = entrypoint.load()
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\Python\lib\site-packages
\OpenGL\plugins.py", line 14, in load
return importByName( self.import_path )
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\Python\lib\site-packages
\OpenGL\plugins.py", line 28, in importByName
module = __import__( ".".join(moduleName), {}, {}, moduleName)
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\Python\lib\site-packages
\OpenGL\arrays\numeric.py", line 15, in <module>
raise ImportError( """No Numeric module present: %s"""%(err))
ImportError: No Numeric module present: No module named Numeric
[INFO ] [Graphx ] Using accelerate graphx module
[INFO ] [Camera ] using <gstreamer> as camera provider
[INFO ] [Text ] using <pygame> as text provider
[INFO ] [Video ] using <gstreamer> as video provider
[WARNING ] [Spelling] Unable to use <enchant> as spellingprovider
[CRITICAL ] [Spelling] Unable to find any valuable Spelling providerat
all!
[INFO ] [OSC ] using <thread> for socket
[INFO ] [Loader ] using <pygame> as thread loader
[INFO ] [Window ] use Pygame as window provider.
[INFO ] [Window ] OpenGL version <4.0.9901 Compatibility Profile C
ontext>
[INFO ] GL Extension GL_EXT_framebuffer_object available
[INFO ] [Base ] Start application main loop
[INFO ] [OSC ] listening for Tuio on 0.0.0.0:3333
[INFO ] [Base ] Leaving application in progress...
Traceback (most recent call last):
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\examples\apps\video
player\video.py", line 13, in <module>
runTouchApp(scat)
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\base.py", line
365, in runTouchApp
pymt_window.mainloop()
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\ui\window\win_
pygame.py", line 191, in mainloop
self._mainloop()
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\ui\window\win_
pygame.py", line 123, in _mainloop
evloop.idle()
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\base.py", line
217, in idle
pymt_window.dispatch_event('on_update')
File "c_accelerate.pyx", line 36, in pymt.c_ext.c_accelerate.eventdispatcher_d
ispatch_event (pymt/c_ext\c_accelerate.c:864)
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\ui\window\__in
it__.py", line 345, in on_update
w.dispatch_event('on_update')
File "c_accelerate.pyx", line 36, in pymt.c_ext.c_accelerate.eventdispatcher_d
ispatch_event (pymt/c_ext\c_accelerate.c:864)
File "c_accelerate.pyx", line 51, in pymt.c_ext.c_accelerate.widget_on_update
(pymt/c_ext\c_accelerate.c:1080)
File "c_accelerate.pyx", line 36, in pymt.c_ext.c_accelerate.eventdispatcher_d
ispatch_event (pymt/c_ext\c_accelerate.c:864)
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\ui\widgets\com
posed\video.py", line 144, in on_update
super(MTVideo, self).on_update()
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\ui\widgets\com
posed\video.py", line 62, in on_update
self.player.update()
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\core\video\vid
eo_gstreamer.py", line 221, in update
self._really_load()
File "C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\pymt\pymt\core\video\vid
eo_gstreamer.py", line 140, in _really_load
self._videosink = gst.element_factory_make('appsink', 'videosink')
gst.ElementNotFoundError: appsink
Aug 18, 2010
(No comment was entered for this change.)
Status:
Accepted
Labels: Milestone-0.5.1 Component-Package-Windows
Aug 19, 2010
(No comment was entered for this change.)
Status:
Started
Owner: thomas.hansen
Aug 19, 2010
i can't seem to reproduce the problem on my windows 7 machine. If possible can I get you to run the following script and paste the contents of the 'gst-debug.txt' file it generates?
Save the following as a py file and run it using pymt the same way you tried to run the video.py file:
import subprocess, traceback
try:
debug_output = subprocess.Popen('gst-inspect-0.10.exe', stdout=subprocess.PIPE)
except Exception as e:
debug_output = traceback.format_exc()
debug_file = open('gst-debug.txt', 'w')
debug_file.write(debug_output)
Aug 19, 2010
corrected debug script :
import subprocess, traceback
try:
debug_output = subprocess.Popen('gst-inspect-0.10.exe', stdout=subprocess.PIPE).communicate()[0]
print debug_output
except Exception as e:
debug_output = traceback.format_exc()
debug_file = open('gst-debug.txt', 'w')
debug_file.write(debug_output)
please find the output attached
Aug 19, 2010
Thanks for the correction, I had hit undo one too many times before posting, after trying soemthign else :P Not quite sure whats going on yet, but getting closer to finding out i guess. I'm about to test on a clean windows 7 install. I'm attaching output on my main dev machine for reference. indeed, your output does not list app (neither appSink or appSrc)...it also is missing some other ones that are listed on mine. Maybe you can unzip the gstreamer directory again from the portable package and make sure all the files got extracted ok?! It seems to find the gstreamer bin's and plugins fine from the PATH's that are set... How are you starting the app/script (command line/drag&drop,...)? not that i think it shuold make a difference
Aug 19, 2010
Can you try changing the line in the debug script to:
debug_output = subprocess.Popen('gst-inspect-0.10.exe app', stdout=subprocess.PIPE).communicate()[0]
this gives me the following output:
Plugin Details:
Name: app
Description: Elements used to communicate with applications
Filename: C:\Users\tehansen\Desktop\pymt-0.5-w32\pymt-0.5-w32\gstreamer\lib\gstreamer-0.10\libgstappplugin.dll
Version: 0.10.25
License: LGPL
Source module: gst-plugins-base
Binary package: GStreamer Base Plug-ins source release
Origin URL: Unknown package origin
appsink: AppSink
appsrc: AppSrc
2 features:
+-- 2 elements
Aug 19, 2010
Plugin Details: Name: app Description: Elements used to communicate with applications Filename: C:\Users\remi\Desktop\pymt-0.5-w32\pymt-0.5-w32\gstreame r\lib\gstreamer-0.10\libgstappplugin.dll Version: 0.10.25 License: LGPL Source module: gst-plugins-base Binary package: GStreamer Base Plug-ins source release Origin URL: Unknown package origin 0 features: same with drag & drop or open with...
Aug 19, 2010
Fixed by deleting C:\Users\remi\.gstreamer-0.10, which had old registry info for gst. Not sure if we shuld automatically kill this..that seems not very nice to do..maybe print suggestion on error when there is gstreamer exception like this. will look into nice way to handle this error...
Status:
Fixed
Aug 19, 2010
Environment Variables GST_REGISTRY Path of the registry file. Default is ~/.gstreamer-0.10/registry-i686.xml. |