PhotoFlow as a GIMP plug-in - now usable!

Ok, I have added in the initial post a (hopefully exhaustive) list of build dependencies, something I should have done from the very beginning…

The additional missing dependency is libpugixml-dev. If you already got to the point of starting the compilation process, that should be the last missing one.

By the way, I must include pugixml among the packages that are tested by cmake…

Hello, finally I managed to compile PhotoFlow, that took 28 minutes using only one core. Some remarks.

  1. The command in your first post:

does not work because there is no directory Release/share/photoflow/plug-in, neither does the file pfgimp.

  1. There is an executable called photoflow though in the directory build/Release/bin. I can start that and see the screenshot as shown in your first post. The first two photos I opened were scrambled after using the curve tool (weird stripes and colors). A third one reacted better. When I tried to save it as a tiff, the application crashed. Hmmm…

  2. I copied the executable to $HOME/.config/GIMP/2.9/plug-ins/ and started GIMP 2.9. Where exactly can I find your plug-in? I don’t see it. I must open a raw from within GIMP? That opens only a 160x120px thumbnail. Ah, I see now that you wrote that I must double click a raw file. But that only opens the same thumbnail in GIMP…

  3. AHA, I need to install the dev packages for GIMP 2.9, that might do the trick. But that’s for developers, not for interested end users! So I stop here.

Yes! As I wrote in the initial post:

In fact, the development packages are not really for developers, they simply provide the header files and libraries needed to compile plug-ins from sources. Nothing will change in your GIMP set-up, since the development packages do not provide another executable. Here “development” does not mean “unstable” but “additional files from the same GIMP version you have already installed”.

So it is safe to install those development packages, as they are needed to generate the "pfgimp plug-in. After that, the photoflow window should open up automatically when you try to open a RAW file in GIMP, as you said.

Hello, I added libgimp2.0-dev to the mix and recompiled, but apparently this is not the right package. The description of that package is “Headers and other files for compiling plugins for GIMP”, so I thought that must be that one. Any idea which packages are missing?

Which version of GIMP have you installed? The plug-in only works with GIMP 2.9.x, installed in my case via Otto’s PPA.

If you are using gimp 2.8 and do not want to upgrade, please let me know and I’ll try to quickly add support for earlier GIMP versions, although you will loose the advantage of 32 bits floating-point precision…

If you are already using GIMP 2.9 packages, could you post the result of the cake command (or a full build log if it is easier for you…)?

Thanks!

Hello, yes running 2.9 here via the usual ppa (Otto’s). No idea what cake is or where I can find a full build log. I just tried to compile your plug-in and that did not work, so next time better! :wink:

Damn automated corrector!!! I meant to write cmake but it seems that my OSX system prefers cakes to build tools…

One thing we should verify is if your PhotoFlow git clone point to the stable branch and not the default master one… what do you get if you run the following command in the PhotoFlow folder:

git branch

If you do not get an asterisk in correspondence of the stable branch, then you need to switch to that first:

git checkout stable

You can then run the git branch command again to verify that the current branch has changed.

As for the build log, simply redirecting the output of the build_all.sh script to a file, and then sending me that output would be enough:

./build_all.sh >& build.log

To save time, since you already compiled VIPS successfully, you can edit the build_all.sh script and set

rebuild_VIPS=0

to avoid re-building VIPS again and gain…

Hi Carmelo,
You must add : OpenEXR and vips>=7.42.0 in the needed modules in plus, please!
here in my Linux Mint Rosa 17.3, I need add it too.
Patrick D.

1 Like

Hi @Patrick_Depoix ! Thanks for the heads up, I have added OpenEXR to the list of required development packages.

Concerning VIPS, it is already listed separately:

I have follow your explanations with ./build_all.sh at the place.
but i havn’t obtained the plugin folder in my Release folder?

What is the output of

ls Release

Thanks!

patrinux@patrinux-ordi ~/PhotoFlow/build $ ls Release
bin
CMakeCache.txt
CMakeFiles
cmake_install.cmake
CPackConfig.cmake
CPackSourceConfig.cmake
data
install_manifest.txt
Makefile
po
share
src

I can add that in /home/patrinux/PhotoFlow/build/Release/share/photoflow
there are not the plugin folder with pfgimp?

Strange… could you send me a private message with the full output of the

make install

command?

So you must add this libgegl-0.2-0 and libgimp2.0-dev
to your long list of required build dependencies too!

Photoflow compiles without complaint as in post #1.
but gives no Release/share/photoflow/plug-in directory…
Trying to launch the executable photoflow gives:

/PhotoFlow/build/Release/bin/photoflow
terminate called after throwing an instance of ‘Glib::ConvertError’
exePath: Abandon (core dumped)

Grrr ?

Hi!

Concerning the plug-in, I am in the process of completely changing the way the plug-in is implemented and invoked. I’ll post a message when this will be finished and tested, meanwhile you can get an idea of what is going on from here.
Shortly speacking, the normal photoflow executable is now also acting as the plug-in, and there is a small wrapper code that should be compiled as the actual GIMP plug-in and that takes care of invoking the photoflow command with the appropriate parameters.

Concerning, the Glib error, I have no idea what could be the reason… could you re-configure and re-compile photoflow with -DCMAKE_BUILD_TYPE=Test and then run the executable with gdb, so that we can see where exactly the code is failing?

Thanks!

Hi, signore Ferrero!
Building pf-gimp works with (see attachment) !!

(some problems to open a raw file solved uninstalling darktable, I dont like photosh… interfaces)
I use PF only for what Gimp does not make: I use gmic, lensfun, persp correction… only with Gimp.

Tried to build PF as DrRaw said:

(gdb) run

Not an expert with gdb… but if I can try something to help

Best regards

Le vendredi 17 février 2017 11:07:50 CET, vous avez écrit :

Salve, signor Alex ;-)!!!

attachments seem not to be stored when you answer messages here, unfortunately…

Concerning how to use gdb, here is the basics:

  • start gdb with the full path to the photoflow executable as parameter

  • when photoflow crashes, write the following at the gdb prompt:

    thread apply all bt

  • send me the full output of the gdb backtrace

Do not hesitate to ask further questions if something is not clear!

¡Hola señor!

Attachment was GitHub - aferrero2707/PhFGimp from yesterday.

gdb Photoflow (if no mistake), hope it helps:

(gdb) run 
Starting program: /home/ego/Système/PhotoFlow/build/Release/bin/photoflow  
[Thread debugging using libthread_db enabled] 
Using host libthread_db library "/usr/lib/libthread_db.so.1". 
terminate called after throwing an instance of 'Glib::ConvertError' 
exePath:  
Program received signal SIGABRT, Aborted. 
0x00007fffef28e04f in raise () from /usr/lib/libc.so.6 
(gdb) thread apply all bt 

Thread 1 (Thread 0x7ffff7f85980 (LWP 15303)): 
#0  0x00007fffef28e04f in raise () at /usr/lib/libc.so.6 
#1  0x00007fffef28f47a in abort () at /usr/lib/libc.so.6 
#2  0x00007fffefba54ed in __gnu_cxx::__verbose_terminate_handler() () 
   at /build/gcc/src/gcc/libstdc++-v3/libsupc++/vterminate.cc:95 
#3  0x00007fffefba32a6 in __cxxabiv1::__terminate(void (*)()) (handler=<optimized out>) 
   at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:47 
#4  0x00007fffefba32f1 in std::terminate() () at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:57 
#5  0x00007fffefba3508 in __cxxabiv1::__cxa_throw(void*, std::type_info*, void (*)(void*)) (obj=0x1df6870, tinfo=0x7ffff2623c
d0 <typeinfo for Glib::ConvertError>, dest=0x7ffff23e84e0 <Glib::ConvertError::~ConvertError()>) 
   at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_throw.cc:87                                                               
#6  0x00007ffff23e8367 in Glib::ConvertError::throw_func(_GError*) () at /usr/lib/libglibmm-2.4.so.1                          
#7  0x00007ffff23fdc6e in Glib::Error::throw_exception(_GError*) () at /usr/lib/libglibmm-2.4.so.1                            
#8  0x00007ffff24099b2 in Glib::operator<<(std::ostream&, Glib::ustring const&) () at /usr/lib/libglibmm-2.4.so.1 
#9  0x00000000008739f1 in PF::PhotoFlow::PhotoFlow() (this=0x1df5a60) 
   at /home/ego/Système/PhotoFlow/src/base/photoflow.cc:219 
#10 0x0000000000875025 in PF::PhotoFlow::Instance() () at /home/ego/Système/PhotoFlow/src/base/photoflow.cc:291 
#11 0x000000000058269c in main(int, char**) (argc=<optimized out>, argv=<optimized out>) 
   at /home/ego/Système/PhotoFlow/src/main.cc:198 
(gdb) 

Le vendredi 17 février 2017 23:04:19 CET, vous avez écrit :

It might be that photoflow is not handling correctly the UTF8 characters in your path (you have a folder called Système).

Would you have the possibility to compile photoflow in a path with only standard characters?

From my side I will see if I can reproduce the problem…

Thanks!