{"id":6044,"date":"2022-02-20T17:37:46","date_gmt":"2022-02-20T16:37:46","guid":{"rendered":"https:\/\/olivier.hoarau.org\/?p=6044"},"modified":"2022-02-20T17:37:46","modified_gmt":"2022-02-20T16:37:46","slug":"traitement-dimages-avec-gmic-3-0","status":"publish","type":"post","link":"https:\/\/olivier.hoarau.org\/?p=6044","title":{"rendered":"Traitement d&rsquo;images avec g&rsquo;mic 3.0"},"content":{"rendered":"\n<p>Il y a quelques temps j&rsquo;avais pr\u00e9sent\u00e9 bri\u00e8vement dans <a href=\"https:\/\/olivier.hoarau.org\/?p=4047\">un pr\u00e9c\u00e9dent post<\/a>  <strong>Darktable<\/strong>, c&rsquo;est un outil particuli\u00e8rement puissant pour traiter les photos en mode raw et qui n&rsquo;a rien \u00e0 envier \u00e0 des outils comme <a href=\"https:\/\/www.adobe.com\/fr\/products\/photoshop-lightroom.html\">Lightroom<\/a> d&rsquo;Adobe.  En contrepartie, ce n&rsquo;est pas un outil facile qui demande de l&rsquo;investissement avant de pouvoir bien l&rsquo;exploiter. Il existe des solutions un peu plus simples et moins puissantes mais qui seront suffisantes la plupart du temps quand on n&rsquo;est pas trop difficile. C&rsquo;est le cas de <strong>G&rsquo;MIC <\/strong>qui s&rsquo;interface avec <strong>GIMP<\/strong> avec <strong>G&rsquo;MIC-Qt<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" width=\"474\" height=\"272\" src=\"https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?resize=474%2C272&#038;ssl=1\" alt=\"\" class=\"wp-image-6045\" srcset=\"https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?resize=1024%2C587&amp;ssl=1 1024w, https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?resize=300%2C172&amp;ssl=1 300w, https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?resize=768%2C440&amp;ssl=1 768w, https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?resize=1536%2C881&amp;ssl=1 1536w, https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?w=1883&amp;ssl=1 1883w, https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?w=948&amp;ssl=1 948w, https:\/\/i0.wp.com\/olivier.hoarau.org\/wp-content\/uploads\/gimp-gmic.jpg?w=1422&amp;ssl=1 1422w\" sizes=\"auto, (max-width: 474px) 100vw, 474px\" \/><\/a><figcaption>G&rsquo;MIC<\/figcaption><\/figure>\n\n\n\n<p>Un <a href=\"https:\/\/linuxfr.org\/news\/sortie-de-g-mic-3-0-une-troisieme-dose-pour-un-traitement-efficace-de-vos-images\">article r\u00e9cent sur linuxfr <\/a>pr\u00e9sente assez bien cet outil et les nouveaut\u00e9s qu&rsquo;apportent la nouvelle version. <strong>G&rsquo;MIC <\/strong>est disponible dans la plupart des distributions r\u00e9centes, mais dans le cas o\u00f9 une installation via les sources vous int\u00e9resse pour pouvoir b\u00e9n\u00e9ficier de la derni\u00e8re version, voici les \u00e9tapes \u00e0 suivre.<\/p>\n\n\n\n<!--more-->\n\n\n\n<p>On r\u00e9cup\u00e8rera les sources par <a href=\"https:\/\/gmic.eu\/download.html\">ici<\/a> et on tapera ensuite les commandes suivantes :<\/p>\n\n\n\n<div style=\"height: 250px; position:relative; margin-bottom: 50px;\" class=\"wp-block-simple-code-block-ace\"><pre class=\"wp-block-simple-code-block-ace\" style=\"position:absolute;top:0;right:0;bottom:0;left:0\" data-mode=\"php\" data-theme=\"monokai\" data-fontsize=\"14\" data-lines=\"Infinity\" data-showlines=\"true\" data-copy=\"false\">tar xvfz gmic_3.0.2.tar.gz\ncd gmic-3.0.2\nmkdir build\ncd build\ncmake .. -DENABLE_OPENCV=ON<\/pre><\/div>\n\n\n\n<p>Voil\u00e0 une partie du r\u00e9sultat<\/p>\n\n\n\n<div style=\"height: 250px; position:relative; margin-bottom: 50px;\" class=\"wp-block-simple-code-block-ace\"><pre class=\"wp-block-simple-code-block-ace\" style=\"position:absolute;top:0;right:0;bottom:0;left:0\" data-mode=\"php\" data-theme=\"monokai\" data-fontsize=\"14\" data-lines=\"Infinity\" data-showlines=\"true\" data-copy=\"false\">-- Checking for module 'fftw3>=3.0'\n--   Found fftw3, version 3.3.9\n-- Found Fftw: fftw3  \n-- Checking for module 'opencv4'\n--   Found opencv4, version 4.5.4\n-- Found OpenCV: opencv_gapi;opencv_stitching;opencv_alphamat;opencv_aruco;opencv_barcode;opencv_bgsegm;opencv_bioinspired;opencv_ccalib;opencv_dnn_objdetect;opencv_dnn_superres;opencv_dpm;opencv_face;opencv_freetype;opencv_fuzzy;opencv_hdf;opencv_hfs;opencv_img_hash;opencv_intensity_transform;opencv_line_descriptor;opencv_mcc;opencv_quality;opencv_rapid;opencv_reg;opencv_rgbd;opencv_saliency;opencv_stereo;opencv_structured_light;opencv_phase_unwrapping;opencv_superres;opencv_optflow;opencv_surface_matching;opencv_tracking;opencv_highgui;opencv_datasets;opencv_text;opencv_plot;opencv_videostab;opencv_videoio;opencv_wechat_qrcode;opencv_xfeatures2d;opencv_shape;opencv_ml;opencv_ximgproc;opencv_video;opencv_xobjdetect;opencv_objdetect;opencv_calib3d;opencv_imgcodecs;opencv_features2d;opencv_dnn;opencv_flann;opencv_xphoto;opencv_photo;opencv_imgproc;opencv_core  \n-- Checking for module 'GraphicsMagick++'\n--   Found GraphicsMagick++, version 1.3.36\n-- Found GraphicsMagick: GraphicsMagick++;GraphicsMagick  \n-- Found TIFF: \/usr\/lib64\/libtiff.so (found version \"4.2.0\")  \n-- Found PNG: \/usr\/lib64\/libpng.so (found version \"1.6.37\") \n-- Found JPEG: \/usr\/lib64\/libjpeg.so (found version \"80\") \n-- Checking for module 'OpenEXR'\n--   Found OpenEXR, version 2.5.7\n-- Found OpenEXR: IlmImf-2_5;Imath-2_5;Half-2_5;Iex-2_5;IexMath-2_5;IlmThread-2_5  \n-- Looking for pthread.h\n-- Looking for pthread.h - found\n-- Performing Test CMAKE_HAVE_LIBC_PTHREAD\n-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed\n-- Looking for pthread_create in pthreads\n-- Looking for pthread_create in pthreads - not found\n-- Looking for pthread_create in pthread\n-- Looking for pthread_create in pthread - found\n-- Found Threads: TRUE  \n-- Found GMicStdlib: \/usr\/local\/linux\/photos\/gmic-3.0.2\/src\/gmic_stdlib.h  \n-- The following OPTIONAL packages have been found:\n\n * OpenMP\n * CURL\n * X11\n * Fftw\n * OpenCV\n * GraphicsMagick\n * TIFF\n * ZLIB\n * PNG\n * JPEG\n * PkgConfig\n * OpenEXR\n * Threads\n\n-- The following REQUIRED packages have been found:\n\n * CImg\n * GMicStdlib\n\n-- Configuring done\n-- Generating done\n-- Build files have been written to: \/usr\/local\/linux\/photos\/gmic-3.0.2\/build<\/pre><\/div>\n\n\n\n<p>On tape ensuite <strong>make<\/strong> et en tant que root <strong>make install<\/strong>. Ce n&rsquo;est pas fini, on r\u00e9cup\u00e8re <strong>G&rsquo;MIC-Qt<\/strong> par <a href=\"https:\/\/github.com\/c-koi\/gmic-qt\">l\u00e0,<\/a> on installera pr\u00e9alablement les sources de <strong>gimp<\/strong> (<strong>urpmi gimp-devel<\/strong> sur ma mageia) et on ex\u00e9cute les commandes suivantes : <\/p>\n\n\n\n<div style=\"height: 250px; position:relative; margin-bottom: 50px;\" class=\"wp-block-simple-code-block-ace\"><pre class=\"wp-block-simple-code-block-ace\" style=\"position:absolute;top:0;right:0;bottom:0;left:0\" data-mode=\"php\" data-theme=\"monokai\" data-fontsize=\"14\" data-lines=\"Infinity\" data-showlines=\"true\" data-copy=\"false\">tar xvfz gmic-qt-v.3.0.0.tar.gz\ngmic-qt-v.3.0.0\nmkdir build\ncd build\ncmake .. -DGMIC_LIB_PATH=\/usr\/local\/lib64 -DGMIC_PATH=\/usr\/local\/linux\/photos\/gmic-3.0.2\/src<\/pre><\/div>\n\n\n\n<p>Pour la derni\u00e8re commande on indiquera le chemin absolu de <strong>G&rsquo;MIC<\/strong>. Voil\u00e0 le r\u00e9sultat:<\/p>\n\n\n\n<div style=\"height: 250px; position:relative; margin-bottom: 50px;\" class=\"wp-block-simple-code-block-ace\"><pre class=\"wp-block-simple-code-block-ace\" style=\"position:absolute;top:0;right:0;bottom:0;left:0\" data-mode=\"php\" data-theme=\"monokai\" data-fontsize=\"14\" data-lines=\"Infinity\" data-showlines=\"true\" data-copy=\"false\">Build type is Release\nBuilding for target host application: gimp\nG'MIC path: \/usr\/local\/linux\/photos\/gmic-3.0.2\/src\nFound G'MIC repository\nFound \/usr\/local\/linux\/photos\/gmic-3.0.2\/src\/CImg.h\nFound \/usr\/local\/linux\/photos\/gmic-3.0.2\/src\/gmic_stdlib_community.h\nCImg version is [300]\nG'MIC version is [300]\n-- Found FFTW3_CORE \n-- FFTW core Found Libraries: \/usr\/lib64\/libfftw3.so\n-- Found FFTW3_THREADS \n-- FFTW threads Found Libraries: \/usr\/lib64\/libfftw3_threads.so\nG'Mic: using OpenMP\nLink Time Optimizer enabled\n-- Checking for module 'gimp-2.0'\n--   Found gimp-2.0, version 2.10.24\n-- The following OPTIONAL packages have been found:\n\n * CURL\n * OpenMP, A low-level parallel execution library, &lt;http:\/\/openmp.org\/wp\/>\n   Optionally used by gmic-qt\n * X11\n\n-- The following REQUIRED packages have been found:\n\n * Qt5Core\n * Qt5Gui\n * Qt5Widgets\n * Qt5Network\n * Qt5 (required version >= 5.2.0)\n * Qt5LinguistTools\n * PNG\n * ZLIB\n * FFTW3\n * PkgConfig\n\n-- Configuring done\n-- Generating done\n-- Build files have been written to: \/usr\/local\/linux\/photos\/gmic-qt-v.3.0.0\/build<\/pre><\/div>\n\n\n\n<p>On tape ensuite <strong>make<\/strong> et en tant que root <strong>make install<\/strong>. En lan\u00e7ant <strong>Gimp<\/strong>, <strong>G&rsquo;MIC<\/strong> fait son apparition au niveau du menu <strong>Filtres<\/strong>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Il y a quelques temps j&rsquo;avais pr\u00e9sent\u00e9 bri\u00e8vement dans un pr\u00e9c\u00e9dent post Darktable, c&rsquo;est un outil particuli\u00e8rement puissant pour traiter les photos en mode raw et qui n&rsquo;a rien \u00e0 envier \u00e0 des outils comme Lightroom d&rsquo;Adobe. En contrepartie, ce n&rsquo;est pas un outil facile qui demande de l&rsquo;investissement avant de pouvoir bien l&rsquo;exploiter. Il &hellip; <a href=\"https:\/\/olivier.hoarau.org\/?p=6044\" class=\"more-link\">Continuer la lecture de <span class=\"screen-reader-text\">Traitement d&rsquo;images avec g&rsquo;mic 3.0<\/span>  <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false,"_share_on_mastodon":"0"},"categories":[5],"tags":[],"class_list":["post-6044","post","type-post","status-publish","format-standard","hentry","category-logiciels-libres"],"share_on_mastodon":{"url":"","error":""},"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/peOjJ-1zu","jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=\/wp\/v2\/posts\/6044","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=6044"}],"version-history":[{"count":2,"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=\/wp\/v2\/posts\/6044\/revisions"}],"predecessor-version":[{"id":6047,"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=\/wp\/v2\/posts\/6044\/revisions\/6047"}],"wp:attachment":[{"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=6044"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=6044"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/olivier.hoarau.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=6044"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}