
Recherche avancée
Autres articles (79)
-
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
La sauvegarde automatique de canaux SPIP
1er avril 2010, parDans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...) -
Multilang : améliorer l’interface pour les blocs multilingues
18 février 2011, parMultilang est un plugin supplémentaire qui n’est pas activé par défaut lors de l’initialisation de MediaSPIP.
Après son activation, une préconfiguration est mise en place automatiquement par MediaSPIP init permettant à la nouvelle fonctionnalité d’être automatiquement opérationnelle. Il n’est donc pas obligatoire de passer par une étape de configuration pour cela.
Sur d’autres sites (6946)
-
Build cpp code to run FFMPEG command in Anroid after generating .so file
22 octobre 2020, par Nikhil SolankiI built
FFMPEG
so files(libavcode.so, libavfilter.so, libavformat.so,libavutil.so, libswscale.so
) by following this tutorial. This tutorial is nice is helpful to build your own.so
files as per your library requirement.

Why I am building own one ?
I know that there is some already available libraries in github like bravobit's, tanersener's and also microshow's. These all have certain limitations like some of this will not work for target SDK 29 & 30 and tanersener's lib is good but there is problems with
-filter_complex
command's output and micrshow's lib is crashing in android 10 and 11 beta ! So, all have specific problems. So, I am considering to create own one.

What I have and already done
After following tutorial(mention in above) I successfully generated
.so
files and put it into my App.

Here is the screenshot of which I already done
.so
files :


So, you can see that I put all files into cpp folder. As per version I only need ARMV7 and AMR64.


What is the problem ?


Problem is that I have no idea how to create
.cpp
file to execute command and what is it actually and how to use it ? I also tried some other libraries.c
code but it didn't work for me. So, what is the code ofcpp
which can execute command ? Is there any other way of this ?

Note of this requirement
We can't run any executable file directly from directory in Android because its restricted in target Android 10 and 11. So, we compulsory need to build native code and call
class
or it'sfunction
.

-
FFMpeg Commands definition in library source code
25 janvier 2013, par SKCI tried running the
ffmpeg
commands from Android activity using an emulator in Windows OS, but i get errors.
I tried keeping both my resource files in/mnt/sdcard
as well the application package within/data/data
, but none of the options worked out for running the ffmpeg commands.These are the following approach i had taken while running the command through an android activity.
(Command to convert a series if images into a video)
Approach 1 :String[] cmd =new String[4];
cmd[0]="/data/data/com.example.commandlineffmpeg/files/ffmpeg";
cmd[1]="-i";
cmd[2]="/data/data/com.example.commandlineffmpeg/images/bpc_%03d.png";
cmd[3]="/data/data/com.example.commandlineffmpeg/out/out.avi";
Process p = Runtime.getRuntime().exec(cmd, null, new File("/data/data/com.example.ffmpegnew/out"));I have solved this, basically there was system permission issues and hence we were not allowed to access the system properties required to run the FFMpeg commands.
Thus we need to sign the apps with the system certificates and hence we can use FFMpeg commands directly from any android activity. -
How to run a python code via Django templates ?
18 novembre 2018, par Iskender BerdievI want to execute code below when the is submitted (project on Django) :
from os import system, listdir, remove
link = 'https://www.youtube.com/watch?v=ME9yO1KEVoo'
def download(): ## Downloading a video from YouTube using youtube-dl
system("youtube-dl -o download {}".format(link))
def convert(): ## Converting downloaded video to mp3 format via ffmpeg.exe(same directory)
listOfFiles = listdir('.')
for i in listOfFiles:
if i.startswith("download"):
name = i
system("ffmpeg -i {} download.mp3".format(name))
def main():
download()
convert()
main()I have tried to put this code into views.py :
class download(TemplateView):
def main(request):
if request.method == 'POST':
link = 'https://www.youtube.com/watch?v=ME9yO1KEVoo'
system("youtube-dl -o download {}".format(link))
listOfFiles = listdir('.')
for i in listOfFiles:
if i.startswith("download"):
name = i
system("ffmpeg -i {} download.mp3".format(name))
return redirect ('loader/wait.html')urls.py :
path('wait/', views.download.as_view(), name='wait')
and the html form which is submitted to run views.download.as_view() :
<form action="{% url " method="POST">{% csrf_token %}
<input type="submit" value="Yes" />
</form>