Recherche avancée

Médias (1)

Mot : - Tags -/Rennes

Autres articles (89)

  • 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

  • Gestion de la ferme

    2 mars 2010, par

    La ferme est gérée dans son ensemble par des "super admins".
    Certains réglages peuvent être fais afin de réguler les besoins des différents canaux.
    Dans un premier temps il utilise le plugin "Gestion de mutualisation"

  • Organiser par catégorie

    17 mai 2013, par

    Dans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
    Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
    Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...)

Sur d’autres sites (8892)

  • geting no result from GetStringUTFChars JNI

    9 avril 2013, par talhamalik22

    android NDK for my android application. i am stuck on the starting lines and it is not compiling further. Following is my code. It doest not compile after "str = (*env)->GetStringUTFChars(env, filename, NULL) ;". Please check my java and c code

    The java code :

    public class MyffmpegActivity extends Activity {

    private static native int logFileInfo(String filename);

    static
    {
       Log.i("HEHA", "HOHA");
       System.loadLibrary("mylib");
    }

    @Override
    protected void onCreate(Bundle savedInstanceState) {
       super.onCreate(savedInstanceState);
       setContentView(R.layout.activity_myffmpeg);
       String path=Environment.getExternalStorageDirectory().getPath();
       path=path+"/test.mp4";
       Log.i("Name Returned is ", ":"+path);
    int x=logFileInfo(path);


    }

    The C code

    jint Java_com_example_myffmpegtest_MyffmpegActivity_logFileInfo(JNIEnv * env, jobject  this, jstring filename)
    {

    av_register_all();
      AVFormatContext *pFormatCtx;
      const jbyte *str;

     str = (*env)->GetStringUTFChars(env, filename, NULL);
    if(av_open_input_file(&pFormatCtx, str, NULL, 0, NULL)!=0)
    {
       LOGE("Can't open file '%s'\n", str);
       return 1;
    }
    else
    {

       LOGI("File was opened\n");
       LOGI("File '%s', Codec %s",
           pFormatCtx->filename,
           pFormatCtx->iformat->name
       );
    }
    return 0;}
  • Ubuntu12.04 : libavformat header trouble when compiling C program

    30 mai 2013, par Juneyoung Oh

    My code is super simple, just include "avformat.h" and call "av_register_all".

    full code is below.

     1 #include
     2 #include
     3 #include
     4 //#include <libavcodec></libavcodec>avcodec.h>
     5 #include <libavformat></libavformat>avformat.h>
     6 //#include "libavcodec/avcodec.h"
     7 //#include "libavformat/avformat.h"
     8
     9
    10 int main (int argc, char* argv[]){
    11         av_register_all();
    12 /*
    13         AVFormatContext* pFormatCtx;
    14         const char* filename = "/home/juneyoungoh/Videos/CON1234ID.ts";
    15
    16         if(av_open_input_file(&amp;pFormatCtx, filename, NULL, 0, NULL) != 0)
    17         {
    18                 handle_error();
    19         }
    20
    21         if(av_find_stream_info(pFormatCtx) &lt; 0)
    22         {
    23                 handle_error();
    24         }
    25
    26         dump_format(pFormatCtx, 0, filename, 1);
    27
    28         //av_get_audio_frame_duration();
    29 */
    30         return 0;
    31 }

    The problem is when I compile this in Terminal it show error.

    /tmp/ccvgpGjv.o: In function `main&#39;:
    getDuration.c:(.text+0x10): undefined reference to `av_register_all&#39;
    collect2: ld returned 1 exit status

    my avformat.h file is in /usr/local/include/libavformat/avformat.h.

    Here is something I have already tried.

    1. gcc getDuration.c
    2. gcc -I/usr/local/include/ getDuration.c
    3. gcc -I/usr/local/include/libavformat/ getDuration.c
    4. gcc -L/usr/local/include/ getDuration.c
    5. gcc -L/usr/local/include/libavformat/ getDuration.c
    6. gcc getDuration.c -lavformat

    Give me the light of hope +_+

  • how to locate the voice chat that the discord bot is connected to

    10 mars 2019, par SwaggZ ReYan

    I am making a discord bot that is being activated by voice recognition, im at the very beginning right now im making him join a voice channel (which is working), and im trying to make a command to make him leave.

    const commando = require('discord.js-commando');

    class LeaveChannelCommand extends commando.Command
    {
       constructor(client){!
           super(client,{
               name: 'leave',
               group: 'music',
               memberName: 'leave',
               description: 'leaves a voice channel'
           });
       }
       async run(message, args)
       {
           if(message.guild.voiceConnection)
           {
               message.guild.voiceConnection.disconnect();
           }
           else
           {
               message.channel.sendMessage("seccessfully left")
           }
       }
    }

    module.exports = LeaveChannelCommand;

    right now you can type !leave from anywhere in the server and the bot leaves,
    i want to make it possible to control him only from the same voice channel,
    what should i do