module inscription newsletter haut de page forum mobile

Ateliers et Formations

[Tuto] Nikon Raw metadata

Discussion dans 'Nikon' créé par moutchou, 16 Avril 2026.

  1. moutchou

    Points Repaire:
    2 050
    Recos reçues:
    4
    Messages:
    338
    Appréciations:
    +17 / 90 / -0
    Salut,

    Je lance ce sujet pour tous ceux, comme moi qui parfois ont du mal à avoir accès aux metadata de leurs rushes. En particulier pour des fichiers N-Raw c'est parfois compliqué de savoir comment ça a été filmé quelques temps après.

    Pour obtenir les infos, j'utilise exiftool pour les afficher. En revanche il s'agit d'un outil en ligne de commande, ce qui n'est pas très pratique. Du coup j'ai voulu le packager pour le rendre disponible en menu contextuel sous Windows (Clique droit --> show metadata). Rien de bien sorcier, mais voilà la procédure au cas où ça intéresse quelqu'un:
    1. Téléchargez exiftool, renommez l'outil en supprimant le (-k) du nom. Posez ça dans un répertoire. Disons "C:\Tools\ShowMetadataPortable"
    2. Installez le SDK .NET8.0 (Télécharger .NET 8.0 (Linux, macOS et Windows) | .NET
    3. Créez les 3 fichiers CS indiqués ci-dessous et posez dans un répertoire. Disons "C:\Tools\SourceCodeMetadata"
    4. Lancez PowerShell
    5. Tapez "cd C:\Tools\SourceCodeMetadata"
    6. Tapez "dotnet build -c Release". Ca doit se terminer par un succès: "Build succeeded with 1 warning(s) in 5.4s"
    7. Tapez "dotnet publish -c Release -r win-x64 --self-contained true /p:PublishSingleFile=true". Ca doit également se terminer par une ligne avec "Succeeded" (faites pas attention aux warnings).
    8. Vous pouvez maintenant copier le fichier ShowMetadata.exe dans le répertoire "C:\Tools\SourceCodeMetadata\bin\Release\net8.0-windows\win-x64\publish" et le coller dans le répertoire "C:\Tools\ShowMetadataPortable". Vous devez donc y trouver désormais le fichier "ShowMedata.exe", le fichier "exiftool.exe" et un répertoire nommé "exiftool_files"
    9. Créer le fichier .reg tel que décrit ci-dessous. Vous pouvez changer le répertoire de lancement, pour adapter l'emplacement où se trouve les fichiers détaillés à l'étape 8. Vous pouvez lancer le fichier REG.
    Et voilà !!

    Maintenant si vous faites un clic-droit sur un fichier vous avez le menu "Show metadata". Parfois il faut en plus choisir "Show more options"; c'est mon cas.

    upload_2026-4-16_21-49-45.png

    Puis le menu "Show metadata" est disponible.

    upload_2026-4-16_21-50-15.png

    Vous avez alors la fenêtre de metadata qui apparaît.

    upload_2026-4-16_21-51-15.png

    ExifTool Version Number : 13.56
    File Name : YMK_0605.NEV
    Directory : C:/Users/youss/Videos/TEMPORAIRE
    File Size : 466 MB
    File Modification Date/Time : 2026:03:19 20:28:19+01:00
    File Access Date/Time : 2026:04:16 21:49:07+02:00
    File Creation Date/Time : 2026:04:16 21:49:07+02:00
    File Permissions : -rw-rw-rw-
    File Type : MP4
    File Type Extension : mp4
    MIME Type : video/mp4
    Major Brand : Unknown (niko)
    Minor Version : 0.0.1
    Compatible Brands : niko
    Movie Header Version : 0
    Modify Date : 2026:03:19 19:28:18
    Time Scale : 24000
    Duration : 11.14 s
    Preferred Rate : 1
    Preferred Volume : 100.00%
    Preview Time : 0 s
    Preview Duration : 0 s
    Poster Time : 0 s
    Selection Time : 0 s
    Selection Duration : 0 s
    Current Time : 0 s
    Next Track ID : 3
    Track Header Version : 0
    Track Create Date : 2026:03:19 19:28:18
    Track Modify Date : 2026:03:19 19:28:18
    Track ID : 1
    Track Duration : 11.14 s
    Track Layer : 0
    Track Volume : 0.00%
    Image Width : 4040
    Image Height : 2276
    Media Language Code : und
    Graphics Mode : srcCopy
    Op Color : 0 0 0
    Compressor ID : NRAW
    Source Image Width : 4040
    Source Image Height : 2276
    X Resolution : 72
    Y Resolution : 72
    Compressor Name : NIKON RAW
    Bit Depth : 24
    Color Profiles : nclx
    Color Primaries : BT.709
    Transfer Characteristics : BT.709
    Matrix Coefficients : BT.709
    Video Full Range Flag : Full
    Video Frame Rate : 23.976
    Matrix Structure : 1 0 0 0 1 0 0 0 1
    Media Header Version : 0
    Media Create Date : 2026:03:19 19:28:18
    Media Modify Date : 2026:03:19 19:28:18
    Media Time Scale : 48000
    Media Duration : 11.14 s
    Handler Type : Audio Track
    Balance : 0
    Audio Format : lpcm
    Make : NIKON CORPORATION
    Model : NIKON ZR
    Software : NIKON ZR Ver.01.10
    Create Date : 2026:03:19 20:28:18
    Date/Time Original : 2026:03:19 20:28:18
    Frame Count : 267
    Frame Rate : 23.976
    Frame Width : 4032
    Frame Height : 2268
    Audio Channels : 2
    Audio Bits Per Sample : 32
    Audio Sample Rate : 48000
    Nikon Date Time : 2026:03:19 20:28:18
    Electronic VR : Off
    Exposure Time : 1/25
    F Number : 5.6
    Exposure Program : Manual
    Exposure Compensation : 0
    Metering Mode : Multi-segment
    Focal Length : 24.0 mm
    Serial Number : 7801808
    Lens Info : 24-120mm f/4
    Lens Make : NIKON
    Lens Model : NIKKOR Z 24-120mm f/4 S
    Lens Serial Number : 20321216
    Maker Note Version : 2.11
    White Balance : PRESET1
    Focus Mode : AF-S
    Crop Hi Speed : 16:9 Crop (6064x4040 cropped to 6064x3416 at pixel 0,312)
    VR Info Version : 0200
    Vibration Reduction : On
    VR Mode : Sport
    VR Type : In-body
    Active D-Lighting : Off
    Picture Control Version : 0311
    Picture Control Name : N-Log
    Picture Control Base : N-Log
    Picture Control Adjust : Quick Adjust
    Picture Control Quick Adjust : n/a
    Sharpness : n/a
    Mid Range Sharpness : n/a
    Clarity : n/a
    Contrast : n/a
    Brightness : n/a
    Saturation : n/a
    Hue : n/a
    Filter Effect : n/a
    Toning Effect : n/a
    Toning Saturation : n/a
    Picture Control Data : (Binary data 108 bytes, use -b option to extract)
    Time Zone : +01:00
    Daylight Savings : No
    Date Display Format : Y/M/D
    ISO : 8063
    ISO Expansion : Off
    ISO2 : 8063
    ISO Expansion 2 : Off
    Vignette Control : Normal
    White Balance Fine Tune : 0 0
    Lens Type : AF
    Lens : 24-120mm f/4
    Flash Mode : Did Not Fire
    Lens Data Version : 0802
    Lens Firmware Version : 1.1.0
    Max Aperture : 4.0
    Focus Distance : 0.528 m
    Lens Position Absolute : 31409
    Lens Mount Type : Z-mount
    Shutter Count : 94
    Vari Program :
    High ISO Noise Reduction : Normal
    AF Info 2 Version : 0402
    AF Detection Method : Hybrid
    AF Area Mode : Auto
    AF Coordinates Available : Yes
    AF Area X Position : 0
    AF Area Y Position : 0
    Focus Result : Out of Focus
    Thumbnail Image : (Binary data 8358 bytes, use -b option to extract)
    Preview Image : (Binary data 434986 bytes, use -b option to extract)
    Preview Image 1 : (Binary data 54108 bytes, use -b option to extract)
    Media Data Size : 464976376
    Media Data Offset : 524296
    Aperture : 5.6
    Image Size : 4040x2276
    Megapixels : 9.2
    Shutter Speed : 1/25
    Auto Focus : On
    Contrast Detect AF : Off
    Lens Spec : 24-120mm f/4 AF
    Avg Bitrate : 334 Mbps
    Rotation : 0
    Focal Length 35mm Equiv : 24.0 mm
    Lens ID : NIKKOR Z 24-120mm f/4 S
    Light Value : 3.3

    C'est vraiment fait à la va-vite.
    Il y a sûrement des options qu'on peut rajouter: le CTRL+F pour la recherche par exemple, filtrer pour ne rendre disponible l'option que sur les fichiers pris en charge par exiftool, regrouper les infos par bloc etc...
    Si besoin je vous laisse le faire, ou alors si j'ai le temps je les ajoute à la demande
    Il suffira alors de refaire les actions 3 à 8 avec les fichiers CS modifiés.

    N'hésitez pas à me dire ça a fonctionné pour vous !
    --------------------------------------------------



    Program.cs
    ---------------
    Code:
    using System;
    using System.Diagnostics;
    using System.IO;
    using System.Text;
    using System.Windows.Forms;
    namespace ShowMetadata {
      internal static class Program {
        [STAThread]
        static void Main(string[] args) {
          if (args.Length == 0 || !File.Exists(args[0])) {
            MessageBox.Show("Fichier invalide.", "Show metadata",
                            MessageBoxButtons.OK, MessageBoxIcon.Error);
            return;
          }
          string filePath = args[0];
          // Répertoire où se trouve ShowMetadata.exe
          string appDir = AppDomain.CurrentDomain.BaseDirectory;
          // ExifTool local
          string exifToolPath = Path.Combine(appDir, "exiftool.exe");
          if (!File.Exists(exifToolPath)) {
            MessageBox.Show(
                "exiftool.exe est introuvable.\n" +
                    "Il doit être dans le même dossier que ShowMetadata.exe",
                "Show metadata", MessageBoxButtons.OK, MessageBoxIcon.Error);
            return;
          }
          var psi = new ProcessStartInfo { FileName = exifToolPath,
                                           Arguments = $"\"{filePath}\"",
                                           RedirectStandardOutput = true,
                                           RedirectStandardError = true,
                                           UseShellExecute = false,
                                           CreateNoWindow = true,
                                           StandardOutputEncoding = Encoding.UTF8 };
          string output;
          string error;
          using (var process = Process.Start(psi)!) {
            output = process.StandardOutput.ReadToEnd();
            error = process.StandardError.ReadToEnd();
            process.WaitForExit();
          }
          // DEBUG VISUEL
          if (string.IsNullOrWhiteSpace(output)) {
            MessageBox.Show(
                "ExifTool n'a retourné aucune donnée.\n\nErreur éventuelle:\n" +
                    error,
                "Show metadata - diagnostic");
          }
          Application.EnableVisualStyles();
          Application.SetCompatibleTextRenderingDefault(false);
          Application.Run(new MetadataForm(output, filePath));
        }
      }
    }
    
    metadata.cs
    Code:
    using System;
    using System.Drawing;
    using System.IO;
    using System.Windows.Forms;
    
    namespace ShowMetadata
    {
        public class MetadataForm : Form
        {
            private RichTextBox richTextBox;
    
            public MetadataForm(string metadata, string filePath)
            {
                Text = "Show metadata – " + Path.GetFileName(filePath);
                Width = 900;
                Height = 700;
    
                richTextBox = new RichTextBox
                {
                    Dock = DockStyle.Fill,
                    ReadOnly = true,
                    Font = new Font("Consolas", 10),
                    BackColor = Color.FromArgb(30, 30, 30),
                    ForeColor = Color.White,
                    BorderStyle = BorderStyle.None
                };
    
                Controls.Add(richTextBox);
    
                ApplyColoring(metadata);
            }
    
            private void ApplyColoring(string metadata)
            {
                richTextBox.SuspendLayout();
                richTextBox.Clear();
    
                var lines = metadata.Split(new[] { "\r\n", "\n" }, StringSplitOptions.None);
    
                foreach (var line in lines)
                {
                    // Ligne vide
                    if (string.IsNullOrWhiteSpace(line))
                    {
                        richTextBox.AppendText(Environment.NewLine);
                        continue;
                    }
    
                    // Ligne de type "Nom : Valeur"
                    int colonIndex = line.IndexOf(':');
    
                    if (colonIndex > 0)
                    {
                        string name = line.Substring(0, colonIndex).TrimEnd();
                        string value = line.Substring(colonIndex + 1).TrimStart();
    
                        // Nom
                        AppendColoredText(name, Color.DeepSkyBlue);
    
                        // Espaces jusqu'au :
                        AppendColoredText(" : ", Color.Gray);
    
                        // Valeur
                        AppendColoredText(value, Color.Gainsboro);
                    }
                    else
                    {
                        // Cas inattendu → texte normal
                        AppendColoredText(line, Color.Gainsboro);
                    }
    
                    richTextBox.AppendText(Environment.NewLine);
                }
    
                richTextBox.SelectionStart = 0;
                richTextBox.SelectionLength = 0;
                richTextBox.ResumeLayout();
            }
    
            private void AppendColoredText(string text, Color color)
            {
                richTextBox.SelectionStart = richTextBox.TextLength;
                richTextBox.SelectionLength = 0;
                richTextBox.SelectionColor = color;
                richTextBox.AppendText(text);
                richTextBox.SelectionColor = richTextBox.ForeColor;
            }
        }
    }
    
    ShowMetadata.csproj
    Code:
    <Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
    
      <PropertyGroup>
        <OutputType>WinExe</OutputType>
        <TargetFramework>net8.0-windows</TargetFramework>
        <UseWindowsForms>true</UseWindowsForms>
        <Nullable>enable</Nullable>
      </PropertyGroup>
    
    </Project>
    
    AddContextMenu.reg
    Code:
    Windows Registry Editor Version 5.00
    
    [HKEY_CLASSES_ROOT\*\shell\ShowMetadata]
    @="Show metadata"
    "Icon"="C:\\Tools\\ShowMetadataPortable\\ShowMetadata.exe"
    
    [HKEY_CLASSES_ROOT\*\shell\ShowMetadata\command]
    @="\"C:\\Tools\\ShowMetadataPortable\\ShowMetadata.exe\" \"%1\""
    
     
    • Merci Merci x 1
    • J'aime J'aime x 1
  2. moutchou

    Points Repaire:
    2 050
    Recos reçues:
    4
    Messages:
    338
    Appréciations:
    +17 / 90 / -0
    Je continue ma série "afficher les metadonnées complète", plus simple à mettre en place, mais nécessitant la version Studio de Davinci Resolve 20.

    Tout d'abord un grand merci à.... Lumo (l'IA de Proton), qui m'a bien aidé sur le sujet :D

    Sous Windows, puisque je ne connais que exiftool sous windows...
    1. Créez des fichiers exiftool_viewer.lua ou appelez-les comme vous voulez (cf ci-dessous).
    2. Placez-le dans : C:\ProgramData\Blackmagic Design\DaVinci Resolve\Fusion\Scripts\Utility
    3. Redémarrez Resolve.
    4. Sélectionnez un élément dans le media pool
    5. Lancer Workspace → Scripts → exiftool_viewer.
    Note: je considère que exiftool est disponible ici: C:\\Tools\\ShowMetadataPortable\
    Je vous laisse modifier le script en cohérence.

    local app = Resolve()
    if not app then
    print("ERREUR: Application Resolve non disponible")
    return
    end
    print("=== MÉTADONNÉES EXIFTOOL ===")
    local project = app:GetProjectManager():GetCurrentProject()
    if not project then
    print("ERREUR: Aucun projet ouvert")
    return
    end
    local mediaPool = project:GetMediaPool()
    if not mediaPool then
    print("ERREUR: Media Pool indisponible")
    return
    end
    -- Obtenir les clips sélectionnés
    local selectedClips = mediaPool:GetSelectedClips()
    if not selectedClips or #selectedClips == 0 then
    print("ERREUR: Aucun clip sélectionné")
    print("Veuillez sélectionner un clip dans le Media Pool.")
    return
    end
    local clip = selectedClips[1]
    local clipName = clip:GetName()
    print("Clip: " .. clipName)
    -- Extraire le chemin du fichier
    local props = clip:GetClipProperty()
    local filePath = props["File Path"]
    if not filePath or filePath == "" then
    print("ERREUR: Impossible d'obtenir le chemin du fichier")
    return
    end
    print("Chemin: " .. filePath)
    -- Chemin vers exiftool
    local exiftoolPath = "C:\\Tools\\ShowMetadataPortable\\exiftool.exe"
    -- Créer un fichier batch pour exécuter exiftool
    local batchFile = os.getenv("TEMP") .. "\\run_exiftool.bat"
    local outputFile = os.getenv("TEMP") .. "\\exiftool_output.txt"
    -- Écrire le contenu du batch
    local batchContent = string.format(
    '@echo off\n"%s" "%s" > "%s" 2>&1\n',
    exiftoolPath, filePath, outputFile
    )
    local batch = io.open(batchFile, "w")
    if not batch then
    print("ERREUR: Impossible de créer le fichier batch")
    return
    end
    batch:write(batchContent)
    batch:close()
    print("Fichier batch créé: " .. batchFile)
    -- Exécuter le batch (silencieusement)
    os.execute('start /B cmd /c "' .. batchFile .. '"')
    -- Attendre un peu que exiftool termine
    print("Attente de l'exécution...")
    local startTime = os.time()
    while os.time() - startTime < 10 do
    local testFile = io.open(outputFile, "r")
    if testFile then
    testFile:close()
    break
    end
    os.execute("timeout /t 1 >nul 2>nul")
    end
    -- Lire le résultat
    local resultFile = io.open(outputFile, "r")
    if not resultFile then
    print("ERREUR: Impossible de lire le fichier de sortie")
    print("Vérifiez manuellement dans le terminal:")
    print('"' .. exiftoolPath .. '" "' .. filePath .. '"')
    return
    end
    local result = resultFile:read("*a")
    resultFile:close()
    -- Nettoyer les fichiers temporaires
    os.remove(batchFile)
    if result == "" then
    print("ERREUR: Aucune métadonnée retournée par exiftool")
    return
    end
    -- Afficher dans la console
    print("")
    print("========================================")
    print(result)
    print("========================================")
    print("Fin des métadonnées")

    local app = Resolve()
    if not app then return end
    local project = app:GetProjectManager():GetCurrentProject()
    local mediaPool = project:GetMediaPool()
    local selectedClips = mediaPool:GetSelectedClips()
    if not selectedClips or #selectedClips == 0 then
    print("ERREUR: Aucun clip sélectionné")
    return
    end
    local clip = selectedClips[1]
    local props = clip:GetClipProperty()
    local filePath = props["File Path"]
    if not filePath then
    print("ERREUR: Pas de chemin")
    return
    end
    -- Créer un fichier batch qui ouvre une fenêtre
    local batchFile = os.getenv("TEMP") .. "\\exiftool_view.bat"
    local batchContent = string.format(
    '@echo off\ntitle Métadonnées ExifTool\ncolor 0A\n"%s" "%s"\npause',
    "C:\\Tools\\ShowMetadataPortable\\exiftool.exe", filePath
    )
    local batch = io.open(batchFile, "w")
    batch:write(batchContent)
    batch:close()
    print("Fenêtre exiftool s'ouvre...")
    os.execute('start "" "' .. batchFile .. '"')

    local app = Resolve()
    if not app then
    print("ERREUR: Application Resolve non disponible")
    return
    end
    print("=== GÉNÉRATION DES MÉTADONNÉES ===")
    local project = app:GetProjectManager():GetCurrentProject()
    if not project then
    print("ERREUR: Aucun projet ouvert")
    return
    end
    local mediaPool = project:GetMediaPool()
    if not mediaPool then
    print("ERREUR: Media Pool indisponible")
    return
    end
    -- Obtenir les clips sélectionnés
    local selectedClips = mediaPool:GetSelectedClips()
    if not selectedClips or #selectedClips == 0 then
    print("ERREUR: Aucun clip sélectionné")
    return
    end
    local clip = selectedClips[1]
    local clipName = clip:GetName()
    -- Extraire le chemin
    local props = clip:GetClipProperty()
    local filePath = props["File Path"]
    if not filePath or filePath == "" then
    print("ERREUR: Impossible d'obtenir le chemin")
    return
    end
    -- Chemin exiftool
    local exiftoolPath = "C:\\Tools\\ShowMetadataPortable\\exiftool.exe"
    -- Créer un fichier batch temporaire pour exécuter exiftool
    local batchFile = os.getenv("TEMP") .. "\\run_exiftool_popup.bat"
    local outputFile = os.getenv("TEMP") .. "\\exiftool_popup_output.txt"
    local batchContent = string.format(
    '@echo off\n"%s" "%s" > "%s" 2>&1\n',
    exiftoolPath, filePath, outputFile
    )
    local batch = io.open(batchFile, "w")
    if not batch then
    print("ERREUR: Impossible de créer le fichier batch")
    return
    end
    batch:write(batchContent)
    batch:close()
    -- Exécuter silencieusement
    os.execute('start /B cmd /c "' .. batchFile .. '"')
    -- Attendre que le fichier soit créé (max 10s)
    local startTime = os.time()
    while os.time() - startTime < 10 do
    local testFile = io.open(outputFile, "r")
    if testFile then
    testFile:close()
    break
    end
    os.execute("timeout /t 1 >nul 2>nul")
    end
    -- Lire le résultat
    local resultFile = io.open(outputFile, "r")
    if not resultFile then
    print("ERREUR: Impossible de lire le fichier de sortie")
    os.remove(batchFile)
    return
    end
    local result = resultFile:read("*a")
    resultFile:close()
    -- Nettoyer
    os.remove(batchFile)
    if result == "" then
    print("ERREUR: Aucune métadonnée")
    return
    end
    -- Limiter la taille pour éviter de planter la fenêtre (max 50000 caractères)
    if #result > 50000 then
    result = result:sub(1, 50000) .. "\n\n... (texte tronqué pour affichage)"
    end
    -- Remplacer les sauts de ligne pour l'affichage (optionnel, selon préférence)
    -- result = result:gsub("\r\n", "\n")
    -- Afficher dans une fenêtre native Resolve
    -- Note: bmd.ShowMessage est parfois indisponible en script externe,
    -- mais essayons d'abord. Si ça échoue, on utilise print().
    if bmd and bmd.ShowMessage then
    bmd.ShowMessage(result, "Métadonnées ExifTool - " .. clipName)
    print("Fenêtre native affichée.")
    else
    -- Fallback: afficher dans la console si ShowMessage n'est pas dispo
    print("Fenêtre native non disponible, affichage dans la console :")
    print("========================================")
    print(result)
    print("========================================")

    -- Alternative: ouvrir dans le Bloc-notes si la fenêtre native échoue
    local tempView = os.getenv("TEMP") .. "\\exiftool_view.txt"
    local viewFile = io.open(tempView, "w")
    viewFile:write(result)
    viewFile:close()
    print("Fichier temporaire créé : " .. tempView)
    print("Ouverture automatique...")
    os.execute('start "" "' .. tempView .. '"')
    end
    print("=== FIN ===")
     
    #2 moutchou, 18 Avril 2026
    Dernière édition: 18 Avril 2026
  3. moutchou

    Points Repaire:
    2 050
    Recos reçues:
    4
    Messages:
    338
    Appréciations:
    +17 / 90 / -0
    Je mets ci-dessous un script qui fonctionne sous windows (ouverture dans le Bloc Note) et MacOS (ouverture dans TextEdit).

    Installation MacOS:
    1. Installez exiftool pour MacOS
    2. Créez le répertoire Utility s'il n'existe pas
      Code:
      mkdir -p ~/Library/Application\ Support/Blackmagic\ Design/DaVinci\ Resolve/Fusion/Scripts/Utility
    3. Posez le fichier lua (voir ci-dessous)
    4. Modifier les fichiers de fichier en fonction de votre installation

    local app = Resolve()
    if not app then return end
    local project = app:GetProjectManager():GetCurrentProject()
    local mediaPool = project:GetMediaPool()
    local selectedClips = mediaPool:GetSelectedClips()
    if not selectedClips or #selectedClips == 0 then
    print("ERREUR: Aucun clip sélectionné")
    return
    end
    local clip = selectedClips[1]
    local props = clip:GetClipProperty()
    local filePath = props["File Path"]
    if not filePath then
    print("ERREUR: Pas de chemin")
    return
    end
    -- Détection du système
    local isWindows = package.config:sub(1,1) == "\\"
    -- Chemin exiftool
    local exiftoolPath = isWindows and "C:\\Tools\\ShowMetadataPortable\\exiftool.exe" or "/usr/local/bin/exiftool"
    -- Chemin temporaire
    local tempDir = isWindows and os.getenv("TEMP") or "/tmp"
    -- Création fichier batch (Windows) ou exécution directe (macOS)
    if isWindows then
    local batchFile = tempDir .. "\\run_exiftool.bat"
    local outputFile = tempDir .. "\\exiftool_output.txt"
    local batchContent = string.format('@echo off\n"%s" "%s" > "%s" 2>&1\n', exiftoolPath, filePath, outputFile)

    local batch = io.open(batchFile, "w")
    batch:write(batchContent)
    batch:close()

    os.execute('start /B cmd /c "' .. batchFile .. '"')

    -- Attente
    for i = 1, 15 do
    local testFile = io.open(outputFile, "r")
    if testFile then testFile:close(); break end
    os.execute("timeout /t 1 >nul 2>nul")
    end

    -- Lecture
    local resultFile = io.open(outputFile, "r")
    local result = resultFile and resultFile:read("*a") or ""
    if resultFile then resultFile:close() end
    os.remove(batchFile)

    -- Ouverture
    local finalFile = tempDir .. "\\exiftool_" .. clip:GetName():gsub("[^%w]", "_") .. ".txt"
    local outFile = io.open(finalFile, "w")
    outFile:write(result)
    outFile:close()
    os.execute('start "" "' .. finalFile .. '"')

    else
    -- macOS
    local outputFile = tempDir .. "/exiftool_output_" .. os.time() .. ".txt"
    local cmd = string.format('"%s" "%s" > "%s" 2>&1', exiftoolPath, filePath, outputFile)

    local handle = io.popen(cmd)
    if handle then handle:close() end

    -- Attente
    for i = 1, 15 do
    local testFile = io.open(outputFile, "r")
    if testFile then testFile:close(); break end
    os.execute("sleep 1")
    end

    -- Lecture
    local resultFile = io.open(outputFile, "r")
    local result = resultFile and resultFile:read("*a") or ""
    if resultFile then resultFile:close() end
    os.remove(outputFile)

    -- Ouverture
    local finalFile = tempDir .. "/exiftool_" .. clip:GetName():gsub("[^%w]", "_") .. ".txt"
    local outFile = io.open(finalFile, "w")
    outFile:write(result)
    outFile:close()
    os.execute('open "' .. finalFile .. '"')
    end
    print("=== FIN ===")

    N'ayant pas de MacOS, et donc pas de DVR Studio installé sur cet OS, je ne peux pas vérifier que ça fonctionne comme prévu.
    Si l'un de vous veut bien tester, je suis preneur.
     
  4. caraibe

    Points Repaire:
    16 200
    Recos reçues:
    260
    Messages:
    24 642
    Appréciations:
    +628 / 2 000 / -89
    Merci pour tes infos mais uniquement valables pour le Raw de ton Nikon
    Sur un mp4 en hevc tu les as aussi ???
    j'ai testé mais je ne suis pas arrivé à avoir les métadonnées d'exposition
    Avec Sony je sais pas où sont les métadonnées
    Même pas dans le XML associées aux mp4 :sad:
    Vrai que c'est bien de pouvoir y accéder et revoir les paramètres d'exposition .
     
  5. AQW333

    So

    Points Repaire:
    17 700
    Recos reçues:
    314
    Messages:
    13 720
    Appréciations:
    +852 / 3 460 / -32
    Normalement pour Sony il faut passer par Catalyse ...
     
    • Merci Merci x 1
  6. moutchou

    Points Repaire:
    2 050
    Recos reçues:
    4
    Messages:
    338
    Appréciations:
    +17 / 90 / -0
    Ca utilise l'outil exiftool. Donc faut plutôt voir ce que lui fournit de manière directe.
    Ce que je propose ci-dessus c'est une manière de lancer l'outil via l'explorateur windows ou via un menu intégré à Davinci.
    La liste des formats supportés par exiftool est tout de même impréssionnante je trouve.
     
  7. caraibe

    Points Repaire:
    16 200
    Recos reçues:
    260
    Messages:
    24 642
    Appréciations:
    +628 / 2 000 / -89
    C'est simple voyons :sad:
    Merci en tout cas
     
    #7 caraibe, 20 Avril 2026
    Dernière édition par un modérateur: 20 Avril 2026
  8. moutchou

    Points Repaire:
    2 050
    Recos reçues:
    4
    Messages:
    338
    Appréciations:
    +17 / 90 / -0
    Oui désolé c'est ce que j'ai trouvé de plus simple. Pas forcément évidemment les applications sous windows.
    Je vais essayer de trouver une solution plus simplifie.
    Je peux aussi fournir le .exe qui est généré entre les étapes 2 à 7.
    Mais je me méfie de windows. Ce qui fonctionne sur une machine ne fonctionne pas forcément sur l'autre.
     
    • Merci Merci x 1
  9. moutchou

    Points Repaire:
    2 050
    Recos reçues:
    4
    Messages:
    338
    Appréciations:
    +17 / 90 / -0
    Bon en fait je me suis enquiquiné pour pas grand chose.
    Y a pas tellement besoin de tout le barnum de build.

    Etapes simples (sous windows):
    1. Télécharger exiftool.
    2. Dézipper ça dans un répertoire. Disons "C:\Tools\ShowMetadataPortable"
    3. Créer le fichier .reg tel que décrit ci-dessous. Vous pouvez changer le répertoire de lancement, pour adapter l'emplacement où se trouve les fichiers.
    4. lancer le fichier REG.
    Voilà, vous l'avez à dispo en menu contextuel (ne pas oublier de regarder dans "show more options").

    Windows Registry Editor Version 5.00

    [HKEY_CLASSES_ROOT\*\shell\ExifMetadata]
    @="Medata (exif)"
    "Icon"="C:\\Tools\\ShowMetadataPortable\\exiftool.exe"

    [HKEY_CLASSES_ROOT\*\shell\ExifMetadata\command]
    @="\"C:\\Tools\\ShowMetadataPortable\\exiftool(-k).exe\" \"%1\""
     
    • Merci Merci x 1
Chargement...

Dernières occasions

 

Partager cette page

Dernières Occasions

 
Vous souhaitez annoncer sur le Repaire ? Contactez-nous