
Recherche avancée
Autres articles (79)
-
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 (...) -
Configurer la prise en compte des langues
15 novembre 2010, parAccé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 (...)
Sur d’autres sites (8388)
-
Random Fatal signal 11 (SIGSEGV) error in app using ffmpeg through ndk
20 janvier 2015, par grzebykI am getting a nasty but well known error while working with FFmpeg and NDK :
A/libc(9845): Fatal signal 11 (SIGSEGV), code 1, fault addr 0xa0a9f000 in tid 9921 (AsyncTask #4)
What am I doing ?
I am developing an application that streams live video feed from a webcam and enables user to pan and tilt the remote camera. I am using FFmpeg library built with NDK to achieve smooth playback with little delay.
I am using FFMpeg library to connect to the video stream. Then the ndk part creates bitmap, does the image processing and render frames on the
SurfaceView videoSurfaceView
object which is located in the android activity (java part).To move the webcam I created a separate class -
public class CameraMover implements Runnable{/**/}
. This class is a separate thread that connects through sockets with the remote camera and manages tasks connected ONLY with pan-tilt movement.Next in the main activity i created a touch listener
videoSurfaceView.setOnTouchListener(new View.OnTouchListener() {/**/
cameraMover.setPanTilt(some parameters);
/**/}which reads user’s finger movement and sends commands to the camera.
All tasks - moving camera around, touch interface and video playback are working perfectly when the one of the others is disabled, i.e. when I disable possibility to move camera, I can watch video streaming and register touch events till the end of time (or battery at least). The problem occurs only when task are configured to work simultaneously.
I am unable to find steps to reproduce the problem. It just happens, but only after user touches the screen to move camera. It can be 15 seconds after first interaction, but sometimes it takes app 10 or more minutes to crash. Usually it is something around a minute.
What have I done ?
- I tried to display millions of logs in logcat to find an error but
the last log was always different. - I created a transparent surface, that I put over the
videoSurfaceView
and assigned touch listener to it. It all ended in the same error. - As I mentioned before, I turned off some functionalities to find which one produces the error, but it appears that error occurs only when everything is working simultaneously.
Types of the error
Almost every time the error looks like this :
A/libc(11528): Fatal signal 11 (SIGSEGV), code 1, fault addr 0x9aa9f00c in tid 11637 (AsyncTask #4)
the difference between two errors is the number right after libc, addr number and tid number. Rarely the AsyncTask number varies - i received #1 couple times but I was unable to reproduce it.
Question
How can i avoid this error ? What can be the source of it ?
- I tried to display millions of logs in logcat to find an error but
-
aarch64 : vp9 : Add NEON optimizations of VP9 MC functions
14 novembre 2016, par Martin Storsjöaarch64 : vp9 : Add NEON optimizations of VP9 MC functions
This work is sponsored by, and copyright, Google.
These are ported from the ARM version ; it is essentially a 1:1
port with no extra added features, but with some hand tuning
(especially for the plain copy/avg functions). The ARM version
isn’t very register starved to begin with, so there’s not much
to be gained from having more spare registers here - we only
avoid having to clobber callee-saved registers.Examples of runtimes vs the 32 bit version, on a Cortex A53 :
ARM AArch64
vp9_avg4_neon : 27.2 23.7
vp9_avg8_neon : 56.5 54.7
vp9_avg16_neon : 169.9 167.4
vp9_avg32_neon : 585.8 585.2
vp9_avg64_neon : 2460.3 2294.7
vp9_avg_8tap_smooth_4h_neon : 132.7 125.2
vp9_avg_8tap_smooth_4hv_neon : 478.8 442.0
vp9_avg_8tap_smooth_4v_neon : 126.0 93.7
vp9_avg_8tap_smooth_8h_neon : 241.7 234.2
vp9_avg_8tap_smooth_8hv_neon : 690.9 646.5
vp9_avg_8tap_smooth_8v_neon : 245.0 205.5
vp9_avg_8tap_smooth_64h_neon : 11273.2 11280.1
vp9_avg_8tap_smooth_64hv_neon : 22980.6 22184.1
vp9_avg_8tap_smooth_64v_neon : 11549.7 10781.1
vp9_put4_neon : 18.0 17.2
vp9_put8_neon : 40.2 37.7
vp9_put16_neon : 97.4 99.5
vp9_put32_neon/armv8 : 346.0 307.4
vp9_put64_neon/armv8 : 1319.0 1107.5
vp9_put_8tap_smooth_4h_neon : 126.7 118.2
vp9_put_8tap_smooth_4hv_neon : 465.7 434.0
vp9_put_8tap_smooth_4v_neon : 113.0 86.5
vp9_put_8tap_smooth_8h_neon : 229.7 221.6
vp9_put_8tap_smooth_8hv_neon : 658.9 621.3
vp9_put_8tap_smooth_8v_neon : 215.0 187.5
vp9_put_8tap_smooth_64h_neon : 10636.7 10627.8
vp9_put_8tap_smooth_64hv_neon : 21076.8 21026.9
vp9_put_8tap_smooth_64v_neon : 9635.0 9632.4These are generally about as fast as the corresponding ARM
routines on the same CPU (at least on the A53), in most cases
marginally faster.The speedup vs C code is pretty much the same as for the 32 bit
case ; on the A53 it’s around 6-13x for ther larger 8tap filters.
The exact speedup varies a little, since the C versions generally
don’t end up exactly as slow/fast as on 32 bit.This is an adapted cherry-pick from libav commit
383d96aa2229f644d9bd77b821ed3a309da5e9fc.Signed-off-by : Ronald S. Bultje <rsbultje@gmail.com>
-
avcodec_open2 error -542398533
24 mars 2016, par bot1131357I am encountering an error when trying to open the codec with avcodec_open2(). I have tried the same code without any problems if I specify "avi" instead of "h264" in the av_guess_format() function.
I have seen avcodec_open2() returning -22, but -542398533... I don’t know what to make of it. Has anyone else encountered a similar problem ?
The library that I’m using is ffmpeg-20160219-git-98a0053-win32-dev. I would really really appreciate if you could help me out of this confusion.
This is my console output :
Video encoding
[libx264 @ 01383460] broken ffmpeg default settings detected
[libx264 @ 01383460] use an encoding preset (e.g. -vpre medium)
[libx264 @ 01383460] preset usage: -vpre <speed> -vpre <profile>
[libx264 @ 01383460] speed presets are listed in x264 --help
[libx264 @ 01383460] profile is optional; x264 defaults to high
Cannot open video codec, -542398533
</profile></speed>This is the code that I’m working with :
// Video encoding sample
AVCodec *codec = NULL;
AVCodecContext *codecCtx= NULL;
AVFormatContext *pFormatCtx = NULL;
AVOutputFormat *pOutFormat = NULL;
AVStream * pVideoStream = NULL;;
AVFrame *picture = NULL;;
int i, x, y, ret;
printf("Video encoding\n");
// Register all formats and codecs
av_register_all();
// guess format from file extension
pOutFormat = av_guess_format("h264", NULL, NULL);
if (NULL==pOutFormat){
cerr << "Could not guess output format" << endl;
return -1;
}
// allocate context
pFormatCtx = avformat_alloc_context();
pFormatCtx->oformat = pOutFormat;
memcpy(pFormatCtx->filename,filename,
min(strlen(filename), sizeof(pFormatCtx->filename)));
// Add stream to pFormatCtx
pVideoStream = avformat_new_stream(pFormatCtx, 0);
if (!pVideoStream)
{
printf("Cannot add new video stream\n");
return -1;
}
// Set stream's codec context
codecCtx = pVideoStream->codec;
codecCtx->codec_id = (AVCodecID)pOutFormat->video_codec;
codecCtx->codec_type = AVMEDIA_TYPE_VIDEO;
codecCtx->frame_number = 0;
// Put sample parameters.
codecCtx->bit_rate = 2000000;
// Resolution must be a multiple of two.
codecCtx->width = 320;
codecCtx->height = 240;
codecCtx->time_base.den = 10;
codecCtx->time_base.num = 1;
pVideoStream->time_base.den = 10;
pVideoStream->time_base.num = 1;
codecCtx->gop_size = 12; // emit one intra frame every twelve frames at most
codecCtx->pix_fmt = AV_PIX_FMT_YUV420P;
if (codecCtx->codec_id == AV_CODEC_ID_H264)
{
// Just for testing, we also add B frames
codecCtx->mb_decision = 2;
}
// Some formats want stream headers to be separate.
if(pFormatCtx->oformat->flags & AVFMT_GLOBALHEADER)
{
codecCtx->flags |= CODEC_FLAG_GLOBAL_HEADER;
}
if(codecCtx->codec_id == AV_CODEC_ID_H264)
av_opt_set(codecCtx->priv_data, "preset", "slow", 0);
// Open the codec.
codec = avcodec_find_encoder(codecCtx->codec_id);
if (codec == NULL) {
fprintf(stderr, "Codec not found\n");
return -1;
}
ret = avcodec_open2(codecCtx, codec, NULL); // returns -542398533 here
if (ret < 0)
{
printf("Cannot open video codec, %d\n",ret);
return -1;
}