GNOME Bugzilla – Bug 601982
Port Pitivi to Windows
Last modified: 2010-11-03 20:39:26 UTC
Created attachment 147775 [details] [review] 0001-Retrieve-the-window-xid-using-the-right-method-in-Wi.patch Hi, A long time ago I started working on porting pitivi to windows to test the GStreamer Winbuilds binaries and after a while (basically when I found some free time), I started working on it again (http://www.mail-archive.com/pitivi-pitivi@lists.sourceforge.net/msg00462.html) ;) The following patches propose some modification to the actual code to make it compatible with Windows. I have tryed reduce the impact as much as possible and you will see that they are not intrusive at all. This serie of patches also provide a packaging script/system for windows using py2exe, to make it easier the distribution of PiTiVi in an auto contained installer. The requirements to package PiTiVi are: -Gtk (www.gtk.org) -GStreamer Winbuilds 0.10.5, which I'm going to release this week, I'm trying to fix a minor bug before the release. -Pygtk (www.pygtk.org) -Pygst (The same as for GStreamer) -Zope.Interface (Installed using easy install) As I haven't released yet GStreamer Winbuilds, I have uploaded in the meanwhile an installer at: http://ossbuild.googlecode.com/files/PiTiVi-0.13.3.exe I haven't tested it in another machine, so probably I missed some dll or python module in the deployment. Work to do: I haven't finished yet the theming support for win32, so the GUI looks pretty ugly... There is bug in the time line which makes it almost unusable: when you try to trim a video it seems that the time line doesn't notice when you release the button, so each time you pass over this segment it thinks that you are trimming it. The timescale code is huge for me but I think you guys will find a fix very quickly. I haven't added any translation yet. Test it out and provide as much feedback as you can xD
Created attachment 147776 [details] [review] 2nd patch
Created attachment 147777 [details] [review] 3rd patch
Created attachment 147778 [details] [review] 4th patch
Created attachment 147779 [details] [review] 0005-Don-t-search-a-None-var.patch
Created attachment 147780 [details] [review] 0001-Disable-device-probing-on-Windows.patch
Created attachment 147781 [details] [review] 0002-Retrieve-the-window-xid-using-the-right-method-in-Wi.patch
Created attachment 147782 [details] [review] 0003-Add-PNG-pixmaps-for-the-Windows-version.patch
Created attachment 147783 [details] [review] 0004-Add-manually-generated-files-for-windows.patch
Created attachment 147784 [details] [review] 0005-Handle-data-files-in-the-root-dir-on-windows.patch
Created attachment 147785 [details] [review] 0006-Don-t-search-a-None-var.patch
Created attachment 147786 [details] [review] 0008-Use-USERPROFILE-instead-of-HOME-in-windows.patch
Created attachment 147787 [details] [review] 0009-Add-Pitivi-s-windows-icon.patch
Created attachment 147788 [details] [review] 0010-Add-script-based-in-py2exe-for-packaging-pitivi-in-w.patch
Created attachment 147789 [details] [review] 0011-Add-innosetup-script-for-the-windows-installer.patch
Patch 4 should be splitted: win32/configure.py win32/pitivi A new commit with the others files: "Add configuration data and modules for win32 deployment"
Created attachment 147793 [details] [review] 0007-1-Add-external-dependencies-for-the-windows-build
Created attachment 147794 [details] [review] 0007-2-Add-external-dependencies-for-the-windows-build.patch
Created attachment 147795 [details] Snapshot1
Created attachment 147796 [details] Snapshot 2
Created attachment 147797 [details] Snapshot 3
Created attachment 147798 [details] Snapshot 4
I have updated the installer with Gtk themes support!
*** Bug 432900 has been marked as a duplicate of this bug. ***
Finally had time to go over the patches. To sum up: * I'm 100% fine with the patches that modify the pitivi source code to handle windows (patches #1, #2, #5, #6, #8). I'll commit/push them ASAP * I find it acceptable to have some stuff which is normally generated by autoconf/automake in win32 (like bin/pitivi). We do the same thing in GStreamer, no big problem there. * I'd prefer the PNG pixmaps support patch to be rewritten a bit so we don't end up with confusing *.svg files in win32/pixmaps/ which are in fact PNG files (i.e. modify the loading code to make it png/svg agnostic) * The .iss file, py2exe script and pitvi.ico are also acceptable. * ... but there is no way we're putting .dlls in the pitivi repository. Those should all belong in the external build system (i.e. winbuilds).
Great! About dll's, Would it be better to provide a link or an error message in the script for example? Please don't commit win32/setup.py and I'll try to send a patch these evening.
Great News! Just running the installer I get this: "You do not have a recent enough version of the GNonLin GStreamer plugin (currently 0.10.11) Install a version of the GNonLin GStreamer plugin greater or equal to 0.10.12" The I redownload and install you latest: GStreamerWinBuild-0.10.4 but get the same error. It doesn't seem to be possible for me to get any further until you release GStreamer Winbuilds 0.10.5? Later on(I know this is at a very early stage) maybe you should add the working GStreamerWinBuild to the installer so it'll be one download. You know with this win-port of Pitivi will actually be the first working NLE which will be cross platform. What I saying is that you're writing history here! :)
I haven't released WinBuilds 0.10.5 yet. The installer comes with an updated version of the GStreamer binaries, but you need to uninstall the previous version of WinBuilds first. I also forgot to set GST_PLUGIN_PATH to pitivi's installation folder so will need to set it manually. GSTPLUGIN_PATH=c:\your_pitivi_installation_path\lig\gstreamer-0.10 I'll try to update the installer ASAP
Where do I set that path? Tried to look for an ini file - but didn't find any. Two small GUI related things on Vista: http://download.videohelp.com/tin2tin/Pitivi_on_Vista.png - In the menu the selected items becomes white text on white background. - The seperating lines comes out wrong. http://download.videohelp.com/tin2tin/Pitivi_Pref_on_Vista.png - The Preferences window should be a bit bigger so the reset buttons would be visible. I can get an image in the player from the file in the timeline - but it doesn't play - properly because that path isn't set correctly.
Cool! It seems that I didn't miss anything :) The first 2 issues seems to be a bug in the Gtk Theme. Could you try changing it? There is an application in bin/gtk2_prefs.exe to change it. By: "but it doesn't play - properly because that path isn't set correctly", what do you mean?
(In reply to comment #24) > * I'd prefer the PNG pixmaps support patch to be rewritten a bit so we don't > end up with confusing *.svg files in win32/pixmaps/ which are in fact PNG files > (i.e. modify the loading code to make it png/svg agnostic) I see two option: 1.Changing the extension in the code to .png 2.Nameing these pixmaps in $ROOT/win32/pixmaps, or even in $ROOT/pixmaps, with the good extension *.png but renaming them to *svg with the setup script. I think this second option is cleaner.
Resaving Clearlooks in gtk2_prefs.exe makes the menu and the preferences window come out right. Nice tool btw. Using a mpg file with 4:3 pal(+audio) dvd properties plays okay when doubleclicking in the Clip Lib window, but when adding it to the timeline makes the playback stutter/not update the image at all. These are the properties of the mentioned clip: Audio: Dolby AC3 48000Hz stereo 192Kbps [AC-3] Video: MPEG2 Video 720x576 (4:3) 25.00fps 7500Kbps [Video] This plays better: Video: Xvid 624x352 29.97fps 938Kbps [Video 0] Audio: MPEG Audio Layer 3 48000Hz stereo 131Kbps [Audio 1] Btw. nothing happens here when selecting Project Settings and Render Project - haven't these functions been added yet?
(In reply to comment #31) > Btw. nothing happens here when selecting Project Settings and Render Project - > haven't these functions been added yet? Uuuppsss, I forgot to package all the *glade files, that's why the GUI doesn't shows up. I have been very busy today and I won't be able to update the installer, I will try again tomorrow. Regarding the video codecs issues... this is the first try and as I said, it's almost unusable actually. You'll get a bunch of errors from gnonlin when trying to move or trim clips, but you should be able to do very simple things and render the clip (once I package the *glade files :) )
No worries. I'm just amazed that it is at all possible to port Pitivi and I hope to help out by testing it. :)
I have updated the installer which fixes the issues with the missing glade files and the gstreamer plugins path: http://ossbuild.googlecode.com/files/PiTiVi-0.13.3-1.exe You should be now able to render projects. I'll upload the patches tomorrow if everything is ok.
Great. I'll run a few tests. ON THE UI: Now both the Project Settings and the Render Project windows works here. :) Selecting Plugins in the menu doesn't open any window. Rendering seems to be doing its job, but selecting a preset doesn't add an extention to the rendered file. Maybe this is not win-port related? ON IMPORTING FILES/CODEC RELATED(I GUESS?) The mpg clip imports okay - and plays back fine in Clip lib but now when added to the timeline. The audio-wave render only renders 1/5 in a very slow pace and the stops. Same behaviour as above. The file is rendered with HCenc. Audio: Dolby AC3 48000Hz stereo 192Kbps [AC-3] Video: MPEG2 Video 720x576 (4:3) 25.00fps 7500Kbps [Video] Importing a flv 720x576 with audio file seems to work, but has a somewhat delayed playback from timeline. Importing this clip: Video: Xvid 624x352 29.97fps 938Kbps [Video 0] Audio: MPEG Audio Layer 3 48000Hz stereo 131Kbps [Audio 1] Produces this error: GStreamer encountered a general stream error. ..\..\..\Source\gst-plugins-good\gst\avi\gstavidemux.c(4219): gst_avi_demux_loop (): /GstPipeline:pipeline0/GstBin:bin0/GnlComposition:gnlcomposition0/GnlSource:gnlsource11/GstBin:bin22/pitivi+elements+singledecodebin+SingleDecodeBin:pitivi+elements+singledecodebin+singledecodebin14/GstAviDemux:avidemux8: streaming stopped, reason not-negotiated Trying to import ac3 and mp3 produces this error: URI:/C:/Users/Test/Music/1-08 Feeling Good.mp3 Problem:Could not establish the duration of the file. Extra information:This clip seems to be in a format which cannot be accessed in a random fashion.
Created attachment 149157 [details] [review] 0003-Add-svg-pitivi-pixmpas-converted-to-png-format-for-w.patch
Created attachment 149158 [details] [review] 0010-Add-script-based-in-py2exe-for-packaging-pitivi-in-w.patch
Created attachment 149159 [details] [review] 0012-Fix-glade-files-path-resolution-in-windows.patch
Created attachment 149160 [details] [review] 0004-Add-manually-generated-files-for-windows.patch From my side the patches are ready to be pushed upstream :) I have remove all the dll's and external files, and everything is now handled in the setup script.
Created attachment 149161 [details] [review] 0003-Add-svg-pitivi-pixmpas-converted-to-png-format-for-w.patch
Is there a new build of the installer as well? :)
I'll try to upload a new installer before wednesday :)
Any luck with the windows build yet? :)
Pushed all the patches except for the Innotek/winbuilds specific one and refactored one slightly : commit c149539b09fe5feb4cb3d1b0c49b5dec6369de6f Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Sun Nov 15 15:57:56 2009 +0100 Add script based in py2exe for packaging pitivi in windows commit 00712025d5ac11b6f61822648f1a8f60692398a4 Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Sun Nov 15 02:02:40 2009 +0100 Add Pitivi's windows icon commit 623391bef1ed6f8e802db7a0f9e3bc9ed0287333 Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Sun Nov 15 15:44:36 2009 +0100 Use 'USERPROFILE' instead of 'HOME' in windows commit 2e2b12bcb1fb5de5a5ada1b4cd13d5797e9807b2 Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Sun Nov 15 01:26:02 2009 +0100 Don't search a 'None' var commit 3b919ac6381bba101c5134604e2322969b15ddd8 Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Tue Apr 27 22:23:43 2010 +0200 ui: Resolve gracefully glade files path on windows Instead of checking for platform.system() =='Windows', check if we launched pitivi.exe. This way windows developers can still run pitivi using the python script by copying the content in $ROOT/pitivi to $ROOT/win32/dist/lib/pitivi/ commit c578bce41a9d23ca61050a8311c8301c5e5b53a1 Author: Edward Hervey <bilboed@bilboed.com> Date: Tue Apr 27 22:20:30 2010 +0200 pitivi.ui: Handle Win32 glade locations commit abed3107e93e4c897a46417fee6d8b364ffebaf3 Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Fri Dec 4 00:46:52 2009 +0100 Add manually generated files for windows We don't use autotools on windows. Generate manually *.in files commit 3a10e34bec3f18893bf62e95cebc196abfa750d9 Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Fri Dec 4 00:40:43 2009 +0100 Add svg pitivi pixmpas converted to png format for windows On windows gdk does not have a pixbuf loader for svg format. We will copy use png pixmaps renamed to *svg, so pitivi can load them commit d3d812a782b7e5d8e0d896060c5b7c6e5f2ba955 Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Sat Nov 14 22:25:34 2009 +0100 Retrieve the window xid using the right method in Windows commit 4dd8e2bcb8e5f5a58db94bf2b0139bccee9ce73b Author: Andoni Morales Alastruey <ylatuya@gmail.com> Date: Thu Mar 25 00:38:36 2010 +0100 Disable device probing on Windows
Comment on attachment 149159 [details] [review] 0012-Fix-glade-files-path-resolution-in-windows.patch Refactored that one slightly to avoid the repetitive glade_file check for GladeWindow/GladeDialog subclasses
Andoni, could you test building again with pitivi head ? If it's all good for you, I'll close this bug.
Andoni, Ping.
Pong. I think the this bug can be closed now.
Meaning... is there a working build up somewhere for testing?
I'm struggling with different versions of Gtk+. With 2.16, there is a bug in the timeline, and trimming clips is painful because the cursor is never released. Instead, with 2.18 this part seems to be fixed, but sometimes you can't add a clip to the timeline. Another problem using 2.18, is that because of the client-side windows stuff, the video is displayed in the full window, instead of using the video window. So many problems for the moments, and nothing really usable at the moment :(
I'm sorry to hear that. Those bugs(sometimes unable to add clips and video in full window) sounds like they where introduced since 2.16? As far as I came testing 2.16 those things seemed to work okay back then.
Closing as per comment 48. Please file new bugs for new issues. Thanks.