Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could find no file with path '/tmp/reanimate1799-0/render-%05d.png' #120

Closed
noughtmare opened this issue Jul 29, 2020 · 5 comments
Closed

Comments

@noughtmare
Copy link

noughtmare commented Jul 29, 2020

I'm running into an ffmpeg error when trying to render my animation to mp4.

Here is the complete command line output:

Starting render of animation: 77.5
Frames rendered: 2325/2325, time spent: 25s
tshark-tests: /usr/bin/ffmpeg -r 30 -i '/tmp/reanimate1799-0/render-%05d.png' -y '-c:v' libx264 -vf 'fps=30' -preset slow -crf 18 -movflags '+faststart' -progress /tmp/reanimate1799-1.txt -pix_fmt yuv420p output.mp4:
ffmpeg version 4.1.6-1~deb10u1 Copyright (c) 2000-2020 the FFmpeg developers
  built with gcc 8 (Debian 8.3.0-6)
  configuration: --prefix=/usr --extra-version='1~deb10u1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-avresample --disable-filter=resample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared
  libavutil      56. 22.100 / 56. 22.100
  libavcodec     58. 35.100 / 58. 35.100
  libavformat    58. 20.100 / 58. 20.100
  libavdevice    58.  5.100 / 58.  5.100
  libavfilter     7. 40.101 /  7. 40.101
  libavresample   4.  0.  0 /  4.  0.  0
  libswscale      5.  3.100 /  5.  3.100
  libswresample   3.  3.100 /  3.  3.100
  libpostproc    55.  3.100 / 55.  3.100
[image2 @ 0x556bcb9340c0] Could find no file with path '/tmp/reanimate1799-0/render-%05d.png' and index in the range 0-4
/tmp/reanimate1799-0/render-%05d.png: No such file or directory

I tested this with both reanimate-0.3.3.0 and reanimate-0.4.0.0, both give the same error message.

I'm using the render method directly, because recompiling takes way too long for my tastes. This is a minimal example that gives the same error:

module Main (main) where

import           Reanimate
import           Reanimate.Render

main :: IO ()
main = render (mkAnimation dur $
    mkCircle . fromToS 0 (dur*60-1))
  "output.mp4"
  RasterAuto
  RenderMp4
  1280
  720
  30
  where
    dur = 2
@noughtmare
Copy link
Author

noughtmare commented Jul 29, 2020

I have a solution: use RasterRSvg instead of RasterAuto. Maybe RenderAuto should not be passed to render?

@lemmih
Copy link
Member

lemmih commented Jul 29, 2020

Yeah, the raster engine has to be decided before calling render. You can use requireRaster or selectRaster.

I don't understand why you want to call render directly, though. Wouldn't it be easier to set some default arguments with withArgs and then call 'reanimate' as normal?

withArgs (words "--target output.mp4 --raster auto --width 1280 --fps 30") $
  reanimate ...

@noughtmare
Copy link
Author

noughtmare commented Jul 30, 2020

I had tried running on the command line with render before, without all those arguments. That gives the error "Failed to find own source code." which confused me a lot because I don't know why it would want to find its own source code (and even now I think the error should be something like "missing arguments: 'target', 'raster', 'width', 'fps'" or something like that). So I looked for a more direct way to render my animation and found the render function.

@lemmih
Copy link
Member

lemmih commented Jul 30, 2020

By default reanimate tries to enable live-reloading (hence the need to find the source file) and use the browser to render. The error message here should be better.

You really should be using reanimate rather than the internal render function. I'll close this issue once the documentation has been improved.

@lemmih
Copy link
Member

lemmih commented Jul 30, 2020

Version 0.4.1.0 now defaults to 'output.mp4' if no better name could be found. And running the browser viewer without the source available gives a better error message.

@lemmih lemmih closed this as completed Jul 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants