
Recherche avancée
Médias (1)
-
Rennes Emotion Map 2010-11
19 octobre 2011, par
Mis à jour : Juillet 2013
Langue : français
Type : Texte
Autres articles (90)
-
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
Creating farms of unique websites
13 avril 2011, parMediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...) -
Le profil des utilisateurs
12 avril 2011, parChaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)
Sur d’autres sites (16114)
-
A Comprehensive Guide to Robust Digital Marketing Analytics
30 octobre 2023, par Erin -
A Comprehensive Guide to Robust Digital Marketing Analytics
15 novembre 2023, par Erin — Analytics Tips -
ffmpeg-android Extract Audio From Digital Container Format
15 août 2013, par user2685548I make program extracts audio from Digital Container Format (DCF).
I want to obtain an encoded audio file.
so, I think that I can write to file only audio stream packet.Some DCF file work well, but some files does not work.
Please, can you help me to find a problem ?
// src -- is DCF
// dest -- is going to write file
int ExtractAudio(const char src[], const char dest[]) {
av_register_all();
avcodec_register_all();
__android_log_print(ANDROID_LOG_DEBUG, "test", "dest : %s", dest);
__android_log_print(ANDROID_LOG_DEBUG, "test", "src : %s", src);
//파일을 열고 컨텍스트에 파일 형식을 불러온다.
AVFormatContext * pInputFormatContext = NULL;
int err = avformat_open_input(&pInputFormatContext, src, NULL, NULL);
if (err < 0) {
__android_log_print( ANDROID_LOG_DEBUG, "test",
"avformat_open_input Err! %d",err);
return 0;
}
FILE *destFile = fopen(dest, "wb");
FILE *srcFile = fopen(src, "rb");
if (destFile == NULL || srcFile == NULL) {
__android_log_print(ANDROID_LOG_DEBUG, "test", "fopen Err!");
__android_log_print(ANDROID_LOG_DEBUG, "test", "fopen Err!");
return 0;
}
fseek(srcFile, 0, SEEK_END);
DCFSize = ftell(srcFile);
fseek(srcFile, 0, SEEK_SET);
int nAudioStreamIdx = -1;
AVCodec *pAudioCodec = NULL;
err = av_find_stream_info(pInputFormatContext);
if (err < 0) {
__android_log_print(ANDROID_LOG_DEBUG, "test",
"av_find_stream_info Err!");
__android_log_print(ANDROID_LOG_DEBUG, "test",
"av_find_stream_info Err!");
return 0;
}
err = av_find_best_stream(pInputFormatContext, AVMEDIA_TYPE_AUDIO, -1, -1,
&pAudioCodec, NULL);
//에러처리 임시
if (err < 0) {
nAudioStreamIdx = 1;
if (err == AVERROR_STREAM_NOT_FOUND)
__android_log_print(ANDROID_LOG_DEBUG, "test",
"AVERROR_STREAM_NOT_FOUND");
if (err == AVERROR_DECODER_NOT_FOUND)
__android_log_print(ANDROID_LOG_DEBUG, "test",
"AVERROR_DECODER_NOT_FOUND ");
} else
nAudioStreamIdx = err;
AVPacket Packet;
av_init_packet(&Packet);
while (av_read_frame(pInputFormatContext, &Packet) >= 0) {
if (Packet.stream_index == nAudioStreamIdx)
{
fwrite(Packet.data, 1, Packet.size, destFile);
PaketPos = Packet.pos;
//__android_log_print(ANDROID_LOG_DEBUG, "test","Extract Progress : %d",getExtractProgress());
}
}
PaketPos = DCFSize;
return 1;
}