Recherche avancée

Médias (0)

Mot : - Tags -/formulaire

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (112)

  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accéder à la configuration et ajouter des langues prises en compte
    Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
    De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
    Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...)

  • Déploiements possibles

    31 janvier 2010, par

    Deux types de déploiements sont envisageable dépendant de deux aspects : La méthode d’installation envisagée (en standalone ou en ferme) ; Le nombre d’encodages journaliers et la fréquentation envisagés ;
    L’encodage de vidéos est un processus lourd consommant énormément de ressources système (CPU et RAM), il est nécessaire de prendre tout cela en considération. Ce système n’est donc possible que sur un ou plusieurs serveurs dédiés.
    Version mono serveur
    La version mono serveur consiste à n’utiliser qu’une (...)

  • Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs

    12 avril 2011, par

    La manière la plus simple d’ajouter des informations aux auteurs est d’installer le plugin Inscription3. Il permet également de modifier certains comportements liés aux utilisateurs (référez-vous à sa documentation pour plus d’informations).
    Il est également possible d’ajouter des champs aux auteurs en installant les plugins champs extras 2 et Interface pour champs extras.

Sur d’autres sites (6698)

  • Point CMake project to specific include file

    16 novembre 2011, par Unapiedra

    I am trying to build OpenCV 2.3.0 with FFMPEG enabled. Since Ubuntu 11.10 only supplies libavcodec/format with version 0.7 and the ticket #1020(link below) indicates that it should work with 0.8.

    If I try to compile I get the following error :

    [ 18%] Building CXX object modules/highgui/CMakeFiles/opencv_highgui.dir/src/cap_ffmpeg.o
    In file included from /home/chris/src/OpenCV-2.3.0/modules/highgui/src/cap_ffmpeg.cpp:45:0:
    /home/foo/src/OpenCV-2.3.0/modules/highgui/src/cap_ffmpeg_impl.hpp:103:36: fatal error: libavformat/avformat.h: No such file or directory
    compilation terminated.

    This file lives in /opt/linux64-debug/include/ffmpeg/libavformat/avformat.h. I tried pointing make at that with CMAKE_INCLUDE_DIRECTORY,PATH, CMAKE_PREFIX_PATH and CMAKE_LIBRARY_PATH. None of that worked. ( I always used the path /opt/linux64-debug/include/ffmpeg.)

    https://code.ros.org/trac/opencv/ticket/1020

  • Is there a way to use ffmpeg binary on anroid platform in MAUI project ?

    18 août 2023, par Mrand

    Currently I'm working on my test project about capabilities of MAUI and ffmpeg, so I can create my own applications. I got stuck on problem about using ffmpeg on platforms other than Windows (for example Anroid).

    


    I tried googling the problem, didn't find anything helpful. Right now my ffmpeg for Android binary is situated inside Platforms/Android/Assets/libs as AndroidAsset. And I'm using code below to put my binary on Android to execute in the future

    


    protected override void OnCreate(Bundle bundle)
{
    base.OnCreate(bundle);

    if (ContextCompat.CheckSelfPermission(this, Manifest.Permission.ReadExternalStorage) != Permission.Granted 
        || ContextCompat.CheckSelfPermission(this, Manifest.Permission.WriteExternalStorage) != Permission.Granted 
        || ContextCompat.CheckSelfPermission(this, Manifest.Permission.Internet) != Permission.Granted) 
    {
        ActivityCompat.RequestPermissions(this, new string[] {
          Manifest.Permission.ReadExternalStorage, Manifest.Permission.WriteExternalStorage, Manifest.Permission.Internet
        }, 0);
    }

    PrepareFFmpeg();
}

private void PrepareFFmpeg()
{
    var assetManager = Android.App.Application.Context.Assets;
    string path = "libs/ffmpeg";
    string destinationPath = Path.Combine(Android.App.Application.Context.ApplicationInfo.DataDir, "ffmpeg");

    var directoryPath = Path.GetDirectoryName(destinationPath);
    if (!Directory.Exists(directoryPath))
    {
        Directory.CreateDirectory(directoryPath);
    }

    using (var inputStream = assetManager.Open(path))
    {
        if (File.Exists(destinationPath)) 
        {
            File.Delete(destinationPath);
        }

        using (var outputStream = File.Create(destinationPath))
        {
            inputStream.CopyTo(outputStream);
        }
    }

    Java.Lang.JavaSystem.SetProperty("java.io.tmpdir", destinationPath);
    Java.Lang.Runtime.GetRuntime().Exec("chmod 700 " + destinationPath);

    FFmpeg.SetExecutablesPath(destinationPath);
}


    


    public static class FFmpegService
{
    public static async Task ConvertVideoAsync(string inputPath, string outputPath, string format)
    {
        if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
        {
            string ffmpegPath = GetFFmpegPath();
            string arguments = $"-i \"{inputPath}\" \"{outputPath}.{format}\"";

            ProcessStartInfo startInfo = new ProcessStartInfo
            {
                FileName = ffmpegPath,
                Arguments = arguments,
                RedirectStandardOutput = true,
                RedirectStandardError = true,
                UseShellExecute = false,
                CreateNoWindow = true,
            };

            using Process process = new Process { StartInfo = startInfo };
            process.Start();
            await process.WaitForExitAsync();
        }
        else
        {
            //IConversion conversion = await FFmpeg.Conversions.FromSnippet.Convert(inputPath, $"{outputPath}.{f*-  .ormat}");
            //string command = $"-i {inputPath} -f {format} {outputPath}";

            //ProcessStartInfo psi = new ProcessStartInfo();
            //psi.FileName = FFmpeg.ExecutablesPath;
            //psi.Arguments = command;
            //psi.RedirectStandardOutput = true;
            //psi.RedirectStandardError = true;
            //psi.UseShellExecute = false;

            //Process process = Process.Start(psi);
            //process.WaitForExit();

            //string output = process.StandardOutput.ReadToEnd();
            //string error = process.StandardError.ReadToEnd();

            string outputPathWithFormat = $"{outputPath}.{format}";
            IConversion conversion = await FFmpeg.Conversions.FromSnippet.Convert(inputPath, outputPathWithFormat);
            IConversionResult result = await conversion.Start();
        }
    }

    private static string GetFFmpegPath()
    {
        //string platformFolder = RuntimeInformation.IsOSPlatform(OSPlatform.Windows) ? "Windows" : "Android";
        //return Path.Combine("Platforms", platformFolder, "ffmpeg", "ffmpeg");
        if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
        {
            return Path.Combine("Platforms", "Windows", "ffmpeg", "ffmpeg");
        }
        else
        {
            return null;
        }
    }
}


    


    I'm trying to use FFmpegService to convert video in any desired format I can by passing it in the arguments of the method (Windows works fine).

    


    In my service I also tried to use Xabe.FFmpeg but it always gives couldn't find part of path (path here). When using more manual approach I face another problem every time : Permission denied.
For path I tried /data/data/APPNAME and cache directories. It always results in problems mentioned above.

    


    I downloaded FFmpeg binary from this repository : https://github.com/tomaszzmuda/Xabe.FFmpeg/releases/tag/executables

    


    My goal is to get conversion working for any format and for at least two platforms : Android and Windows, but if you can tell me how to do it on other platforms as well - I would be grateful.

    


    Additional question : If you can tell me the best practice setting standard path for storing converted audio and video, thanks.

    


    If you need more details, please specify I would happily provide them.
P.S. : don't look at the quality of code, I tried to code this for week so I didn't care about quality, I just want to learn how can I do this.

    


    Thanks for your time and attention !

    


    Project : Maui Blazor .Net 7.0

    


  • No Implementation Found for init method in Youtube Live Streaming Watch me project

    17 mai 2017, par Basha

    I am new to android development.presently I am Working on Youtube Live Streaming and downloaded watchMe project.I am getting the error in my class where I used to load FFMPEG libffmpeg.so file and the error was cannot resolve "init" method. and getting error while running the application as below

    java.lang.UnsatisfiedLinkError: No implementation found for boolean com.google.sai.apps.watchme.Ffmpeg.init(int, int, int, java.lang.String) (tried Java_com_google_sai_apps_watchme_Ffmpeg_init and Java_com_google_sai_apps_watchme_Ffmpeg_init__IIILjava_lang_String_2)
                                                                                        at com.google.sai.apps.watchme.Ffmpeg.init(Native Method)
                                                                                        at com.google.sai.apps.watchme.VideoStreamingConnection.open(VideoStreamingConnection.java:71)
                                                                                        at com.google.sai.apps.watchme.StreamerService.startStreaming(StreamerService.java:73)
                                                                                        at com.google.sai.apps.watchme.StreamerActivity.startStreaming(StreamerActivity.java:163)
                                                                                        at com.google.sai.apps.watchme.StreamerActivity.access$200(StreamerActivity.java:39)
                                                                                        at com.google.sai.apps.watchme.StreamerActivity$1.onServiceConnected(StreamerActivity.java:55)
                                                                                        at android.app.LoadedApk$ServiceDispatcher.doConnected(LoadedApk.java:1223)
                                                                                        at android.app.LoadedApk$ServiceDispatcher$RunConnection.run(LoadedApk.java:1240)
                                                                                        at android.os.Handler.handleCallback(Handler.java:739)
                                                                                        at android.os.Handler.dispatchMessage(Handler.java:95)
                                                                                        at android.os.Looper.loop(Looper.java:148)
                                                                                        at android.app.ActivityThread.main(ActivityThread.java:5438)
                                                                                        at java.lang.reflect.Method.invoke(Native Method)
                                                                                        at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:762)
                                                                                        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:652)
       05-17 11:31:41.415 23434-25678/com.google.sai.apps.watchme E/ImageFetcher: Error in downloadBitmap - java.io.FileNotFoundException: https://i.ytimg.com/vi/FFvfpXcOpYk/default_live.jpg

    and FFMPEG class was

    public class Ffmpeg {


       static {
           System.loadLibrary("ffmpeg");
       }


       public static native boolean init(int width, int height, int audio_sample_rate, String rtmpUrl);

       public static native void shutdown();

       // Returns the size of the encoded frame.
       public static native int encodeVideoFrame(byte[] yuv_image);

       public static native int encodeAudioFrame(short[] audio_data, int length);
    }

    please someone help me.