EffectEngine: Add all Paths to .json

  • This is already possible.

    Code
    "effects" :
        {
            "paths" :
            [
                "/storage/hyperion/effects",
                "/opt/hyperion/effects"
            ]
        },


    There is just a small problem. It throws an error at the log for the missing path. Is it possible to modifiy this that just a message will be thrown if no paths are found?


    //This is a failsave method for all users.


    log:

    Code
    EFFECTENGINE ERROR: Effect directory can not be loaded: storage/hyperion/effects


    @penfold42 ?


    Thank you :)

  • This the code block that does the path loading:


    https://github.com/hyperion-pr…e/EffectEngine.cpp#L34-53


    Will add a check there so if we found 0 valid paths it throws an error :)


    // Update


    Would look like this and will test here now, so if we find 0 paths it will always throw and if only one out of two in there is invalid we don't throw as we have valid effects.



    // Update 2


    Complete example on gist and tested here with one invalid and one valid path like in the example.


    \libsrc\effectengine\EffectEngine.cpp


    [MEDIA=gist]RickDB/3e8938b86f6bc3b0da076824c14574e7[/MEDIA]

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!