Code Monkey home page Code Monkey logo

reel.jl's People

Contributors

github-actions[bot] avatar iblislin avatar jgoldfar avatar juliatagbot avatar jverzani avatar maximebouton avatar shashi avatar shushman avatar tawheeler avatar tkelman avatar zsunberg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

reel.jl's Issues

0.3 deprecation warnings

Loading Reel in Julia 0.4 throws some warnings related to the deprecation of Uint -> UInt, Nothing -> Void, etc.

WARNING: Base.Uint is deprecated, use UInt instead.
  likely near /home/tim/.julia/v0.4/Reel/src/Reel.jl:14
WARNING: Base.Nothing is deprecated, use Void instead.
  likely near /home/tim/.julia/v0.4/Reel/src/Reel.jl:14
WARNING: Union(args...) is deprecated, use Union{args...} instead.

Is it possible to update the package and then throw in Compat.jl for backwards compatibility? I can take a stab at it and submit a PR if you prefer.

t = 0.0 for the first two steps

It seems that when roll is called, t is 0.0 for the first two steps rather than just the first step. Is this the intended behavior for some reason? Making a PR to correct it now.

Inactive Development

Reel is a wonderful package. It use is limited by the inactive development - a new tag needs to be pushed, etc. I would be willing to work on Reel. Would @shashi consider adding me as a repo collaborator?

I work on other Julia packages such as BayesNets and PGFPlots.

Transparent background turns black in videos

Transparency becomes black in videos.

One way to solve this is to use IM convert on push! to flatten the png. But a better way would of course be some mysterious command-line flag in ffmpeg which does this.

roll from generator

Is it possible to roll from a generator?
In my case, creating a instance of array is time-consuming.
e.g.

roll((plot(i) for i in huge_dataset), fps=24)

Update to Julia 0.6 syntax

This should be easy to fix:

 WARNING: deprecated syntax "inner constructor Frames(...) around C:\Users\Mykel\.julia\v0.6\Reel\src\Reel.jl:22".

Set up Travis

@shashi - I'd like to set up Travis similar to this. The problem is that the package is under shashi/Reel, so I cannot enable testing for it on Travis. I believe it is free. Any chance you could set that up?

You need to:

  • create an account on Travis
  • sync it with your Github repos
  • enable Travis for Reel.jl

Anyone pushing to Reel.jl that should automatically trigger a new Travis build.

image

Decoder (codec none) not found for input stream #0:0

While trying to follow along with this example given in README.md, I get an error, as described towards the end.

Platform:

Distributor ID: Ubuntu
Description:    Ubuntu 18.04 LTS
Release:    18.04
Codename:   bionic

Julia:

Version 1.5.0

Packages:

FFMPEG v0.3.0
Gadfly v1.3.0
Reel v1.3.0

$ fmpeg -version:

ffmpeg version 3.4.8-0ubuntu0.2 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 7 (Ubuntu 7.5.0-3ubuntu1~18.04)
configuration: --prefix=/usr --extra-version=0ubuntu0.2 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-librsvg --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared
libavutil      55. 78.100 / 55. 78.100
libavcodec     57.107.100 / 57.107.100
libavformat    57. 83.100 / 57. 83.100
libavdevice    57. 10.100 / 57. 10.100
libavfilter     6.107.100 /  6.107.100
libavresample   3.  7.  0 /  3.  7.  0
libswscale      4.  8.100 /  4.  8.100
libswresample   2.  9.100 /  2.  9.100
libpostproc    54.  7.100 / 54.  7.100

Error:

julia> using Reel, Gadfly                                                                                                          
                                                                                                                                   
julia> function render(t, dt)                                                                                                      
       plot([x -> sin(x+t*π), x -> cos(x+t*π)], 0, 6)                                                                              
       end                                                                                                                         
render (generic function with 1 method)                                                                                            
                                                                                                                                   
julia> film = roll(render, fps=30, duration=2)                                                                                     
Frames{MIME{Symbol("text/html")}}("/tmp/jl_4MxfPR", 0x000000000000003c, 30.0, nothing)                                             
                                                                                                                                   
julia> write("output0.gif", film)                                                                                                  
Decoder (codec none) not found for input stream #0:0                                                                               
ERROR: failed process: Process(`/home/sid/.julia/artifacts/7f40eeb66d90d3026ae5fb68761c263b57adb840/bin/ffmpeg -y -r 30.0 -f image$
 -i /tmp/jl_4MxfPR/%d.html output0.gif -loglevel error`, ProcessExited(1)) [1]                                                     
                                                                                                                                   
Stacktrace:                                                                                                                        
 [1] pipeline_error at ./process.jl:525 [inlined]                                                                                  
 [2] run(::Cmd; wait::Bool) at ./process.jl:440                                                                                    
 [3] run at ./process.jl:438 [inlined]                                                                                             
 [4] (::FFMPEG.var"#4#6"{Cmd})(::String) at /home/sid/.julia/packages/FFMPEG/vocw2/src/FFMPEG.jl:114
 [5] (::FFMPEG_jll.var"#8#9"{FFMPEG.var"#4#6"{Cmd}})() at /home/sid/.julia/packages/FFMPEG_jll/w0b7h/src/wrappers/x86_64-linux-gnu.
jl:49
 [6] withenv(::FFMPEG_jll.var"#8#9"{FFMPEG.var"#4#6"{Cmd}}, ::Pair{String,String}, ::Vararg{Pair{String,String},N} where N) at ./en
v.jl:161
 [7] ffmpeg(::FFMPEG.var"#4#6"{Cmd}; adjust_PATH::Bool, adjust_LIBPATH::Bool) at /home/sid/.julia/packages/FFMPEG_jll/w0b7h/src/wra
ppers/x86_64-linux-gnu.jl:48
 [8] ffmpeg at /home/sid/.julia/packages/FFMPEG_jll/w0b7h/src/wrappers/x86_64-linux-gnu.jl:31 [inlined]
 [9] #exe#2 at /home/sid/.julia/packages/FFMPEG/vocw2/src/FFMPEG.jl:113 [inlined]
 [10] ffmpeg_exe at /home/sid/.julia/packages/FFMPEG/vocw2/src/FFMPEG.jl:125 [inlined]
 [11] #write#6 at /home/sid/.julia/packages/Reel/Mu9ck/src/Reel.jl:68 [inlined]
 [12] write(::String, ::Frames{MIME{Symbol("text/html")}}) at /home/sid/.julia/packages/Reel/Mu9ck/src/Reel.jl:66
 [13] top-level scope at REPL[8]:1

Use mktempdir instead of tempname+mkdir

Thanks for the great work on Reel.jl.

On Windows 8.1 Reel does not work because tempname already creates a temporary file, and the subsequent mkdir call in Reel.jl line 21 fails.

The fix is to use the mktempdir call instead, i.e. replace

type Frames{M <: MIME}
    tmpdir::AbstractString
    length::Uint
    fps::Float64
    rendered::Union(Nothing, AbstractString)
    function Frames(; fps=30)
        tmpdir = tempname()
        mkdir(tmpdir)
        new(tmpdir, 0, fps, nothing)
    end
end

with

type Frames{M <: MIME}
    tmpdir::AbstractString
    length::Uint
    fps::Float64
    rendered::Union(Nothing, AbstractString)
    function Frames(; fps=30)
        tmpdir = mktempdir()
        new(tmpdir, 0, fps, nothing)
    end
end

Also, it would be great if the Reel.jl test case could check for the presence of ffmpeg, or even better, would bring it's own ffmpeg installation.

Using which on Windows

This doesn't seem to work on Windows (currently starting at line 71 of src/Reel.jl):

        cmd = try readstring(`which convert`)
        catch e1
            try readstring(`which magick`)
            catch e2
                error("Could not find imagemagick binary. Is it installed?")
            end
        end |> strip

The command which is not supported. We end up getting this error:

Could not find imagemagick binary. Is it installed?

when it is actually installed.

Use multi-threading for rendering

It would be nice to support multi-threaded rendering. Candidates for Threads.@spawn may be the render(t, dt) call in roll and (perhaps even more importantly) the call to writeframe. This might require some more restructuring since the push!(frames,...) design requires things to be rather sequential.

tag new release?

Looks like Reel has quite a few updates that aren't in the first v0.1.0 release.
Would it be possible to tag a new one?

Imagemagick convert command replaced

The 'convert' command of imagemagick has been replaced by magick in the latest version. It needs to be replaced if you want to export in gif.

Extension for Text/HTML

I get the error

LoadError: MethodError: extension has no method matching extension(::MIME{symbol("text/html")})
while loading In[3], in expression starting on line 1

in push! at /Users/solver/.julia/v0.4/Reel/src/Reel.jl:40
in roll at /Users/solver/.julia/v0.4/Reel/src/Reel.jl:93

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.