time4tea / gopro-dashboard-overlay

Programs to process GoPro MP4 & Generic GPX/FIT files and create video dashboards & maps
GNU General Public License v3.0
327 stars 48 forks source link

Trying to Create a movie from GPX and video not created with GoPro #183

Closed dominic-findlay closed 4 months ago

dominic-findlay commented 4 months ago

I have got the overlay to work using the --use-gpx-only creating a overlay with the alpha channel and then overlaying it myself using ffmpeg, However I would like to do this in one step

I have set the FileCreated attribute on the file.

While trying to supply the two video filenames at the end of the command I get this error

gopro-dashboard.py: error: unrecognized arguments: videoFileName.mp4 videoFileName + Overlay.mp4

I am using java to run the command, the command I am running is from this

          "./gopro-dashboard-overlay-windows/venv/Scripts/python",
          "./gopro-dashboard-overlay-windows/venv/Scripts/gopro-dashboard.py",
          "--font",
          "trebuc.ttf",
          "--profile",
          "nnvgpu",
          "--layout-xml",
          videoDir.getOverlayLayoutFileStr().get("1920x1080"), //Will return path of the layout file
          "--overlay-size",
          "1920x1080",
          "--video-time-start",
          "file-created",
          " --use-gpx-only",
          "--gpx",
          inputGpxFileStr, // The path to the GPX file
          mainVideoName, // The video to be underneath
          outputFileName // Filename to output to (will end in  "+ Overlay.mp4")
        );

Can you see a issue in how I an trying to run this command? or was this functionality removed/changed as it did say experimental I am running this on windows, if that could change anything.

Thank you for this amazing project.

dominic-findlay commented 4 months ago

Managed to get it to work with


          "./gopro-dashboard-overlay-windows/venv/Scripts/python",
          "./gopro-dashboard-overlay-windows/venv/Scripts/gopro-dashboard.py",
          "--video-time-start",
          "file-modified", //Turns out my java code was changing the date modified
          "--font",
          "trebuc.ttf",
          "--use-gpx-only",
          "--gpx",
          inputGpxFileStr,
          "--profile",
          "nnvgpu",
          "--overlay-size",
          "1920x1080",
          "--layout-xml",
          videoDir.getOverlayLayoutFileStr().get("1920x1080"),
          mainVideoName,
          outputFileName
        );

Seems the only thing I changed is the order of the params
time4tea commented 4 months ago

Hi there. Thanks for your interest in the software.

Glad you got it to work. There are various examples of the command lines at

https://github.com/time4tea/gopro-dashboard-overlay/tree/main/docs/bin#create-a-movie-from-gpx-and-video-not-created-with-gopro

Using file names with spaces in is usually a source of frustration - so that could have made things a bit more tricky!

Cheers

James