After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 601982 - Port Pitivi to Windows
Port Pitivi to Windows
Status: RESOLVED FIXED
Product: pitivi
Classification: Other
Component: General
Git
Other Windows
: Normal normal
: Git
Assigned To: Pitivi maintainers
Pitivi maintainers
: 432900 (view as bug list)
Depends on:
Blocks: 335805
 
 
Reported: 2009-11-15 16:18 UTC by Andoni Morales
Modified: 2010-11-03 20:39 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
0001-Retrieve-the-window-xid-using-the-right-method-in-Wi.patch (1.60 KB, patch)
2009-11-15 16:18 UTC, Andoni Morales
none Details | Review
2nd patch (14.17 KB, patch)
2009-11-15 16:19 UTC, Andoni Morales
none Details | Review
3rd patch (521.05 KB, patch)
2009-11-15 16:19 UTC, Andoni Morales
none Details | Review
4th patch (521.05 KB, patch)
2009-11-15 16:20 UTC, Andoni Morales
none Details | Review
0005-Don-t-search-a-None-var.patch (712 bytes, patch)
2009-11-15 16:21 UTC, Andoni Morales
none Details | Review
0001-Disable-device-probing-on-Windows.patch (1.46 KB, patch)
2009-11-15 16:24 UTC, Andoni Morales
committed Details | Review
0002-Retrieve-the-window-xid-using-the-right-method-in-Wi.patch (1.60 KB, patch)
2009-11-15 16:24 UTC, Andoni Morales
committed Details | Review
0003-Add-PNG-pixmaps-for-the-Windows-version.patch (14.17 KB, patch)
2009-11-15 16:25 UTC, Andoni Morales
none Details | Review
0004-Add-manually-generated-files-for-windows.patch (521.05 KB, patch)
2009-11-15 16:25 UTC, Andoni Morales
none Details | Review
0005-Handle-data-files-in-the-root-dir-on-windows.patch (1.19 KB, patch)
2009-11-15 16:26 UTC, Andoni Morales
committed Details | Review
0006-Don-t-search-a-None-var.patch (712 bytes, patch)
2009-11-15 16:27 UTC, Andoni Morales
committed Details | Review
0008-Use-USERPROFILE-instead-of-HOME-in-windows.patch (1.50 KB, patch)
2009-11-15 16:29 UTC, Andoni Morales
committed Details | Review
0009-Add-Pitivi-s-windows-icon.patch (4.99 KB, patch)
2009-11-15 16:30 UTC, Andoni Morales
committed Details | Review
0010-Add-script-based-in-py2exe-for-packaging-pitivi-in-w.patch (6.00 KB, patch)
2009-11-15 16:30 UTC, Andoni Morales
none Details | Review
0011-Add-innosetup-script-for-the-windows-installer.patch (3.03 KB, patch)
2009-11-15 16:31 UTC, Andoni Morales
rejected Details | Review
0007-1-Add-external-dependencies-for-the-windows-build (587.75 KB, patch)
2009-11-15 16:55 UTC, Andoni Morales
none Details | Review
0007-2-Add-external-dependencies-for-the-windows-build.patch (735.22 KB, patch)
2009-11-15 16:56 UTC, Andoni Morales
none Details | Review
Snapshot1 (169.68 KB, image/png)
2009-11-15 17:02 UTC, Andoni Morales
  Details
Snapshot 2 (214.10 KB, image/png)
2009-11-15 17:03 UTC, Andoni Morales
  Details
Snapshot 3 (127.80 KB, image/png)
2009-11-15 17:04 UTC, Andoni Morales
  Details
Snapshot 4 (261.74 KB, image/png)
2009-11-15 17:06 UTC, Andoni Morales
  Details
0003-Add-svg-pitivi-pixmpas-converted-to-png-format-for-w.patch (4.84 KB, patch)
2009-12-05 15:16 UTC, Andoni Morales
none Details | Review
0010-Add-script-based-in-py2exe-for-packaging-pitivi-in-w.patch (6.87 KB, patch)
2009-12-05 15:17 UTC, Andoni Morales
committed Details | Review
0012-Fix-glade-files-path-resolution-in-windows.patch (11.20 KB, patch)
2009-12-05 15:19 UTC, Andoni Morales
committed Details | Review
0004-Add-manually-generated-files-for-windows.patch (6.50 KB, patch)
2009-12-05 15:21 UTC, Andoni Morales
committed Details | Review
0003-Add-svg-pitivi-pixmpas-converted-to-png-format-for-w.patch (14.19 KB, patch)
2009-12-05 15:24 UTC, Andoni Morales
committed Details | Review

Description Andoni Morales 2009-11-15 16:18:31 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
Comment 1 Andoni Morales 2009-11-15 16:19:05 UTC
Created attachment 147776 [details] [review]
2nd patch
Comment 2 Andoni Morales 2009-11-15 16:19:52 UTC
Created attachment 147777 [details] [review]
3rd patch
Comment 3 Andoni Morales 2009-11-15 16:20:41 UTC
Created attachment 147778 [details] [review]
4th patch
Comment 4 Andoni Morales 2009-11-15 16:21:12 UTC
Created attachment 147779 [details] [review]
0005-Don-t-search-a-None-var.patch
Comment 5 Andoni Morales 2009-11-15 16:24:07 UTC
Created attachment 147780 [details] [review]
0001-Disable-device-probing-on-Windows.patch
Comment 6 Andoni Morales 2009-11-15 16:24:38 UTC
Created attachment 147781 [details] [review]
0002-Retrieve-the-window-xid-using-the-right-method-in-Wi.patch
Comment 7 Andoni Morales 2009-11-15 16:25:08 UTC
Created attachment 147782 [details] [review]
0003-Add-PNG-pixmaps-for-the-Windows-version.patch
Comment 8 Andoni Morales 2009-11-15 16:25:58 UTC
Created attachment 147783 [details] [review]
0004-Add-manually-generated-files-for-windows.patch
Comment 9 Andoni Morales 2009-11-15 16:26:29 UTC
Created attachment 147784 [details] [review]
0005-Handle-data-files-in-the-root-dir-on-windows.patch
Comment 10 Andoni Morales 2009-11-15 16:27:04 UTC
Created attachment 147785 [details] [review]
0006-Don-t-search-a-None-var.patch
Comment 11 Andoni Morales 2009-11-15 16:29:30 UTC
Created attachment 147786 [details] [review]
0008-Use-USERPROFILE-instead-of-HOME-in-windows.patch
Comment 12 Andoni Morales 2009-11-15 16:30:29 UTC
Created attachment 147787 [details] [review]
0009-Add-Pitivi-s-windows-icon.patch
Comment 13 Andoni Morales 2009-11-15 16:30:59 UTC
Created attachment 147788 [details] [review]
0010-Add-script-based-in-py2exe-for-packaging-pitivi-in-w.patch
Comment 14 Andoni Morales 2009-11-15 16:31:23 UTC
Created attachment 147789 [details] [review]
0011-Add-innosetup-script-for-the-windows-installer.patch
Comment 15 Andoni Morales 2009-11-15 16:42:04 UTC
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"
Comment 16 Andoni Morales 2009-11-15 16:55:27 UTC
Created attachment 147793 [details] [review]
0007-1-Add-external-dependencies-for-the-windows-build
Comment 17 Andoni Morales 2009-11-15 16:56:36 UTC
Created attachment 147794 [details] [review]
0007-2-Add-external-dependencies-for-the-windows-build.patch
Comment 18 Andoni Morales 2009-11-15 17:02:50 UTC
Created attachment 147795 [details]
Snapshot1
Comment 19 Andoni Morales 2009-11-15 17:03:29 UTC
Created attachment 147796 [details]
Snapshot 2
Comment 20 Andoni Morales 2009-11-15 17:04:20 UTC
Created attachment 147797 [details]
Snapshot 3
Comment 21 Andoni Morales 2009-11-15 17:06:11 UTC
Created attachment 147798 [details]
Snapshot 4
Comment 22 Andoni Morales 2009-11-15 17:36:15 UTC
I have updated the installer with Gtk themes support!
Comment 23 Edward Hervey 2009-11-16 07:20:25 UTC
*** Bug 432900 has been marked as a duplicate of this bug. ***
Comment 24 Edward Hervey 2009-11-16 07:43:09 UTC
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).
Comment 25 Andoni Morales 2009-11-16 09:25:59 UTC
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.
Comment 26 tin2tin 2009-11-16 10:09:12 UTC
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! :)
Comment 27 Andoni Morales 2009-11-16 11:36:49 UTC
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
Comment 28 tin2tin 2009-11-16 12:32:39 UTC
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.
Comment 29 Andoni Morales 2009-11-16 14:52:04 UTC
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?
Comment 30 Andoni Morales 2009-11-16 15:00:12 UTC
(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.
Comment 31 tin2tin 2009-11-16 20:05:10 UTC
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?
Comment 32 Andoni Morales 2009-11-16 23:38:17 UTC
(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 :) )
Comment 33 tin2tin 2009-11-17 15:05:19 UTC
No worries. I'm just amazed that it is at all possible to port Pitivi and I hope to help out by testing it. :)
Comment 34 Andoni Morales 2009-11-18 01:54:19 UTC
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.
Comment 35 tin2tin 2009-11-18 07:34:12 UTC
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.
Comment 36 Andoni Morales 2009-12-05 15:16:04 UTC
Created attachment 149157 [details] [review]
0003-Add-svg-pitivi-pixmpas-converted-to-png-format-for-w.patch
Comment 37 Andoni Morales 2009-12-05 15:17:36 UTC
Created attachment 149158 [details] [review]
0010-Add-script-based-in-py2exe-for-packaging-pitivi-in-w.patch
Comment 38 Andoni Morales 2009-12-05 15:19:43 UTC
Created attachment 149159 [details] [review]
0012-Fix-glade-files-path-resolution-in-windows.patch
Comment 39 Andoni Morales 2009-12-05 15:21:52 UTC
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.
Comment 40 Andoni Morales 2009-12-05 15:24:55 UTC
Created attachment 149161 [details] [review]
0003-Add-svg-pitivi-pixmpas-converted-to-png-format-for-w.patch
Comment 41 tin2tin 2009-12-06 09:03:00 UTC
Is there a new build of the installer as well? :)
Comment 42 Andoni Morales 2009-12-07 09:34:33 UTC
I'll try to upload a new installer before wednesday :)
Comment 43 tin2tin 2010-01-04 23:15:03 UTC
Any luck with the windows build yet? :)
Comment 44 Edward Hervey 2010-04-28 16:21:49 UTC
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 45 Edward Hervey 2010-04-28 16:23:58 UTC
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
Comment 46 Edward Hervey 2010-04-28 16:25:26 UTC
Andoni, could you test building again with pitivi head ? If it's all good for you, I'll close this bug.
Comment 47 Tobias Mueller 2010-06-16 13:19:15 UTC
Andoni, Ping.
Comment 48 Andoni Morales 2010-06-16 13:22:22 UTC
Pong. I think the this bug can be closed now.
Comment 49 tin2tin 2010-06-16 14:03:21 UTC
Meaning... is there a working build up somewhere for testing?
Comment 50 Andoni Morales 2010-06-16 14:46:33 UTC
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 :(
Comment 51 tin2tin 2010-06-17 07:29:34 UTC
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.
Comment 52 Tobias Mueller 2010-11-03 20:39:26 UTC
Closing as per comment 48. Please file new bugs for new issues. Thanks.