Recherche avancée

Médias (39)

Mot : - Tags -/audio

Autres articles (67)

  • Submit bugs and patches

    13 avril 2011

    Unfortunately a software is never perfect.
    If you think you have found a bug, report it using our ticket system. Please to help us to fix it by providing the following information : the browser you are using, including the exact version as precise an explanation as possible of the problem if possible, the steps taken resulting in the problem a link to the site / page in question
    If you think you have solved the bug, fill in a ticket and attach to it a corrective patch.
    You may also (...)

  • Les tâches Cron régulières de la ferme

    1er décembre 2010, par

    La gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
    Le super Cron (gestion_mutu_super_cron)
    Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

Sur d’autres sites (7874)

  • Why FFMPEG commands not working in marshmallows and lollipop ?

    22 février 2016, par Andy Developer

    why my code is not working in marshmallows and lollipop devices. or any idea how to use FFMPEG in that versions. any help.

    import android.os.Bundle;
    import android.os.Environment;
    import android.support.v7.app.AppCompatActivity;
    import android.view.View;
    import android.view.View.OnClickListener;
    import android.widget.Button;
    import android.widget.Toast;

    import com.kru.ffmpeglibs.FFmpeg;
    import com.kru.ffmpeglibs.FFmpegExecuteResponseHandler;
    import com.kru.ffmpeglibs.FFmpegLoadBinaryResponseHandler;
    import com.kru.ffmpeglibs.exceptions.FFmpegCommandAlreadyRunningException;
    import com.kru.ffmpeglibs.exceptions.FFmpegNotSupportedException;

    public class CommandsActivity extends AppCompatActivity {
    private FFmpeg fFmpeg;
    private Button btnGenerate;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
       super.onCreate(savedInstanceState);
       setContentView(R.layout.activity_main);

       fFmpeg = FFmpeg.getInstance(CommandsActivity.this);
       executeBinary();

       btnGenerate = (Button) findViewById(R.id.btnGenerate);
       btnGenerate.setOnClickListener(new OnClickListener() {
           @Override
           public void onClick(View v) {
               try {
                   String[] ffmpegCommand = { "-i "
                           + Environment.getExternalStorageDirectory()
                                   .getPath()
                           + "/vid.mp4"
                           + " -r 10 "
                           + Environment.getExternalStorageDirectory()
                                   .getPath()
                           + "/com.mobvcasting.mjpegffmpeg/frame_%05d.jpg" };

                   executeCommand(ffmpegCommand);

               } catch (FFmpegCommandAlreadyRunningException e) {
                   e.printStackTrace();
               }
           }
       });
    }

    private void executeCommand(String[] cmd)
           throws FFmpegCommandAlreadyRunningException {

       fFmpeg.execute(cmd, new FFmpegExecuteResponseHandler() {
           @Override
           public void onSuccess(String message) {

               Toast.makeText(CommandsActivity.this, "Sucesses..",
                       Toast.LENGTH_SHORT).show();

               System.out.println(message);
           }

           @Override
           public void onProgress(String message) {
               // Toast.makeText(MainActivity.this, "On Process",
               // Toast.LENGTH_SHORT).show();
               System.out.println(message);
           }

           @Override
           public void onFailure(String message) {
               Toast.makeText(CommandsActivity.this, "Fail this",
                       Toast.LENGTH_SHORT).show();
               System.out.println(message);
           }

           @Override
           public void onStart() {

           }

           @Override
           public void onFinish() {
               Toast.makeText(CommandsActivity.this, "Finish",
                       Toast.LENGTH_SHORT).show();

           }
       });
    }

    private void executeBinary() {

       try {
           fFmpeg.loadBinary(new FFmpegLoadBinaryResponseHandler() {
               @Override
               public void onFailure() {

               }

               @Override
               public void onSuccess() {

               }

               @Override
               public void onStart() {

               }
               @Override
               public void onFinish() {

               }
           }); } catch (FFmpegNotSupportedException e) {   e.printStackTrace();
       }
     }
    }

    Here is my code but it still not working. please tell me what is wrong in the code
    The exception i got is something like this.

    02-22 11:18:41.469: E/AndroidRuntime(27839): FATAL EXCEPTION: main
    02-22 11:18:41.469: E/AndroidRuntime(27839):     java.lang.UnsatisfiedLinkError: Native method not found: com.kru.ffmpeglibs.ArmArchHelper.cpuArchFromJNI:()Ljava/lang/String;
    02-22 11:18:41.469: E/AndroidRuntime(27839):    at com.kru.ffmpeglibs.ArmArchHelper.cpuArchFromJNI(Native Method)
    02-22 11:18:41.469: E/AndroidRuntime(27839):    at com.kru.ffmpeglibs.CpuArchHelper.getCpuArch(CpuArchHelper.java:61)
    02-22 11:18:41.469: E/AndroidRuntime(27839):    at com.kru.ffmpeglibs.FFmpeg.loadBinary(FFmpeg.java:40)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at com.kru.sampleffmpeg.MainActivity.loadFFMpegBinary(MainActivity.java:68)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at com.kru.sampleffmpeg.MainActivity.onCreate(MainActivity.java:36)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.app.Activity.performCreate(Activity.java:5372)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1104)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2257)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2349)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.app.ActivityThread.access$700(ActivityThread.java:159)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1316)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.os.Handler.dispatchMessage(Handler.java:99)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.os.Looper.loop(Looper.java:176)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at android.app.ActivityThread.main(ActivityThread.java:5419)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at java.lang.reflect.Method.invokeNative(Native Method)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at java.lang.reflect.Method.invoke(Method.java:525)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1046)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:862)
    02-22 11:18:41.469: E/AndroidRuntime(27839):   at dalvik.system.NativeStart.main(Native Method)
  • FFmpeg can't run in some device Android

    30 mars 2016, par tqn

    i’m working in a video processing project and now i’m using ffmpeg library in Android. I’m facing with a strange problem with asus zenphone 4 t00l (or all x86 device, I’ve just test in this x86 phone). When start command in project, app always crash :

    03-30 15:08:18.461 21068-21068/com.paditech.videa I/FFmpeg: Loading FFmpeg for armv7-neon CPU
    03-30 15:08:18.781 21068-21068/com.paditech.videa I/System.out: Success........
    03-30 15:26:12.933 21068-21068/com.paditech.videa E/IMGSRV: :0: PVRDRMOpen: TP3, ret = 59
    03-30 15:26:12.933 21068-21068/com.paditech.videa E/IMGSRV: :0: PVRDRMOpen: TP3, ret = 63
    03-30 15:26:15.913 21068-21068/com.paditech.videa D/VideoActivity: onDestroy
    03-30 15:26:18.993 21068-21068/com.paditech.videa I/FFmpeg: Loading FFmpeg for armv7-neon CPU
    03-30 15:26:19.263 21068-21068/com.paditech.videa I/System.out: Success........
    03-30 15:26:42.583 21068-21184/com.paditech.videa D/FFmpeg: Running publishing updates method
    03-30 15:26:42.583 21068-21068/com.paditech.videa E/IMGSRV: :0: PVRDRMOpen: TP3, ret = 59
    03-30 15:26:42.583 21068-21068/com.paditech.videa E/IMGSRV: :0: PVRDRMOpen: TP3, ret = 85
    03-30 15:26:42.683 21068-21068/com.paditech.videa D/VideoActivity: /data/data/com.paditech.videa/files/ffmpeg[1]: syntax error: '-�-4�' unexpected
    03-30 15:26:42.683 21068-21068/com.paditech.videa D/VideoActivity: /data/data/com.paditech.videa/files/ffmpeg[1]: syntax error: '-�-4�' unexpected

    First, I think the problem is ffmpeg library. So I created a test module with simple activity just load and run command and there’re no problem.

    Second, I’m afraid that app cannot load version ffmpeg, because in my log, it’s armv7-neon althought it’s x86 (In my test module, it display x86). And according my search result, may be a external library make app to use abi arm (Build.CPU_API="armv7"). So I try remove all library in gradle in module Test and detected a library. But check in aar file of library, it support all x86 and arm. But after remove it, app still crash with same log. And strangely, althogh Test module register as arm but it’still run success (External question : Why add library jp.wasabeef:picasso-transformations make system register as armv7 although it’s x86)

    Finally, i think problem is command. But after debug, I use same command for Test module but it still success. Now i’m still stuck with it. Could anyone help me to solve it. Thanks. Here my demo code :

       String input = "/storage/emulated/0/Videa/Video/VIDEO_20160122_160020.mp4";
       String output = "/storage/emulated/0/Videa/Audio/AUDIO_20160330_142501.wav";
       String[] command = {
               "-y",
               "-i",
               input,
               "-vn",
               "-f",
               "wav",
               output
       };
       FFmpeg ffmpeg = FFmpeg.getInstance(getApplicationContext());
       try {
           ffmpeg.execute(command, new ExecuteBinaryResponseHandler() {

               @Override
               public void onSuccess(String message) {
                   super.onSuccess(message);
                   System.out.println("Success " + message);
               }

               @Override
               public void onFailure(String message) {
                   super.onFailure(message);
                   System.out.println("Failure " + message);
               }
           });
       } catch (Exception e) {
           e.printStackTrace();
       }

    And here is Failed command :

       ArrayList<string> cmd = new ArrayList<string>();
       cmd.add("-y");
       cmd.add("-i");
       cmd.add(input);
       cmd.add("-vn");
       cmd.add("-f");
       cmd.add("wav");
       cmd.add(output);
       String[] result = new String[cmd.size()];
       return cmd.toArray(result);
    </string></string>
  • android:video watermark show error

    27 avril 2016, par Sakibmohammad Syed

    I want to watermark video and below is my code but when I try to run then it show error like Failed to validate license file, existing!.

       public class MainActivity extends AppCompatActivity {
       private String strAudioFolderPath;
       @Override
       protected void onCreate(Bundle savedInstanceState) {
           super.onCreate(savedInstanceState);
           setContentView(R.layout.activity_main);

           // here my ffmpeg command to watermark video.
           String s = "ffmpeg -i /sdcard/Download/testing.mp4 -i /sdcard/temp1.jpg -filter_complex 'overlay=10:main_h-overlay_h-10' /sdcard/Download/out.mp4";

           GeneralUtils.deleteFileUtil(strAudioFolderPath + "vk.log");
           PowerManager powerManager = (PowerManager) this.getSystemService(Activity.POWER_SERVICE);
           PowerManager.WakeLock wakeLock = powerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "VK_LOCK");
           wakeLock.acquire();
           LoadJNI vk = new LoadJNI();
           try {
               try {
                   vk.run(GeneralUtils.utilConvertToComplex(s), strAudioFolderPath, MainActivity.this);
                   Log.e("Checking water marker", ">>>>>>>>>>>>>>>");

               } catch (Throwable e) {
               } finally {
                   if (wakeLock.isHeld())
                       wakeLock.release();
                   else {
                   }
               }
           } catch (Exception e)
           {
               e.printStackTrace();
           }        
       }
    }

    and error show in logcat like below.

       04-26 17:13:18.211 20492-20492/com.example.android.watermarkvideo I/Videokit: license file not found...
    04-26 17:13:18.211 20492-20492/com.example.android.watermarkvideo I/Videokit: license file /sdcard/Download/testing.mp4/ffmpeglicense.lic not created.
    04-26 17:13:18.211 20492-20492/com.example.android.watermarkvideo D/Videokit: license check rc: -3
    04-26 17:13:18.211 20492-20492/com.example.android.watermarkvideo E/Videokit: Failed to validate license file, existing!

    Actually I have used ffmpeg library to watermak on video file but it is not woking as well as I have not find any proper solution so please help.
    Thanks in advance.