zmn-hamid / Aseprite-Export-Video-Script

Aseprite script for exporting mp4 and mkv animations
4 stars 0 forks source link

Aseprite-Export-Video-Script #1

Closed Zakhar201 closed 2 months ago

Zakhar201 commented 6 months ago

Hi, I tried this script and it doesn't work as it should. I did everything as it was supposed to be done, but in the end the info.ffconcat file is created. image

zmn-hamid commented 6 months ago

working on it...

zmn-hamid commented 6 months ago

The info.concat file is supposed to be made, it's used to make the video file. but unfortunately there is apparently no way to delete that file via the script. I have opened an issue on the Aseprite's github API. I'll update you if I made changes about it.

If the video is not even created for you, then do this:

  1. Verify FFMPEG: Type cmd in your windows, when opened, type ffmpeg -version and there should appear a long text, and the beginning of that text is the version of ffmpeg. if it instead returns error saying that ffmpeg doesn't exist or something like that, then it's because you haven't added it to the path properly. go through the guide again and fix it. example of what you should see: Screenshot 2024-05-03 115310

  2. if the problem still occurs, it must show an error. provide me with that so I can help you

I tested the code once again by myself and it worked completely fine, both with an old ffmpeg and the newest one.

Zakhar201 commented 6 months ago

Hi, I checked this and cmd shows the FFMPEG version. image

Zakhar201 commented 6 months ago

Any ideas?

zmn-hamid commented 6 months ago

If it shows no error, then the error must happen in the FFMPEG part (where it coverts the frames into a video). Please follow these steps one by one:

  1. Download the latest version of the script: https://github.com/zmn-hamid/Aseprite-Export-Video-Script/blob/master/Export%20Video.lua I've made some changes to it. Test it out and if doesn't work, go for the next steps:
  2. Download the latest FFMPEG version if you haven't. The download section for Windows is here and you can download ffmpeg-git-full.7z from the first section. after adding it to the path and verifying the version via the way mentioned earlier, then test the script again.
  3. If the problem still persists, I have made a debug script as well for this case. download it from here and install. After testing it out, a "report.txt" file would be created in the same directory you chose to export the video to. share with me the content of it so I can hopefully understand what's wrong.

Thanks for your patience and sorry If I still couldn't make a definite fix for it. Thanks for contributing to this project. P.S. I will try testing out the older versions of FFMPEG tomorrow.

wuyi0020 commented 3 months ago

I fixed the problem by changing lines 87 from " "to ' '. local ffmpegCommand = string.format('ffmpeg -f concat -safe 0 -y -i \"%s\" -pix_fmt yuv420p \"%s\"', concatFilePath, saveTo) I hope this is helpful.

Zakhar201 commented 3 months ago

Hi, I'll try it later

zmn-hamid commented 2 months ago

Sorry for the latency. I made the changes mentioned by wuyi0020. And I also added a logging option. Download the new script and test it, if your issue still isn't solved, the logging option is mentioned in the README.md file. follow the guide and there would be a FFMPEG log file. provide us with that so we can further assist you.

Looking for your response

Zakhar201 commented 2 months ago

Hi, I did everything as written in the README and it works. It runs even if there are frames with different duration. But it gives an error if there are spaces in the file path in the folder name or the name is not in Latin. Anyway, everything works.

zmn-hamid commented 2 months ago

Hi, I did everything as written in the README and it works. It runs even if there are frames with different duration. But it gives an error if there are spaces in the file path in the folder name or the name is not in Latin. Anyway, everything works.

Glad to hear it works. I'll try fixing those bugs and will update you when the changes are done