
Recherche avancée
Autres articles (71)
-
Les autorisations surchargées par les plugins
27 avril 2010, parMediaspip core
autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs -
Use, discuss, criticize
13 avril 2011, parTalk to people directly involved in MediaSPIP’s development, or to people around you who could use MediaSPIP to share, enhance or develop their creative projects.
The bigger the community, the more MediaSPIP’s potential will be explored and the faster the software will evolve.
A discussion list is available for all exchanges between users. -
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa 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 (...)
Sur d’autres sites (9085)
-
Error on linking ffmpeg example code in linux
15 novembre 2013, par user2995111I'm trying to work on the ffmpeg example source file. Now, I'm trying to compile and link from the command line but I can't seem to get it to link.
I compiled the code and generated obj file.
My problem is on linking ,
I just tried this :
gcc -Wall -o example -L/home/jayanthi/example -lavcodec -lavutil example.o
At this point, I get error of 'undefined reference error'
example.o: In function `audio_encode_example':
example.c:(.text+0x25): undefined reference to `avcodec_find_encoder'
example.c:(.text+0x6a): undefined reference to `avcodec_alloc_context3'
example.c:(.text+0xad): undefined reference to `avcodec_open'
example.c:(.text+0x1ce): undefined reference to `sin'
example.c:(.text+0x238): undefined reference to `avcodec_encode_audio'
example.c:(.text+0x297): undefined reference to `avcodec_close'
example.c:(.text+0x2a3): undefined reference to `av_free'
example.o: In function `audio_decode_example':
example.c:(.text+0x2f7): undefined reference to `av_init_packet'
example.c:(.text+0x30b): undefined reference to `avcodec_find_decoder'
example.c:(.text+0x359): undefined reference to `avcodec_alloc_context3'
example.c:(.text+0x379): undefined reference to `avcodec_open'
..... etc.
collect2: ld returned 1 exit statusplease help me out
-
Evolution #4060 (Nouveau) : Nettoyage du code PHP 5.4
11 décembre 2017Quelques tests sont présents dans le code pour tester des vieilles versions de SPIP.
=> Les trouver, et les enlever. -
undefined reference in ffmpeg (use code blocks)
6 février 2015, par Yonghao ZhaoI am currently testing a video encoding program using ffmepg codeblocks.I encountered several undefined reference warning. I have checked on internet and add extern "c" to the headers but it still doesnt work. Please help me check.
Here is part of the code :
extern "C" {
#include "libavcodec/avcodec.h"
#include "libavutil/channel_layout.h"
#include "libavutil/common.h"
#include "libavutil/imgutils.h"
#include "libavutil/mathematics.h"
#include "libavutil/samplefmt.h"
}
#include
#include "libavutil/opt.h"
static void video_encode_example(const char *filename, int codec_id)
{
AVCodec *codec;
AVCodecContext *c= NULL;
int i, ret, x, y, got_output;
FILE *f;
AVFrame *frame;
AVPacket pkt;
uint8_t endcode[] = { 0, 0, 1, 0xb7 };
printf("Encode video file %s\n", filename);
/* find the mpeg1 video encoder */
codec = avcodec_find_encoder(AV_CODEC_ID_H264);
if (!codec) {
fprintf(stderr, "Codec not found\n");
exit(1);
}
c = avcodec_alloc_context3(codec);
if (!c) {
fprintf(stderr, "Could not allocate video codec context\n");
exit(1);
}
int main(int argc, char **argv)
{
avcodec_register_all();
video_encode_example("test.mpg", AV_CODEC_ID_MPEG1VIDEO);
return 0;
}The error given :
||=== Build : Debug in ffmepg_video_en (compiler : GNU GCC Compiler) ===|
obj/Debug/main.o||In functionvideo_encode_example':|
codeblocksfile/ffmepg_video_en/main.cpp|36|undefined reference toavcodec_find_encoder’|
codeblocksfile/ffmepg_video_en/main.cpp|41|undefined reference toavcodec_alloc_context3'|
codeblocksfile/ffmepg_video_en/main.cpp|63|undefined reference toav_opt_set(void*, char const*, char const*, int)’|
codeblocksfile/ffmepg_video_en/main.cpp|65|undefined reference toavcodec_open2'|
codeblocksfile/ffmepg_video_en/main.cpp|74|undefined reference toav_frame_alloc’|
codeblocksfile/ffmepg_video_en/main.cpp|85|undefined reference toav_image_alloc(unsigned char**, int*, int, int, AVPixelFormat, int)'|
codeblocksfile/ffmepg_video_en/main.cpp|92|undefined reference toav_init_packet’|
codeblocksfile/ffmepg_video_en/main.cpp|112|undefined reference toavcodec_encode_video2'|
codeblocksfile/ffmepg_video_en/main.cpp|120|undefined reference toav_free_packet’|
codeblocksfile/ffmepg_video_en/main.cpp|126|undefined reference toavcodec_encode_video2'|
/home/yonghao/codeblocksfile/ffmepg_video_en/main.cpp|134|undefined reference toav_free_packet’|
codeblocksfile/ffmepg_video_en/main.cpp|140|undefined reference toavcodec_close'|
codeblocksfile/ffmepg_video_en/main.cpp|141|undefined reference toav_free’|
codeblocksfile/ffmepg_video_en/main.cpp|142|undefined reference toav_freep'|
codeblocksfile/ffmepg_video_en/main.cpp|143|undefined reference toav_frame_free’|
obj/Debug/main.o||In functionmain':|
codeblocksfile/ffmepg_video_en/main.cpp|151|undefined reference toavcodec_register_all’|
||=== Build failed : 16 error(s), 0 warning(s) (0 minute(s), 1 second(s)) ===|