Giter Site home page Giter Site logo

pyffmpeg's People

Watchers

 avatar

pyffmpeg's Issues

Can't build on OS X 10.5.2

What steps will reproduce the problem?
1. python setup.py build

What is the expected output? What do you see instead?
It doesn't build; I get the following error from distutils:
distutils.errors.DistutilsPlatformError: $MACOSX_DEPLOYMENT_TARGET mismatch: 
now "10.3" but 
"10.5" during configure

What version of the product are you using? On what operating system?
Mac OS X 10.5.2

Original issue reported on code.google.com by peterp%[email protected] on 22 Apr 2008 at 7:39

Source available?

Are you able to post the source for this -- ffmpeg is cross-platform and
I'd like to try pyffmpeg on *nix etc.


Original issue reported on code.google.com by [email protected] on 28 Mar 2008 at 11:41

Can not install pyffmeg under ASrch Linux

What steps will reproduce the problem?
1. pythons setup.py build

What is the expected output? What do you see instead?
I see traceback with error

What version of the product are you using? On what operating system?
pyffmpeg-1.9.0beta, Arch Linux

Please provide any additional information below.

Traceback (most recent call last):
  File "setup.py", line 130, in <module>
    **meta_data
  File "/usr/lib/python2.6/distutils/core.py", line 152, in setup
    dist.run_commands()
  File "/usr/lib/python2.6/distutils/dist.py", line 975, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python2.6/distutils/dist.py", line 995, in run_command
    cmd_obj.run()
  File "/usr/lib/python2.6/distutils/command/build_ext.py", line 340, in run
    self.build_extensions()
  File "/usr/lib/python2.6/site-packages/Cython/Distutils/build_ext.py", line 83, in 
build_extensions
    self.build_extension(ext)
  File "/usr/lib/python2.6/distutils/command/build_ext.py", line 524, in build_extension
    libraries=self.get_libraries(ext),
  File "/usr/lib/python2.6/distutils/command/build_ext.py", line 763, in get_libraries
    return ext.libraries + [pythonlib]

Original issue reported on code.google.com by [email protected] on 21 Apr 2010 at 7:55

seek_to_frame with GOP files

Hello,

is it possible to force pyffmpeg to seek to any frame? It seems to me that if  
I use MPEG file (actually MXF with IMX30 essence), I am only able to seek to 
keyframes, or use step() method to step one frame ahead... so for example I 
can't just go one frame back. I've tried to rebuild pyffmpeg with uncommented 
AVSEEK_FLAG_ANY flag in seek_to method, but it didn't help.

Thanks

Martin

Original issue reported on code.google.com by [email protected] on 10 Dec 2010 at 11:55

Fixes and deprecated functions using recent ffmpeg (PATCH)

What steps will reproduce the problem?

1. Compile with recent ffmpeg-svn

What is the expected output? What do you see instead?

Build errors. Memory leaks.

What version of the product are you using? On what operating system?

Windows/MinGW.

Please provide any additional information below.

I was able to use recent ffmpeg rev13712 using the patch attached.

Original issue reported on code.google.com by [email protected] on 7 Aug 2008 at 2:09

Attachments:

setup.py fails with cython 0.14

What steps will reproduce the problem?
1. install cython 0.14 and other prerequisites
2. exec setup.py build

What is the expected output? What do you see instead?
python setup.py build
running build
running build_ext
cythoning pyffmpeg.pyx to pyffmpeg.c
Traceback (most recent call last):
...
KeyError: 'T'

What version of the product are you using? On what operating system?
pyffmpeg 2.0 with cython 0.14

Please provide any additional information below.
According to the cython mailing list the KeyError may occur if the deprecated 
__new__ method is used.
(Source: http://codespeak.net/pipermail/cython-dev/2010-December/010418.html)

Replacing all "def __new__(...)" with "def __cinit(...)" in pyffmpeg.pyx fixes 
the problem (see the attached patch file made for pyffmpeg 2.0)



Original issue reported on code.google.com by [email protected] on 24 Jan 2011 at 9:53

Attachments:

Forgot about numpy import result on line 87

What steps will reproduce the problem?
setup.py build

What version of the product are you using? On what operating system?
0.2.0 newversion_beta, MacOSX 10.6.4

Please provide any additional information below.
At the beginning of the setup.py you made a check on NumPy, but on line 87:
"incdir = [ path_join(ffmpegpath, 'include'), "/usr/include/ffmpeg" , 
"./include" ] + nd.get_numpy_include_dirs()"
you use "nd" whatever import was

Original issue reported on code.google.com by [email protected] on 7 Aug 2010 at 2:57

build error on Ubuntu 10.04 64bit ?

What steps will reproduce the problem?
1.download source
2.run python setup.py build
3.

What is the expected output? What do you see instead?
compiler quits with error

What version of the product are you using? On what operating system?
pyffmpeg-2.0, under ubuntu 10.04 64bit, cython 0.12.1, python 2.6.5

Please provide any additional information below.
end of error logs follows:

pyffmpeg.c: In function 
‘__pyx_pf_8pyffmpeg_12FFMpegReader___finalize_open_write’:
pyffmpeg.c:12126: warning: assignment makes pointer from integer without a cast
pyffmpeg.c:12139: error: dereferencing pointer to incomplete type
pyffmpeg.c:12148: error: dereferencing pointer to incomplete type
pyffmpeg.c:12171: error: dereferencing pointer to incomplete type
pyffmpeg.c:12171: error: dereferencing pointer to incomplete type
pyffmpeg.c:12188: error: dereferencing pointer to incomplete type
pyffmpeg.c: In function ‘__pyx_pf_8pyffmpeg_12FFMpegReader___finalize_open’:
pyffmpeg.c:12335: warning: implicit declaration of function 
‘av_find_stream_info’
pyffmpeg.c:12506: error: dereferencing pointer to incomplete type
pyffmpeg.c:12517: error: dereferencing pointer to incomplete type
pyffmpeg.c:12611: error: dereferencing pointer to incomplete type
pyffmpeg.c:12632: error: dereferencing pointer to incomplete type
pyffmpeg.c:12693: error: dereferencing pointer to incomplete type
pyffmpeg.c:12704: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in this 
function)
pyffmpeg.c:12880: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in this 
function)
pyffmpeg.c: In function 
‘__pyx_f_8pyffmpeg_12FFMpegReader___prefetch_packet’:
pyffmpeg.c:13650: warning: implicit declaration of function ‘av_read_frame’
pyffmpeg.c: In function 
‘__pyx_pf_8pyffmpeg_12FFMpegReader_process_current_packet’:
pyffmpeg.c:14096: error: dereferencing pointer to incomplete type
pyffmpeg.c:14106: error: dereferencing pointer to incomplete type
pyffmpeg.c:14106: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in this 
function)
pyffmpeg.c:14154: error: dereferencing pointer to incomplete type
pyffmpeg.c:14154: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in this 
function)
pyffmpeg.c: In function 
‘__pyx_pf_8pyffmpeg_12FFMpegReader_read_until_next_frame’:
pyffmpeg.c:14772: error: dereferencing pointer to incomplete type
pyffmpeg.c: In function ‘__pyx_pf_8pyffmpeg_12FFMpegReader_seek_to’:
pyffmpeg.c:15318: warning: implicit declaration of function ‘av_seek_frame’
pyffmpeg.c:15318: error: ‘AVSEEK_FLAG_BACKWARD’ undeclared (first use in 
this function)
pyffmpeg.c: In function ‘__pyx_pf_8pyffmpeg_12FFMpegReader_seek_bytes’:
pyffmpeg.c:15973: error: ‘AVSEEK_FLAG_BACKWARD’ undeclared (first use in 
this function)
pyffmpeg.c:15973: error: ‘AVSEEK_FLAG_BYTE’ undeclared (first use in this 
function)
pyffmpeg.c:16034: error: dereferencing pointer to incomplete type
pyffmpeg.c:16034: error: dereferencing pointer to incomplete type
pyffmpeg.c: In function ‘__pyx_pf_8pyffmpeg_12FFMpegReader___getitem__’:
pyffmpeg.c:16239: error: ‘AV_TIME_BASE’ undeclared (first use in this 
function)
pyffmpeg.c: In function ‘__pyx_pf_8pyffmpeg_12FFMpegReader_duration’:
pyffmpeg.c:16724: error: dereferencing pointer to incomplete type
pyffmpeg.c:16748: error: dereferencing pointer to incomplete type
pyffmpeg.c: In function ‘__pyx_pf_8pyffmpeg_12FFMpegReader_duration_time’:
pyffmpeg.c:16799: error: ‘AV_TIME_BASE’ undeclared (first use in this 
function)
pyffmpeg.c: In function ‘initpyffmpeg’:
pyffmpeg.c:19897: error: ‘AV_TIME_BASE’ undeclared (first use in this 
function)
pyffmpeg.c:20000: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in this 
function)
pyffmpeg.c:20017: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in this 
function)
error: Command "gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fPIC -I/opt/ffmpeg/include -I/usr/include/ffmpeg 
-I./include -I/usr/lib/python2.6/dist-packages/numpy/core/include 
-I/usr/include/python2.6 -c pyffmpeg.c -o 
build/temp.linux-x86_64-2.6/pyffmpeg.o" failed with exit status 1

Original issue reported on code.google.com by [email protected] on 18 Jul 2010 at 2:19

pyffmpeg can't open some H.264 files

What steps will reproduce the problem?
1. Install a recent version of ffmpeg and make sure it can load the file / make 
sure pyffmpeg is built using that version of ffmpeg
2.
        arg1 = <path to the file>
        arg2 = {}
        arg2['video1'] = (0, -1, {} )
        arg2['video1'][2]['dest_height'] = -1
        arg2['video1'][2]['dest_width'] = -1
        arg2['video1'][2]['outputmode'] = pyffmpeg.OUTPUTMODE_NUMPY
        reader.open(arg1 , arg2)

What is the expected output? What do you see instead?

Here's the backtrace:
File "pyffmpeg.pyx", line 1686, in pyffmpeg.FFMpegReader.open (pyffmpeg.c:10777)
  File "pyffmpeg.pyx", line 1738, in pyffmpeg.FFMpegReader.__finalize_open (pyffmpeg.c:11353)
  File "pyffmpeg.pyx", line 1271, in pyffmpeg.VideoTrack.init (pyffmpeg.c:6410)
  File "pyffmpeg.pyx", line 845, in pyffmpeg.Track.init (pyffmpeg.c:2834)
IOError: Unable to get decoder


What version of the product are you using? On what operating system?

happens in both beta and stable. the backtrace i provided is from beta.

Please provide any additional information below.

A file that causes the problem is attached

Original issue reported on code.google.com by [email protected] on 14 Jul 2010 at 8:35

Attachments:

ImportError: DLL load failed: The specified procedure could not be found.

What steps will reproduce the problem?
1. import pyffmpeg in python 2.6

What is the expected output? What do you see instead?
I expect that pyffmpeg is imported without any errors, but instead i get this 
error: 

Traceback (most recent call last):
  File "<pyshell#1>", line 1, in <module>
    import pyffmpeg
ImportError: DLL load failed: The specified procedure could not be found.

What version of the product are you using? On what operating system?

I use pyffmpeg 2.1 on Windows XP 32 bit, with Python 2.6.6 , ffmpeg shared 
build from this site: http://ffmpeg.zeranoe.com/builds/
I installed the 2011-09-06 build. Installed MingW with msys to. 

Please provide any additional information below.

I added the directories: C:\ffmpeg\bin, C:\MinGW\bin, C:\MinGW\msys\1.0\bin to 
the system path

copied the files from the pyffmpeg zip file to the directory 
C:\Python26\Lib\site-packages

copied the files : avcodec-53.dll, avdevice-53.dll, avfilter-2.dll, 
avformat-53.dll, avutil-51.dll, postproc-51.dll, swscale-2.dll from the 
directory C:\ffmpeg\bin to C:\WINDOWS\system32

and copied libgcc_s_dw2-1.dll from C:\MinGW\bin to C:\WINDOWS\system32

I already examined issue 31, bt it didn't help for me. 

Thanks in advance, 

Dennis


Original issue reported on code.google.com by [email protected] on 15 Sep 2011 at 9:24

Cannot build pyffmpeg

What steps will reproduce the problem?
1. svn checkout http://pyffmpeg.googlecode.com/svn/trunk/ pyffmpeg
2. python setup.py install --prefix=$HOME/local
3.

What is the expected output? 

What do you see instead?
/home/nwagner/local/lib64/python2.6/site-packages/Pyrex/Compiler/Errors.py:17:
DeprecationWarning: BaseException.message has been deprecated as of Python
2.6                                                                       

  self.message = message                                                  

running install                                                           

running build                                                             

running build_ext                                                         

pyrexc pyffmpeg.pyx --> pyffmpeg.c                                        

/home/nwagner/local/lib64/python2.6/site-packages/Pyrex/Compiler/Scanning.py:39:
DeprecationWarning: the md5 module is deprecated; use hashlib instead     


  import md5                                                              

building 'pyffmpeg' extension                                             

creating build                                                            

creating build/temp.linux-x86_64-2.6                                      

/usr/bin/gcc -fno-strict-aliasing -DNDEBUG -fmessage-length=0 -O2 -Wall
-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables
-fasynchronous-unwind-tables -g -fwrapv -fPIC -I/usr/include/libavcodec/
-I/usr/include/libavformat -I/usr/include/libavutil
-I/usr/include/libswscale -I/usr/include/python2.6 -c pyffmpeg.c -o
build/temp.linux-x86_64-2.6/pyffmpeg.o                  
pyffmpeg.c:30:25: error: mathematics.h: Datei oder Verzeichnis nicht
gefunden                                                
pyffmpeg.c:31:20: error: avutil.h: Datei oder Verzeichnis nicht gefunden  

pyffmpeg.c:32:21: error: swscale.h: Datei oder Verzeichnis nicht gefunden 

pyffmpeg.c:33:21: error: avcodec.h: Datei oder Verzeichnis nicht gefunden 

pyffmpeg.c:34:22: error: avformat.h: Datei oder Verzeichnis nicht gefunden

pyffmpeg.c:35:18: error: avio.h: Datei oder Verzeichnis nicht gefunden    

pyffmpeg.c:83: error: field ‘packet’ has incomplete type                  

pyffmpeg.c:94: warning: ‘struct AVPicture’ declared inside parameter list 

pyffmpeg.c:94: warning: its scope is only this definition or declaration,
which is probably not what you want                
pyffmpeg.c:95: warning: ‘struct AVPicture’ declared inside parameter list 

pyffmpeg.c: In function ‘__pyx_f_8pyffmpeg_8pyffmpeg_py_av_register_all’: 

pyffmpeg.c:267: warning: implicit declaration of function ‘av_register_all’

pyffmpeg.c: In function
‘__pyx_f_8pyffmpeg_8pyffmpeg_11VideoStream___cinit__’:                    

pyffmpeg.c:291: warning: implicit declaration of function
‘avcodec_alloc_frame’                                              
pyffmpeg.c:291: warning: assignment makes pointer from integer without a
cast                                                
pyffmpeg.c: In function ‘__pyx_f_8pyffmpeg_8pyffmpeg_11VideoStream_dump’: 

pyffmpeg.c:330: warning: implicit declaration of function ‘dump_format’   

pyffmpeg.c: In function ‘__pyx_f_8pyffmpeg_8pyffmpeg_11VideoStream_open’: 

pyffmpeg.c:364: warning: implicit declaration of function
‘av_open_input_file’                                               
pyffmpeg.c:388: warning: implicit declaration of function
‘av_find_stream_info’                                              
pyffmpeg.c:412: error: dereferencing pointer to incomplete type           

pyffmpeg.c:414: error: dereferencing pointer to incomplete type           

pyffmpeg.c:414: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in this
function)                                            
pyffmpeg.c:414: error: (Each undeclared identifier is reported only once  

pyffmpeg.c:414: error: for each function it appears in.)                  

pyffmpeg.c:444: error: dereferencing pointer to incomplete type           

pyffmpeg.c:447: warning: implicit declaration of function
‘avcodec_find_decoder’                                             
pyffmpeg.c:447: error: dereferencing pointer to incomplete type           

pyffmpeg.c:447: warning: assignment makes pointer from integer without a
cast                                                
pyffmpeg.c:465: error: dereferencing pointer to incomplete type           

pyffmpeg.c:465: error: ‘CODEC_CAP_TRUNCATED’ undeclared (first use in this
function)                                         
pyffmpeg.c:467: error: dereferencing pointer to incomplete type           

pyffmpeg.c:467: error: dereferencing pointer to incomplete type           

pyffmpeg.c:467: error: ‘CODEC_FLAG_TRUNCATED’ undeclared (first use in this
function)                                        
pyffmpeg.c:473: warning: implicit declaration of function ‘avcodec_open’  

pyffmpeg.c: At top level:                                                 

pyffmpeg.c:508: warning: ‘struct AVPicture’ declared inside parameter list

pyffmpeg.c: In function
‘__pyx_f_8pyffmpeg_8pyffmpeg_11VideoStream_ConvertToRGBA’:                

pyffmpeg.c:523: warning: assignment makes pointer from integer without a
cast                                                
pyffmpeg.c:541: error: dereferencing pointer to incomplete type           

pyffmpeg.c:544: error: dereferencing pointer to incomplete type           

pyffmpeg.c:547: warning: implicit declaration of function
‘avpicture_get_size’                                               
pyffmpeg.c:547: error: ‘PIX_FMT_RGBA32’ undeclared (first use in this
function)                                              
pyffmpeg.c:553: warning: implicit declaration of function ‘avpicture_fill’

pyffmpeg.c:556: warning: implicit declaration of function ‘sws_getContext’

pyffmpeg.c:556: error: dereferencing pointer to incomplete type           

pyffmpeg.c:556: error: ‘SWS_BICUBIC’ undeclared (first use in this
function)                                                 
pyffmpeg.c:556: warning: assignment makes pointer from integer without a
cast                                                

Original issue reported on code.google.com by [email protected] on 17 Sep 2009 at 6:09

sys is not defined

"sys" is not defined in try construction (if except happens)


try:
  import numpy.distutils.misc_util as nd
  with_numpy=True
except:
  with_numpy=False
  sys.stderr.write("Numpy does not seems to be installed on your system.\n")
  sys.stderr.write("You may still use pyffmpeg but audiosupport and numpy-bride are disabled.\n")  

Original issue reported on code.google.com by yanchenko.igor on 12 Mar 2011 at 12:55

The "python-numpy-devel" package is required by "setup.py", but it is not documented

 - What steps will reproduce the problem?

I have a Linux Mageia 1 32 bits.
I have the "python-numpy" package installed,
but not the "python-numpy-devel" package installed.

I tried to run the script "setup.py" and got the message :

"Numpy does not seems to be installed on your system.
You may still use pyffmpeg but audiosupport and numpy-bridge are disabled."

This message is not correct, because "Numpy" is installed. By installing the 
python-numpy-devel" package, the previous message does not appear any more, but 
this is not documented.


 - What is the expected output? What do you see instead?

You should precise :

The "python-numpy-devel" package does not seems to be installed on your system.
You may still use pyffmpeg but audiosupport and numpy-bridge are disabled."


 - What version of the product are you using? On what operating system?
"pyffmpeg-2.1beta.tar.gz"


 - Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 4 May 2012 at 12:42

Mac OSX

dlopen("/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-pac
kages/pyffmpeg.so", 2);
Traceback (most recent call last):
  File "fast_keyframes_extraction.py", line 8, in <module>
    from pyffmpeg import *
ImportError: 
dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-pack
ages/pyffmpeg.so, 2): Symbol not found: _av_close_input_file
  Referenced from: /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/pyffmpeg.so
  Expected in: dynamic lookup


Using Python Version 2.6.5
Cython version 0.13
numpy version 1.5.0
pyffmpeg version 2.0

FFmpeg version SVN-r25083, Copyright (c) 2000-2010 the FFmpeg developers
  built on Sep  9 2010 12:42:43 with gcc 4.2.1 (Apple Inc. build 5664)
  configuration: --disable-static --enable-shared --enable-gpl --enable-nonfree --enable-libmp3lame --enable-libfaac --enable-libx264
  libavutil     50.26. 0 / 50.26. 0
  libavcore      0. 9. 0 /  0. 9. 0
  libavcodec    52.87. 5 / 52.87. 5
  libavformat   52.78. 3 / 52.78. 3
  libavdevice   52. 2. 2 / 52. 2. 2
  libavfilter    1.38. 3 /  1.38. 3
  libswscale     0.11. 0 /  0.11. 0



Full Trace Attached

Original issue reported on code.google.com by [email protected] on 9 Sep 2010 at 5:02

Attachments:

ImportError: DLL load failed: No such module has been found

Hi! I installed PIL 1.7 and extract the files in pyffmpeg-2.1beta.win32.zip to 
relatted directory. But when I open IDLE and type "Import pyffmpeg", I got an 
error that "No such module has been found".

Please tell me what should I do except these above and how to fix this error.

thx:)

Original issue reported on code.google.com by [email protected] on 7 Jul 2011 at 8:03

include_dirs for newer ffmpeg

Newer ffmpeg seems to have .h files split into several directories

What steps will reproduce the problem?
1. install ffmpeg-0.4.9_p20080326
2. try to compile the extension
3. you'll notice following errors

pyffmpeg/pyffmpeg.c:14:25: error: mathematics.h: No such file or directory
pyffmpeg/pyffmpeg.c:15:20: error: avutil.h: No such file or directory
pyffmpeg/pyffmpeg.c:16:21: error: avcodec.h: No such file or directory
pyffmpeg/pyffmpeg.c:17:22: error: avformat.h: No such file or directory
pyffmpeg/pyffmpeg.c:18:18: error: avio.h: No such file or directory


Please provide any additional information below.

Can be fixed by adding additional include dirs into setup.py

            Extension("pyffmpeg", ["pyffmpeg/pyffmpeg.pyx"],
                include_dirs=["/usr/include/ffmpeg",
"/usr/include/libavutil", "/usr/include/libavcodec",
"/usr/include/libavformat"],
                libraries = ["avformat","avcodec"])
            ],

Original issue reported on code.google.com by [email protected] on 16 Jul 2008 at 7:01

Seg fault when interpreter closes

What steps will reproduce the problem?
$ python
Python 2.5.1 (r251:54863, Jun 15 2008, 18:24:56)
[GCC 4.3.0 20080428 (Red Hat 4.3.0-8)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import pyffmpeg
>>> quit()
Segmentation fault (core dumped)


What version of the product are you using? On what operating system?

beta, checked out from svn 2010-07-13 and edited to get it to build 
successfully.

Original issue reported on code.google.com by [email protected] on 14 Jul 2010 at 8:18

pyffmpeg needs to be ported to libswscale

pyffmeg still uses the now deprecated img_convert and needs to be ported to
swscale. not 100% sure how, but it doesn't look like its hugely difficult,
although I have personnally little to no knowledge of python

Original issue reported on code.google.com by [email protected] on 24 Oct 2008 at 1:03

pyffmpeg 2.0 & 2.1 beta under Fedoara 16 with python 2.7.2 - error compiling

What steps will reproduce the problem?
1. use python setup.py install ( under Fedora 16 )
2.
3.

What is the expected output? What do you see instead?
pyffmpeg-2.1beta]$ python setup.py build
running build
running build_ext
cythoning pyffmpeg.pyx to pyffmpeg.c
warning: pyffmpeg.pyx:1905:49: Unreachable code

Error compiling Cython file:
------------------------------------------------------------
...

    cdef AVFormatContext *FormatCtx
 #   self.prepacket=<AVPacket *>None
#   self.packet=&self.packetbufa

    def __new__(self):
   ^
------------------------------------------------------------

pyffmpeg.pyx:808:4: __new__ method of extension type will change semantics in a 
future version of Pyrex and Cython. Use __cinit__ instead.

Error compiling Cython file:
------------------------------------------------------------
...
    cdef object default_audio_track
    cdef object default_video_track
    cdef int with_readahead
    cdef unsigned long long int seek_before_security_interval

    def __new__(self,with_readahead=True,seek_before=4000):
   ^
------------------------------------------------------------

pyffmpeg.pyx:1835:4: __new__ method of extension type will change semantics in 
a future version of Pyrex and Cython. Use __cinit__ instead.

Error compiling Cython file:
------------------------------------------------------------
...
##################################################################



def py_av_register_all():
    if __registered:
                  ^
------------------------------------------------------------

pyffmpeg.pyx:706:19: local variable '__registered' referenced before assignment
building 'pyffmpeg' extension
C compiler: gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall 
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector 
--param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom 
-fasynchronous-unwind-tables -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe 
-Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector 
--param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom 
-fasynchronous-unwind-tables -D_GNU_SOURCE -fPIC -fwrapv -fPIC

compile options: '-I/opt/ffmpeg/include -I/usr/include/ffmpeg -I./include 
-I/usr/lib/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 
-c'
gcc: pyffmpeg.c
pyffmpeg.c:1:2: error: #error Do not use this file, it is the result of a 
failed Cython compilation.
pyffmpeg.c:1:2: error: #error Do not use this file, it is the result of a 
failed Cython compilation.
error: Command "gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall 
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector 
--param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom 
-fasynchronous-unwind-tables -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe 
-Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector 
--param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom 
-fasynchronous-unwind-tables -D_GNU_SOURCE -fPIC -fwrapv -fPIC 
-I/opt/ffmpeg/include -I/usr/include/ffmpeg -I./include 
-I/usr/lib/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 
-c pyffmpeg.c -o build/temp.linux-i686-2.7/pyffmpeg.o" failed with exit status 1


What version of the product are you using? On what operating system?
I try both pyffmpeg 2.0 and 2.1beta

Please provide any additional information below.
I have ffmpeg install and python :
$ python 
Python 2.7.2 (default, Oct 27 2011, 01:36:46) 
[GCC 4.6.1 20111003 (Red Hat 4.6.1-10)] on linux2

Original issue reported on code.google.com by [email protected] on 1 Apr 2012 at 8:19

An error in the usage examples.

on http://code.google.com/p/pyffmpeg/#Usage_Examples :
> ## create the reader object
> mp=FFMpegReader()

That is wrong -- instead, "mp = pyffmpeg.FFMpegReader()" would run correctly.

Original issue reported on code.google.com by [email protected] on 4 Jan 2011 at 3:56

cannot import

What steps will reproduce the problem?
1. install pyffmpeg
2. run script with 'import pyffmpeg'

What is the expected output? 
that it runs

What do you see instead?
ImportError: /usr/local/lib/python2.6/dist-packages/pyffmpeg.so: undefined
symbol: av_reduce


What version of the product are you using? 
latest svn

On what operating system?
Ubuntu 9.04
Python 2.6

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 10 Jan 2010 at 1:07

GetFrameNo : compatibility with previous PyFFMPEG version

Pyffmpeg2 doesn't preserve compatibility with previous PyFFMpeg version :

stream = pyffmpeg.VideoStream()
stream.open('myvideo.avi')
image = stream.GetFrameNo(0)

AttributeError: 'pyffmpegb.FFMpegReader' object has no attribute
'seek_to_frameno'



/usr/lib/python2.5/site-packages/pyffmpegb.so in
pyffmpegb.VideoStream.GetFrameNo (pyffmpegb.c:19911)()
   2131         return self.vr.get_current_frame()
   2132     def GetFrameNo(self, fno):
-> 2133         self.vr.seek_to_frameno(fno)
   2134         return self.vr.get_current_frame()
   2135     def GetCurrentFrame(self, fno):

Original issue reported on code.google.com by [email protected] on 12 Nov 2009 at 1:04

How to install pyffmpeg on Ubuntu 8.04

Since I am not a member of the project - take this with caution:

1) use Synaptic (or apt-get/aptitude) to install the following packages:
ffmpeg, libavcodec-dev, libavformat-dev, libavutil-dev, python-dev,
python-Pyrex

2) verify that /usr/include/ffmpeg was created

3) in "pyffmpeg.pyx", fix line #584 (arguments of function "GetFrameTime"),
namely, change the  var type of "timestep" from type "float" to "int64_t",
so that the function header would be:
    def GetFrameTime(self,int64_t timestamp):

4) if you got here, you should not be editing anything else ... (unlike
other protocols in this project's post) just go to the project folder on
your machine

5) 'python setup.py build' (I got about 6 compilation warnings ...)

6) I use 'checkinstall' as an installation tool but it is not a must:
'sudo checkinstall python setup.py install'

7) enter whatever you wish when asked by checkinstall and there-you-have-it !


Original issue reported on code.google.com by [email protected] on 16 Oct 2008 at 9:38

Trouble installing on mac os

What steps will reproduce the problem?
1.sudo python setup.py install

What is the expected output? What do you see instead?
I expected to be able to install it... instead I get this error message

---
running install
running build
running build_ext
cythoning pyffmpeg.pyx to pyffmpeg.c
building 'pyffmpeg' extension
C compiler: llvm-gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -g -Os -pipe 
-fno-common -fno-strict-aliasing -fwrapv -mno-fused-madd -DENABLE_DTRACE 
-DMACOSX -DNDEBUG -Wall -Wstrict-prototypes -Wshorten-64-to-32 -DNDEBUG -g 
-fwrapv -Os -Wall -Wstrict-prototypes -DENABLE_DTRACE -arch i386 -arch x86_64 
-pipe

compile options: '-I/opt/ffmpeg/include -I/usr/include/ffmpeg -I./include 
-I/Library/Python/2.7/site-packages/numpy-2.0.0.dev_e2af7b7_20110721-py2.7-macos
x-10.7-x86_64.egg/numpy/core/include 
-I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c'
llvm-gcc-4.2: pyffmpeg.c
pyffmpeg.c:1:2: error: #error Do not use this file, it is the result of a 
failed Cython compilation.
pyffmpeg.c:1:2: error: #error Do not use this file, it is the result of a 
failed Cython compilation.
lipo: can't open input file: /var/tmp//cc7If9Mb.out (No such file or directory)
pyffmpeg.c:1:2: error: #error Do not use this file, it is the result of a 
failed Cython compilation.
pyffmpeg.c:1:2: error: #error Do not use this file, it is the result of a 
failed Cython compilation.
lipo: can't open input file: /var/tmp//cc7If9Mb.out (No such file or directory)

---

What version of the product are you using? On what operating system?
I'm using OS X 10.7.2, python 2.7.1, Cython 0.15.1, that's about it. I've tried 
both pyffmpeg2.1 and 2.0, to no avail. Any help would be greatly welcome!


Original issue reported on code.google.com by [email protected] on 19 Oct 2011 at 2:56

Error: "undefined reference to `floorf' " during the compilation

 - What steps will reproduce the problem?

The software compilation with the following command:
python ./setup.py build

I got the following error:
Error: undefined reference to `floorf'

Full output:
gcc -pthread -shared -Wl,--as-needed -Wl,--no-undefined -Wl,-z,relro -Wl,-O1 
-Wl,--build-id -Wl,--enable-new-dtags build/temp.linux-i686-2.7/pyffmpeg.o 
-L/opt/ffmpeg/lib -L/usr/lib -lavformat -lavcodec -lavutil -lswscale 
-lpython2.7 -o build/lib.linux-i686-2.7/pyffmpeg.so
build/temp.linux-i686-2.7/pyffmpeg.o: In function 
`__pyx_pf_8pyffmpeg_10AudioTrack_1reset_tps':
/home/varenne/jmvp/aa/pyffmpeg-2.1beta/pyffmpeg.c:5193: undefined reference to 
`floorf'
build/temp.linux-i686-2.7/pyffmpeg.o: In function 
`__pyx_pf_8pyffmpeg_10AudioTrack_init':
/home/varenne/jmvp/aa/pyffmpeg-2.1beta/pyffmpeg.c:4910: undefined reference to 
`floorf'
collect2: ld a retourné 1 code d'état d'exécution
build/temp.linux-i686-2.7/pyffmpeg.o: In function 
`__pyx_pf_8pyffmpeg_10AudioTrack_1reset_tps':
/home/varenne/jmvp/aa/pyffmpeg-2.1beta/pyffmpeg.c:5193: undefined reference to 
`floorf'
build/temp.linux-i686-2.7/pyffmpeg.o: In function 
`__pyx_pf_8pyffmpeg_10AudioTrack_init':
/home/varenne/jmvp/aa/pyffmpeg-2.1beta/pyffmpeg.c:4910: undefined reference to 
`floorf'
collect2: ld a retourné 1 code d'état d'exécution
error: Command "gcc -pthread -shared -Wl,--as-needed -Wl,--no-undefined 
-Wl,-z,relro -Wl,-O1 -Wl,--build-id -Wl,--enable-new-dtags 
build/temp.linux-i686-2.7/pyffmpeg.o -L/opt/ffmpeg/lib -L/usr/lib -lavformat 
-lavcodec -lavutil -lswscale -lpython2.7 -o 
build/lib.linux-i686-2.7/pyffmpeg.so" failed with exit status 1



 - What is the expected output? What do you see instead?

After investigation on Internet, it appears that the "floorf" symbol is defined 
in a "libm.so" library. Then, the "-lm" argument shall be added to the "gcc" 
command. To fix it, you can add the following lines in the "setup.py" file:

if platform.startswith("linux"):
    libs += [ 'm' ]



 - What version of the product are you using? On what operating system?

"pyffmpeg-2.1beta.tar.gz"
"Linux Mageia 1" 32 bits


 - Please provide any additional information below.

Original issue reported on code.google.com by [email protected] on 4 May 2012 at 3:23

Import Erorr: No module found pyffmpeg

What steps will reproduce the problem?
1.pyffmpeg cannot be imported
2.
3.

What is the expected output? What do you see instead?
The expected output are the images from video.

What version of the product are you using? On what operating system?
 Python 2.6.5 Ubuntu 10.04

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 30 Mar 2011 at 5:42

seek_to_frame not working on long .mp4 files

This is a chunk of code that's a good example of the kinds of problems I'm 
having. "SD010008.mp4" is over an hour long and hads 60 frames per second.

IDLE 2.6.5      ==== No Subprocess ====
>>> import pyffmpeg
>>> mp = pyffmpeg.FFMpegReader()
>>> mp.open("SD010008.mp4",pyffmpeg.TS_VIDEO)
result PTS:33367
start time checked : pts = 33367 , declared was : 4505
result PTS:33367
>>> vt=mp.get_tracks()[0]
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> image = vt.get_next_frame()
>>> vt.get_current_frame_frameno()
14
>>> vt.seek_to_frame(0)
result PTS:33367
>>> vt.get_current_frame_frameno()
16
>>> vt.seek_to_frame(0)
result PTS:33367
>>> vt.get_current_frame_frameno()
18
>>> vt.seek_to_frame(1)
result PTS:116789
>>> vt.get_current_frame_frameno()
21
>>> vt.seek_to_frame(1*60*60*60)
result PTS:3603650056
>>> vt.get_current_frame_frameno()
84
>>> 

I am running Windows 7, Python 2.6.5, pyffmpeg-2.1beta.win32.zip 

I was really hoping for a way to get back to the beginning of the file, and a 
way to jump forward five or 10 frames that's better than calling 
get_next_frame() repeatedly. When I noticed that seek_to_frame was not really 
working at all.

Original issue reported on code.google.com by [email protected] on 15 Apr 2011 at 2:36

Type mismatch for GetFrameTime

What steps will reproduce the problem?
1. pyrex 0.9.6.4
2. checkout trunk at revision 5
3. fix pyffmpeg.pyx path in setup.py
4. pythons setup.py build_ext

What is the expected output? What do you see instead?

Pyrex compilation fails with the following error:
pyffmpeg.pyx:586:24: Cannot assign type 'float' to 'pyffmpeg.int64_t'

What version of the product are you using? On what operating system?

Trunk at revision 5, ubuntu 8.04

Please provide any additional information below.

I've managed to compile pyffmpeg with the attached patch.

Original issue reported on code.google.com by [email protected] on 22 Jul 2008 at 9:14

Attachments:

Build on Ubuntu 11.04, python 2.7 AMD fails

Python Beta 2.1 error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’


pyffmpeg.c: In function ‘__pyx_pf_8pyffmpeg_5Track_init’:
pyffmpeg.c:3030:65: error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’

ubuntu 11.04, python2.7
Build fails first error is one listed above.
Complete trace below

sudo python setup.py build
running build
running build_ext
building 'pyffmpeg' extension

running build
running build_ext
building 'pyffmpeg' extension
C compiler: gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fPIC

compile options: '-I/opt/ffmpeg/include -I/usr/include/ffmpeg -I./include 
-I/usr/lib/pymodules/python2.7/numpy/core/include -I/usr/include/python2.7 -c'
gcc: pyffmpeg.c
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_5Track_init’:
pyffmpeg.c:3030:65: error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_10VideoTrack_set_hurry’:
pyffmpeg.c:9571:81: error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’
pyffmpeg.c:9610:81: error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’
pyffmpeg.c: In function ‘pyx_f_8pyffmpeg_10VideoTrackconvert_to’:
pyffmpeg.c:9776:3: warning: passing argument 2 of ‘sws_scale’ from 
incompatible pointer type
/usr/local/include/libswscale/swscale.h:223:5: note: expected ‘const uint8_t 
* const*’ but argument is of type ‘uint8_t **’
pyffmpeg.c: In function ‘pyx_f_8pyffmpeg_10VideoTrackconvert_withbuf’:
pyffmpeg.c:9954:3: warning: passing argument 2 of ‘sws_scale’ from 
incompatible pointer type
/usr/local/include/libswscale/swscale.h:223:5: note: expected ‘const uint8_t 
* const*’ but argument is of type ‘uint8_t **’
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_dump’:
pyffmpeg.c:10993:3: warning: ‘dump_format’ is deprecated (declared at 
/usr/local/include/libavformat/avformat.h:1399)
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_open’:
pyffmpeg.c:11200:14: warning: implicit declaration of function 
‘guess_format’
pyffmpeg.c:11200:94: warning: assignment makes pointer from integer without a 
cast
pyffmpeg.c:11283:5: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c:11343:7: warning: ‘url_setbufsize’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:287)
pyffmpeg.c:11429:7: warning: ‘get_buffer’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:242)
pyffmpeg.c:11453:7: warning: ‘url_fseek’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:281)
pyffmpeg.c:11463:9: warning: ‘url_fclose’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:280)
pyffmpeg.c:11472:9: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c:11675:5: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c: In function 
‘pyx_pf_8pyffmpeg_12FFMpegReader_finalize_open_write’:
pyffmpeg.c:11798:23: warning: assignment makes pointer from integer without a 
cast
pyffmpeg.c:11847:3: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_finalize_open’:
pyffmpeg.c:12359:32: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in 
this function)
pyffmpeg.c:12359:32: note: each undeclared identifier is reported only once for 
each function it appears in
pyffmpeg.c:12535:32: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in 
this function)
pyffmpeg.c: In function 
‘pyx_pf_8pyffmpeg_12FFMpegReader_process_current_packet’:
pyffmpeg.c:13720:56: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in 
this function)
pyffmpeg.c:13764:56: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in 
this function)
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_seek_bytes’:
pyffmpeg.c:15607:5: warning: ‘url_fseek’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:281)
pyffmpeg.c: In function ‘initpyffmpeg’:
pyffmpeg.c:19594:30: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in 
this function)
pyffmpeg.c:19611:30: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in 
this function)
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_5Track_init’:
pyffmpeg.c:3030:65: error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_10VideoTrack_set_hurry’:
pyffmpeg.c:9571:81: error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’
pyffmpeg.c:9610:81: error: ‘struct AVCodecContext’ has no member named 
‘hurry_up’
pyffmpeg.c: In function ‘pyx_f_8pyffmpeg_10VideoTrackconvert_to’:
pyffmpeg.c:9776:3: warning: passing argument 2 of ‘sws_scale’ from 
incompatible pointer type
/usr/local/include/libswscale/swscale.h:223:5: note: expected ‘const uint8_t 
* const*’ but argument is of type ‘uint8_t **’
pyffmpeg.c: In function ‘pyx_f_8pyffmpeg_10VideoTrackconvert_withbuf’:
pyffmpeg.c:9954:3: warning: passing argument 2 of ‘sws_scale’ from 
incompatible pointer type
/usr/local/include/libswscale/swscale.h:223:5: note: expected ‘const uint8_t 
* const*’ but argument is of type ‘uint8_t **’
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_dump’:
pyffmpeg.c:10993:3: warning: ‘dump_format’ is deprecated (declared at 
/usr/local/include/libavformat/avformat.h:1399)
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_open’:
pyffmpeg.c:11200:14: warning: implicit declaration of function 
‘guess_format’
pyffmpeg.c:11200:94: warning: assignment makes pointer from integer without a 
cast
pyffmpeg.c:11283:5: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c:11343:7: warning: ‘url_setbufsize’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:287)
pyffmpeg.c:11429:7: warning: ‘get_buffer’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:242)
pyffmpeg.c:11453:7: warning: ‘url_fseek’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:281)
pyffmpeg.c:11463:9: warning: ‘url_fclose’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:280)
pyffmpeg.c:11472:9: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c:11675:5: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c: In function 
‘pyx_pf_8pyffmpeg_12FFMpegReader_finalize_open_write’:
pyffmpeg.c:11798:23: warning: assignment makes pointer from integer without a 
cast
pyffmpeg.c:11847:3: warning: ‘url_fopen’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:279)
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_finalize_open’:
pyffmpeg.c:12359:32: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in 
this function)
pyffmpeg.c:12359:32: note: each undeclared identifier is reported only once for 
each function it appears in
pyffmpeg.c:12535:32: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in 
this function)
pyffmpeg.c: In function 
‘pyx_pf_8pyffmpeg_12FFMpegReader_process_current_packet’:
pyffmpeg.c:13720:56: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in 
this function)
pyffmpeg.c:13764:56: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in 
this function)
pyffmpeg.c: In function ‘pyx_pf_8pyffmpeg_12FFMpegReader_seek_bytes’:
pyffmpeg.c:15607:5: warning: ‘url_fseek’ is deprecated (declared at 
/usr/local/include/libavformat/avio.h:281)
pyffmpeg.c: In function ‘initpyffmpeg’:
pyffmpeg.c:19594:30: error: ‘CODEC_TYPE_VIDEO’ undeclared (first use in 
this function)
pyffmpeg.c:19611:30: error: ‘CODEC_TYPE_AUDIO’ undeclared (first use in 
this function)
error: Command "gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fPIC -I/opt/ffmpeg/include -I/usr/include/ffmpeg 
-I./include -I/usr/lib/pymodules/python2.7/numpy/core/include 
-I/usr/include/python2.7 -c pyffmpeg.c -o 
build/temp.linux-x86_64-2.7/pyffmpeg.o" failed with exit status 1

Original issue reported on code.google.com by [email protected] on 25 May 2011 at 3:17

Out of memory crash

What steps will reproduce the problem?
1.Run this code (with a video with enough frames):
import pyffmpeg

stream = pyffmpeg.VideoStream()
stream.open('movie.avi')
for i in xrange(0,752):
    stream.GetFrameNo(i).save('ddr' + str(i) + '.jpg')

What is the expected output? What do you see instead?
All the frames captured as jpg.
Python runs out of memory.

What version of the product are you using? On what operating system?
0.2.1 Windows

Please provide any additional information below.
The garbage collector isn't working for some reason.

Original issue reported on code.google.com by [email protected] on 16 May 2010 at 2:49

get_next_frame() not in sync with video file

*** What steps will reproduce the problem?

======================

from pyffmpeg import *

from PIL import Image

def openVideoTest():
    #300 frames "Stefan" sequence
    # this is correctly recognized by ffmpeg 
    filename = "stefan_IP_h264jm16_2_qp30.mp4"
    TS_VIDEO_PIL={ 'video1':(CodecTypes.CODEC_TYPE_VIDEO, -1, {'outputmode':OUTPUTMODE_PIL})}

    mp=FFMpegReader()
    mp.open(filename,TS_VIDEO_PIL)

    vt=mp.get_tracks()[0]    # video track

    currFps = vt.get_fps()
    lastPts = 0
    diffPts = int(1/currFps*1e6)

    #vidim = vt.get_next_frame()
    #vidim = vt.get_next_frame()
    #vidim = vt.get_next_frame()
    for k in xrange(0,300):
        vidim = vt.get_next_frame()
        currPts = vt.get_cur_pts()
        print k, vt.get_current_frame_frameno(), currPts, "(", currPts-lastPts,")", vt.get_current_frame_pict_type()
        lastPts = currPts 

if __name__ == "__main__":
    openVideoTest()

======================

*** What is the expected output? What do you see instead?

get_next_frame() should return frame 1, 2, 3, 4, 5, 6 ... but instead 
get_next_frame() returns frame 1, 1, 1, 1, 2, 3, ...

Use the code below to reproduce the problem of missing synchronization for 
get_next_frame(). The attached video file is the Stefan sequence encoded with 
the reference codec for a QP of 30 with IPP..., so there is only one I frame at 
the beginning. get_next_frame() returns 3 or 4 frames with identical content of 
the first I frame. As the sequence has 300 frames, it should be possible to 
decode these 300 frames. Unfortunately, this is not possible and the decoding 
stops some frames before the end. 

*** What version of the product are you using? On what operating system?

Tried GIT check out from https://github.com/tranx/pyffmpeg.git and 
pyffmpeg-2.1beta.tar.gz (GIT, SVN and ZIP with different versions is quite 
confusing, so which repository is up-to-date?) 
Mac OS X
Python 2.6.6 (r266:84292, Jan  6 2011, 11:51:09) 
GCC 4.2.1 (Apple Inc. build 5664)

*** Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 9 Mar 2011 at 9:33

Attachments:

The "libffmpeg-devel" package is required during the compilation, but it is not documented

 - What steps will reproduce the problem?

I tried to compile the software with the following command:
python ./setup.py build

But I got an error message which says that the "libavutil/mathematics.h" file 
is missing.

After investigation, it appears that this file is in a "libffmpeg-devel" 
package. After installing it, it solved the problem.


 - What is the expected output? What do you see instead?

The list of requirements to compile the software should be written in a
"readme.txt" file given in the ".tar.gz" archive. Moreover, each one shall 
precise the version that can allow the compilation.


 - What version of the product are you using? On what operating system?

"Linux Mageia 1" 32 bits
"pyffmpeg-2.1beta.tar.gz"


 - Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 4 May 2012 at 2:17

Installation with python 2.7

Here a problem:

Traceback (most recent call last):
  File "setup.py", line 130, in <module>
    **meta_data
  File "/usr/lib/python2.7/distutils/core.py", line 152, in setup
    dist.run_commands()
  File "/usr/lib/python2.7/distutils/dist.py", line 953, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "/usr/lib/python2.7/distutils/command/install.py", line 563, in run
    self.run_command('build')
  File "/usr/lib/python2.7/distutils/cmd.py", line 326, in run_command
    self.distribution.run_command(command)
  File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "/usr/lib/python2.7/distutils/command/build.py", line 127, in run
    self.run_command(cmd_name)
  File "/usr/lib/python2.7/distutils/cmd.py", line 326, in run_command
    self.distribution.run_command(command)
  File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "/usr/lib/python2.7/distutils/command/build_ext.py", line 340, in run
    self.build_extensions()
  File "/usr/lib/python2.7/site-packages/Cython/Distutils/build_ext.py", line 81, in build_extensions
    self.build_extension(ext)
  File "/usr/lib/python2.7/distutils/command/build_ext.py", line 524, in build_extension
    libraries=self.get_libraries(ext),
  File "/usr/lib/python2.7/distutils/command/build_ext.py", line 763, in get_libraries
    return ext.libraries + [pythonlib]
TypeError: can only concatenate tuple (not "list") to tuple


Here is a patch:

Index: setup.py
===================================================================
--- setup.py    (wersja 37)
+++ setup.py    (kopia robocza)
Index: newversion_beta/setup.py
===================================================================
--- newversion_beta/setup.py    (wersja 37)
+++ newversion_beta/setup.py    (kopia robocza)
@@ -82,7 +82,7 @@
     pass


-libs = ('avformat', 'avcodec', 'avutil', 'swscale')
+libs = ['avformat', 'avcodec', 'avutil', 'swscale']
 incdir = [ path_join(ffmpegpath, 'include'), "/usr/include/ffmpeg" , "./include" ] + nd.get_numpy_include_dirs()
 libinc = [ path_join(ffmpegpath, 'lib') ]

Original issue reported on code.google.com by [email protected] on 20 Sep 2010 at 1:32

Undefined Symbol: av_free_packet

I receive the following error when I attempt to import FFMpegReader:

ImportError: /usr/local/lib/python2.6/dist-packages/pyffmpeg.so: undefined 
symbol: av_free_packet

Any ideas?

Thanks.

Original issue reported on code.google.com by [email protected] on 4 May 2011 at 2:49

Extracting all the frames from a given video

What steps will reproduce the problem?
1. My purpose is to extract all the frames from a given video

2.I used the following code, it served the purpose but its getting crashed 
due to heavy memory usage.  
3. The code I used was ,
import pyffmpeg
frame_Number=0
while 1: 
        stream=pyffmpeg.VideoStream()
        stream.open('test_wmv.wmv')
        image=stream.GetFrameNo(frame_Number)
    except Exception,value:  
        print value
        break
    image.save('frame wmv %d.png'%(frame_Number))
    image=""
    frame_Number+=1



Expected to extract all the frames from a given video but the application 
crashed.


I am using it on Windows

-Regards,
Manoj




Original issue reported on code.google.com by [email protected] on 9 Jul 2009 at 3:36

Dist for python 2.6 on WiIndows

I saw that some old 2.4 and 2.5 win-python installers can be downloaded, but 
nothing quite recent for python 2.6. It would be so great to have it!

Thank you for your consideration


Original issue reported on code.google.com by [email protected] on 7 Aug 2010 at 9:39

Image sequences and Alpha

Hello,
I've just started using pyffmpeg and there is two minor issues (or maybe 
feature requests).

1) I'm not able to open image sequence as i can do with CLI ffmpeg (eg. -i 
foo%03d.tga) 

2) movies containing alpha channel (for example mov files with bgra pixel 
format) cannot be opened. It would be nice if alpha channel can be used via 
numpy (i am not sure if ffmpeg can manipulate with alpha, but it definetely can 
read files with alpha channel)

If you are accepting donations, I'm ready to donate some money if these 
features will be added.

thanks

martin

Original issue reported on code.google.com by [email protected] on 5 Oct 2010 at 6:16

module declaration

if you run example code:
#!/usr/bin/python

import pyffmpeg
import sys

if len(sys.argv) < 2: sys.exit()
filename_i = sys.argv[1]

stream = pyffmpeg.VideoStream()
print stream
stream.open(filename_i)
image = stream.GetFrameNo(0)
then you have:

$ ./kadr.py ../Svadba.mp4 
<pyffmpeg.VideoStream instance at 0x1cc5878>
Traceback (most recent call last):
  File "./kadr.py", line 11, in <module>
    stream.open(filename_i)
  File "pyffmpeg.pyx", line 2469, in pyffmpeg.VideoStream.open (pyffmpeg.c:16954)
  File "pyffmpeg.pyx", line 1944, in pyffmpeg.FFMpegReader.open (pyffmpeg.c:11937)
  File "pyffmpeg.pyx", line 2049, in pyffmpeg.FFMpegReader.__finalize_open (pyffmpeg.c:12806)
  File "pyffmpeg.pyx", line 1424, in pyffmpeg.VideoTrack.init (pyffmpeg.c:7382)
AttributeError: 'NoneType' object has no attribute 'new'

so, you need to add to example code:
import PIL

then:
$ ./kadr.py ../Svadba.mp4 
<pyffmpeg.VideoStream instance at 0x10916c8>
result PTS:0
start time checked : pts = 80000 , declared was : 0
result PTS:80000
result PTS:80000

Original issue reported on code.google.com by [email protected] on 24 Sep 2011 at 10:58

compilation errors on linux fedora 10

What steps will reproduce the problem?
1. install all needed packages with 'yum' (FFMPEG libs, Cython,..)
2. python setup build

What is the expected output? What do you see instead?
1. first build try:
Traceback (most recent call last):
[...] 
Pyrex.Compiler.Errors.CompileError:
/local/mben/soft/pyffmpeg-read-only/pyffmpeg.pyx:0:0:
'pyffmpeg-read-only.pyffmpeg' is not a valid module name

--> solution : rename directory 'pyffmpeg-read-only' as 'pyffmpeg'

2. second build try:
compilation errors :a lot of .h files are missing... (mathematics.h,
avutils.h, etc...)

--> solution : change a line in the setup.py file, in the linux part (after
else:)

include_dirs=["/usr/include/ffmpeg/","/usr/include/ffmpeg/libavcodec/","/usr/inc
lude/ffmpeg/libavformat","/usr/include/ffmpeg/libavutil","/usr/include/ffmpeg/li
bswscale"],

What version of the product are you using? On what operating system?
last version from svn with :
svn checkout http://pyffmpeg.googlecode.com/svn/trunk/ pyffmpeg-read-only

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 13 Aug 2009 at 2:09

gcc: pyffmpeg.c: No such file or directory

What steps will reproduce the problem?
1. just try to build under linux 

What is the expected output? What do you see instead?

root@kato:/opt/pyffmpeg# python setup.py build
running build
running build_ext
building 'pyffmpeg' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -O2 -Wall -Wstrict-prototypes
-fPIC -I/usr/include/ffmpeg -I/usr/include/python2.5 -c pyffmpeg.c -o
build/temp.linux-i686-2.5/pyffmpeg.o
gcc: pyffmpeg.c: No such file or directory
gcc: no input files
error: command 'gcc' failed with exit status 1


What version of the product are you using? On what operating system?

trunk, linux ubuntu 7.10 i386



Original issue reported on code.google.com by [email protected] on 15 May 2008 at 6:56

ioerror unable to seek

What steps will reproduce the problem?
1. install everything
2. run the sample program on the frontpage

What is the expected output? 
it should output an image file

What do you see instead?
[NULL @ 0x856d500]hmm, seems the headers are not complete, trying to guess
time_increment_bits
[NULL @ 0x856d500]my guess is 16 bits ;)
[NULL @ 0x856d500]looks like this file was encoded with
(divx4/(old)xvid/opendivx) -> forcing low_delay flag
[mpeg4 @ 0x856d500]low_delay flag incorrectly, clearing it
[swscaler @ 0x856e6c0]No accelerated colorspace conversion found.
Traceback (most recent call last):
  File "./tt.py", line 5, in <module>
    image = stream.GetFrameNo(1)
  File "pyffmpeg.pyx", line 2043, in pyffmpeg.VideoStream.GetFrameNo
(pyffmpeg.c:14997)
  File "pyffmpeg.pyx", line 1539, in pyffmpeg.VideoTrack.seek_to_frame
(pyffmpeg.c:9228)
  File "pyffmpeg.pyx", line 960, in pyffmpeg.Track.seek_to_seconds
(pyffmpeg.c:3887)
  File "pyffmpeg.pyx", line 986, in pyffmpeg.Track.seek_to_pts
(pyffmpeg.c:3974)
  File "pyffmpeg.pyx", line 1915, in pyffmpeg.FFMpegReader.seek_to
(pyffmpeg.c:13343)
IOError: Unable to seek: -1

What version of the product are you using? 
latest svn

On what operating system?
ubuntu 9.04 and its apt packages


Original issue reported on code.google.com by [email protected] on 12 Jan 2010 at 8:28

pyffmpeg.c missng

What steps will reproduce the problem?
1. Run python setup.py build on linux

What is the expected output? What do you see instead?
Expected: Compilation of the Extension pyffmpeg
Insetead: i686-pc-linux-gnu-gcc: pyffmpeg.c: No such file or directory


What version of the product are you using? On what operating system?
Source Version from SVN Revision 5


Please provide any additional information below.
It seems like pyffmpeg.c is missing in the source directory. Could it be?

Original issue reported on code.google.com by [email protected] on 28 Aug 2007 at 9:31

No 32 bits build

Hi,

Wanted to seek for a kind of alternative to AVISynth scripting language, which 
is not available on Linux. Found PyFFMPeg, but download only shows 64 bits 
binary, and I can't locate source to compile for my 32 bits Ubuntu Maverick.

Original issue reported on code.google.com by [email protected] on 13 Nov 2011 at 3:51

whyPyffmpeg not support Python 2.6?

What steps will reproduce the problem?

Currently,the downloads list not any release file support the python2.6.

It seem that this project not update for a long time.

my question is:why not support Python2.6?


Original issue reported on code.google.com by [email protected] on 29 Apr 2010 at 2:10

beta doesn't build

What steps will reproduce the problem?
1. Install dependencies
2. from newversion_beta, run python setup.py install --prefix=${MY_INSTALL_DIR}

What is the expected output? What do you see instead?

Instead of building and installing, I get this:
running install
running build
running build_ext
building 'pyffmpeg' extension
C compiler: gcc -pthread -fno-strict-aliasing -DNDEBUG -O2 -g -pipe -Wall 
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector 
--param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fPIC

compile options: '-I/opt/ffmpeg/include -I/usr/include/ffmpeg -I./include 
-I/opt/lisa/os/lib/python2.5/site-packages/numpy/core/include 
-I/usr/include/python2.5 -c'
Traceback (most recent call last):
  File "setup.py", line 151, in <module>
    **meta_data
  File "/usr/lib64/python2.5/distutils/core.py", line 151, in setup
    dist.run_commands()
  File "/usr/lib64/python2.5/distutils/dist.py", line 974, in run_commands
    self.run_command(cmd)
  File "/usr/lib64/python2.5/distutils/dist.py", line 994, in run_command
    cmd_obj.run()
  File "/usr/lib64/python2.5/distutils/command/install.py", line 506, in run
    self.run_command('build')
  File "/usr/lib64/python2.5/distutils/cmd.py", line 333, in run_command
    self.distribution.run_command(command)
  File "/usr/lib64/python2.5/distutils/dist.py", line 994, in run_command
    cmd_obj.run()
  File "/usr/lib64/python2.5/distutils/command/build.py", line 112, in run
    self.run_command(cmd_name)
  File "/usr/lib64/python2.5/distutils/cmd.py", line 333, in run_command
    self.distribution.run_command(command)
  File "/usr/lib64/python2.5/distutils/dist.py", line 994, in run_command
    cmd_obj.run()
  File "/usr/lib64/python2.5/distutils/command/build_ext.py", line 290, in run
    self.build_extensions()
  File "/u/lisa/local/export.soft.lisa.master/linux-x86_64-fc9.x86_64/lib64/python2.5/site-packages/Cython-0.12.1-py2.5-linux-x86_64.egg/Cython/Distutils/build_ext.py", line 83, in build_extensions
    self.build_extension(ext)
  File "/usr/lib64/python2.5/distutils/command/build_ext.py", line 506, in build_extension
    libraries=self.get_libraries(ext),
  File "/usr/lib64/python2.5/distutils/command/build_ext.py", line 712, in get_libraries
    return ext.libraries + [pythonlib]
TypeError: can only concatenate tuple (not "list") to tuple


What version of the product are you using? On what operating system?
pyffmpeg-read-only svn checked out july 12, 2010. Fedora release 9.

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 12 Jul 2010 at 8:27

ImportError: DLL load failed: The specified module could not be found.

What steps will reproduce the problem?
1. Download the pyffmpeg-2.0.win32.zip and unzip to 
C:\Python26\Lib\site-packages

2. After typing import pyffmpeg, I got the errors
Traceback (most recent call last):
  File "<pyshell#0>", line 1, in <module>
    import pyffmpeg
ImportError: DLL load failed: The specified module could not be found.

3.

What is the expected output? What do you see instead?
It seems I failed to import the pyffmpeg module. 

What version of the product are you using? On what operating system?
The version of python I am using is 2.6. OS is windows 7.

Please provide any additional information below.
Could you give me some instructions about how to install pyffmpeg correctly? 
Thanks a lot.

Original issue reported on code.google.com by [email protected] on 3 Jan 2011 at 4:35

Build on Ubuntu 11.10 python 2.7.2+ Intel Centrino Duo 32bit fails

What steps will reproduce the problem?
1. In pyffmpeg.pyx change line 808 to     def __cinit__(self):
2. and line 1835 to     def 
__cinit__(self,with_readahead=True,seek_before=4000):
3. Run python setup.py build

What is the expected output? What do you see instead?
running build
running build_ext
skipping 'pyffmpeg.c' Cython extension (up-to-date)
building 'pyffmpeg' extension
C compiler: gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fPIC

compile options: '-I/opt/ffmpeg/include -I/usr/include/ffmpeg -I./include 
-I/usr/lib/pymodules/python2.7/numpy/core/include -I/usr/include/python2.7 -c'
gcc: pyffmpeg.c
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_13AFFMpegReader_2open«:
pyffmpeg.c:2020:13: Warnung: Variable »__pyx_v_track_selector« gesetzt, aber 
nicht verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_5Track_5init«:
pyffmpeg.c:2963:3: Warnung: »avcodec_open« ist veraltet (deklariert bei 
/usr/include/libavcodec/avcodec.h:3650) [-Wdeprecated-declarations]
pyffmpeg.c:2988:65: Fehler: »struct AVCodecContext« hat kein Element namens 
»hurry_up«
pyffmpeg.c:2641:13: Warnung: Variable »__pyx_v_observer« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_5Track_9_reopencodec«:
pyffmpeg.c:4131:3: Warnung: »avcodec_open« ist veraltet (deklariert bei 
/usr/include/libavcodec/avcodec.h:3650) [-Wdeprecated-declarations]
pyffmpeg.c:4015:7: Warnung: Variable »__pyx_v_ret« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_f_8pyffmpeg_10AudioTrack_process_packet«:
pyffmpeg.c:5947:195: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer 
Breite [-Wint-to-pointer-cast]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_10VideoTrack_init«:
pyffmpeg.c:6649:7: Warnung: Variable »__pyx_v_i« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion 
»__pyx_f_8pyffmpeg_10VideoTrack__read_current_motion_vectors«:
pyffmpeg.c:7633:7: Warnung: Variable »__pyx_v_mv_y« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c:7632:7: Warnung: Variable »__pyx_v_mv_x« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_10VideoTrack_9_internal_get_current_frame«:
pyffmpeg.c:8278:327: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer 
Breite [-Wint-to-pointer-cast]
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_10VideoTrack_10_get_current_frame_without_copy«:
pyffmpeg.c:8444:327: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer 
Breite [-Wint-to-pointer-cast]
pyffmpeg.c:8393:7: Warnung: Variable »__pyx_v_numBytes« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c:8392:19: Warnung: Variable »__pyx_v_pFrameRes« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_10VideoTrack_18set_hurry«:
pyffmpeg.c:9448:81: Fehler: »struct AVCodecContext« hat kein Element namens 
»hurry_up«
pyffmpeg.c:9487:81: Fehler: »struct AVCodecContext« hat kein Element namens 
»hurry_up«
pyffmpeg.c: In Funktion »__pyx_f_8pyffmpeg_10VideoTrack__convert_to«:
pyffmpeg.c:9646:3: Warnung: Übergabe des Arguments 2 von »sws_scale« von 
inkompatiblem Zeigertyp [standardmäßig aktiviert]
/usr/include/libswscale/swscale.h:233:5: Anmerkung: »const uint8_t * const*« 
erwartet, aber Argument hat Typ »uint8_t **«
pyffmpeg.c:9517:26: Warnung: Variable »__pyx_v_pCodecCtx« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_f_8pyffmpeg_10VideoTrack__convert_withbuf«:
pyffmpeg.c:9816:3: Warnung: Übergabe des Arguments 2 von »sws_scale« von 
inkompatiblem Zeigertyp [standardmäßig aktiviert]
/usr/include/libswscale/swscale.h:233:5: Anmerkung: »const uint8_t * const*« 
erwartet, aber Argument hat Typ »uint8_t **«
pyffmpeg.c:9705:26: Warnung: Variable »__pyx_v_pCodecCtx« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_3dump«:
pyffmpeg.c:10854:3: Warnung: »dump_format« ist veraltet (deklariert bei 
/usr/include/libavformat/avformat.h:1485) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_4open«:
pyffmpeg.c:11061:14: Warnung: Implizite Deklaration der Funktion 
»guess_format« [-Wimplicit-function-declaration]
pyffmpeg.c:11061:94: Warnung: Zuweisung erzeugt Zeiger von Ganzzahl ohne 
Typkonvertierung [standardmäßig aktiviert]
pyffmpeg.c:11144:5: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c:11204:7: Warnung: »url_setbufsize« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:286) [-Wdeprecated-declarations]
pyffmpeg.c:11281:7: Warnung: »get_buffer« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:241) [-Wdeprecated-declarations]
pyffmpeg.c:11305:7: Warnung: »url_fseek« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:280) [-Wdeprecated-declarations]
pyffmpeg.c:11315:9: Warnung: »url_fclose« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:279) [-Wdeprecated-declarations]
pyffmpeg.c:11324:9: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c:11446:5: Warnung: »av_open_input_stream« ist veraltet (deklariert 
bei /usr/include/libavformat/avformat.h:1032) [-Wdeprecated-declarations]
pyffmpeg.c:11527:5: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_12FFMpegReader_5__finalize_open_write«:
pyffmpeg.c:11650:23: Warnung: Zuweisung erzeugt Zeiger von Ganzzahl ohne 
Typkonvertierung [standardmäßig aktiviert]
pyffmpeg.c:11699:3: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_6__finalize_open«:
pyffmpeg.c:12205:32: Fehler: »CODEC_TYPE_VIDEO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:12205:32: Anmerkung: jeder nicht deklarierte Bezeichner wird nur 
einmal für jede Funktion, in der er vorkommt, gemeldet
pyffmpeg.c:12381:32: Fehler: »CODEC_TYPE_AUDIO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_12FFMpegReader_8process_current_packet«:
pyffmpeg.c:13566:56: Fehler: »CODEC_TYPE_VIDEO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:13610:56: Fehler: »CODEC_TYPE_AUDIO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:13483:7: Warnung: Variable »__pyx_v_processed« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_19seek_bytes«:
pyffmpeg.c:15445:5: Warnung: »url_fseek« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:280) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_11VideoStream_6GetCurrentFrame«:
pyffmpeg.c:16762:13: Warnung: Variable »__pyx_v_fno« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_11VideoStream_7GetNextFrame«:
pyffmpeg.c:16858:13: Warnung: Variable »__pyx_v_fno« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »initpyffmpeg«:
pyffmpeg.c:19712:30: Fehler: »CODEC_TYPE_VIDEO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:19729:30: Fehler: »CODEC_TYPE_AUDIO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_13AFFMpegReader_2open«:
pyffmpeg.c:2020:13: Warnung: Variable »__pyx_v_track_selector« gesetzt, aber 
nicht verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_5Track_5init«:
pyffmpeg.c:2963:3: Warnung: »avcodec_open« ist veraltet (deklariert bei 
/usr/include/libavcodec/avcodec.h:3650) [-Wdeprecated-declarations]
pyffmpeg.c:2988:65: Fehler: »struct AVCodecContext« hat kein Element namens 
»hurry_up«
pyffmpeg.c:2641:13: Warnung: Variable »__pyx_v_observer« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_5Track_9_reopencodec«:
pyffmpeg.c:4131:3: Warnung: »avcodec_open« ist veraltet (deklariert bei 
/usr/include/libavcodec/avcodec.h:3650) [-Wdeprecated-declarations]
pyffmpeg.c:4015:7: Warnung: Variable »__pyx_v_ret« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_f_8pyffmpeg_10AudioTrack_process_packet«:
pyffmpeg.c:5947:195: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer 
Breite [-Wint-to-pointer-cast]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_10VideoTrack_init«:
pyffmpeg.c:6649:7: Warnung: Variable »__pyx_v_i« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion 
»__pyx_f_8pyffmpeg_10VideoTrack__read_current_motion_vectors«:
pyffmpeg.c:7633:7: Warnung: Variable »__pyx_v_mv_y« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c:7632:7: Warnung: Variable »__pyx_v_mv_x« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_10VideoTrack_9_internal_get_current_frame«:
pyffmpeg.c:8278:327: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer 
Breite [-Wint-to-pointer-cast]
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_10VideoTrack_10_get_current_frame_without_copy«:
pyffmpeg.c:8444:327: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer 
Breite [-Wint-to-pointer-cast]
pyffmpeg.c:8393:7: Warnung: Variable »__pyx_v_numBytes« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c:8392:19: Warnung: Variable »__pyx_v_pFrameRes« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_10VideoTrack_18set_hurry«:
pyffmpeg.c:9448:81: Fehler: »struct AVCodecContext« hat kein Element namens 
»hurry_up«
pyffmpeg.c:9487:81: Fehler: »struct AVCodecContext« hat kein Element namens 
»hurry_up«
pyffmpeg.c: In Funktion »__pyx_f_8pyffmpeg_10VideoTrack__convert_to«:
pyffmpeg.c:9646:3: Warnung: Übergabe des Arguments 2 von »sws_scale« von 
inkompatiblem Zeigertyp [standardmäßig aktiviert]
/usr/include/libswscale/swscale.h:233:5: Anmerkung: »const uint8_t * const*« 
erwartet, aber Argument hat Typ »uint8_t **«
pyffmpeg.c:9517:26: Warnung: Variable »__pyx_v_pCodecCtx« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_f_8pyffmpeg_10VideoTrack__convert_withbuf«:
pyffmpeg.c:9816:3: Warnung: Übergabe des Arguments 2 von »sws_scale« von 
inkompatiblem Zeigertyp [standardmäßig aktiviert]
/usr/include/libswscale/swscale.h:233:5: Anmerkung: »const uint8_t * const*« 
erwartet, aber Argument hat Typ »uint8_t **«
pyffmpeg.c:9705:26: Warnung: Variable »__pyx_v_pCodecCtx« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_3dump«:
pyffmpeg.c:10854:3: Warnung: »dump_format« ist veraltet (deklariert bei 
/usr/include/libavformat/avformat.h:1485) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_4open«:
pyffmpeg.c:11061:14: Warnung: Implizite Deklaration der Funktion 
»guess_format« [-Wimplicit-function-declaration]
pyffmpeg.c:11061:94: Warnung: Zuweisung erzeugt Zeiger von Ganzzahl ohne 
Typkonvertierung [standardmäßig aktiviert]
pyffmpeg.c:11144:5: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c:11204:7: Warnung: »url_setbufsize« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:286) [-Wdeprecated-declarations]
pyffmpeg.c:11281:7: Warnung: »get_buffer« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:241) [-Wdeprecated-declarations]
pyffmpeg.c:11305:7: Warnung: »url_fseek« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:280) [-Wdeprecated-declarations]
pyffmpeg.c:11315:9: Warnung: »url_fclose« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:279) [-Wdeprecated-declarations]
pyffmpeg.c:11324:9: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c:11446:5: Warnung: »av_open_input_stream« ist veraltet (deklariert 
bei /usr/include/libavformat/avformat.h:1032) [-Wdeprecated-declarations]
pyffmpeg.c:11527:5: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_12FFMpegReader_5__finalize_open_write«:
pyffmpeg.c:11650:23: Warnung: Zuweisung erzeugt Zeiger von Ganzzahl ohne 
Typkonvertierung [standardmäßig aktiviert]
pyffmpeg.c:11699:3: Warnung: »url_fopen« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:278) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_6__finalize_open«:
pyffmpeg.c:12205:32: Fehler: »CODEC_TYPE_VIDEO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:12205:32: Anmerkung: jeder nicht deklarierte Bezeichner wird nur 
einmal für jede Funktion, in der er vorkommt, gemeldet
pyffmpeg.c:12381:32: Fehler: »CODEC_TYPE_AUDIO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c: In Funktion 
»__pyx_pf_8pyffmpeg_12FFMpegReader_8process_current_packet«:
pyffmpeg.c:13566:56: Fehler: »CODEC_TYPE_VIDEO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:13610:56: Fehler: »CODEC_TYPE_AUDIO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:13483:7: Warnung: Variable »__pyx_v_processed« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_12FFMpegReader_19seek_bytes«:
pyffmpeg.c:15445:5: Warnung: »url_fseek« ist veraltet (deklariert bei 
/usr/include/libavformat/avio.h:280) [-Wdeprecated-declarations]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_11VideoStream_6GetCurrentFrame«:
pyffmpeg.c:16762:13: Warnung: Variable »__pyx_v_fno« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »__pyx_pf_8pyffmpeg_11VideoStream_7GetNextFrame«:
pyffmpeg.c:16858:13: Warnung: Variable »__pyx_v_fno« gesetzt, aber nicht 
verwendet [-Wunused-but-set-variable]
pyffmpeg.c: In Funktion »initpyffmpeg«:
pyffmpeg.c:19712:30: Fehler: »CODEC_TYPE_VIDEO« nicht deklariert (erste 
Benutzung in dieser Funktion)
pyffmpeg.c:19729:30: Fehler: »CODEC_TYPE_AUDIO« nicht deklariert (erste 
Benutzung in dieser Funktion)
error: Command "gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fPIC -I/opt/ffmpeg/include -I/usr/include/ffmpeg 
-I./include -I/usr/lib/pymodules/python2.7/numpy/core/include 
-I/usr/include/python2.7 -c pyffmpeg.c -o build/temp.linux-i686-2.7/pyffmpeg.o" 
failed with exit status 1


What version of the product are you using? On what operating system?
tried pyffmpeg 2.0 as well as 2.1b, same problem

Please provide any additional information below.
before doing the changes, mentioned before, it complained about "__new__ method 
of extension type will change semantics in a future version of Pyrex and 
Cython. Use __cinit__ instead."

Python 2.7.2+ (default, Oct  4 2011, 20:03:08) 
[GCC 4.6.1] on linux2

Original issue reported on code.google.com by [email protected] on 3 Apr 2012 at 6:08

AttributeError: 'module' object has no attribute 'VideoStream'

What steps will reproduce the problem?
1. Post installation
2. First test run
3. in python from command line (as given on site)

What is the expected output? What do you see instead?

AttributeError: 'module' object has no attribute 'VideoStream'

What version of the product are you using? On what operating system?

checked out from repository latest

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 30 Jun 2009 at 3:15

Error opening media when using standalone executables with either py2app or pyinstaller

What steps will reproduce the problem?
1. Create a Python script that uses pyffmpeg
2. Use either py2app or pyinstaller to create an application bundle or a 
standalone executable
3. Opening a movie file fails with an error message

What is the expected output? What do you see instead?
When running the Python script, the media file opens with no problems. When 
running the standalone executables created with either py2app or pyinstaller, I 
get the error message below:

File "pyffmpeg.pyx", line 1949, in pyffmpeg.FFMpegReader.open (pyffmpeg.c:11574)
File "pyffmpeg.pyx", line 2049, in pyffmpeg.FFMpegReader.__finalize_open 
(pyffmpeg.c:12435)
File "pyffmpeg.pyx", line 1425, in pyffmpeg.VideoTrack.init (pyffmpeg.c:7098)
AttributeError: 'NoneType' object has no attribute 'zeros'


What version of the product are you using? On what operating system?

I'm using pyffmpeg 2.0. This happens with py2app on Mac OS 10.5 and with 
pyinstaller on Windows XP.

Please provide any additional information below.

Thanks a lot,

Adriano

Original issue reported on code.google.com by [email protected] on 27 Jun 2011 at 2:52

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.