
Recherche avancée
Médias (1)
-
DJ Dolores - Oslodum 2004 (includes (cc) sample of “Oslodum” by Gilberto Gil)
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
Autres articles (50)
-
L’agrémenter visuellement
10 avril 2011MediaSPIP est basé sur un système de thèmes et de squelettes. Les squelettes définissent le placement des informations dans la page, définissant un usage spécifique de la plateforme, et les thèmes l’habillage graphique général.
Chacun peut proposer un nouveau thème graphique ou un squelette et le mettre à disposition de la communauté. -
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 -
ANNEXE : Les plugins utilisés spécifiquement pour la ferme
5 mars 2010, parLe site central/maître de la ferme a besoin d’utiliser plusieurs plugins supplémentaires vis à vis des canaux pour son bon fonctionnement. le plugin Gestion de la mutualisation ; le plugin inscription3 pour gérer les inscriptions et les demandes de création d’instance de mutualisation dès l’inscription des utilisateurs ; le plugin verifier qui fournit une API de vérification des champs (utilisé par inscription3) ; le plugin champs extras v2 nécessité par inscription3 (...)
Sur d’autres sites (6890)
-
I tried to play the audio on Alexa skill from my S3 Bucket, from the test tab, **it show but in fact, I can't hear any sound
19 avril 2022, par Siti MaynaSo I tried to play the audio on Alexa skill from my S3 Bucket, from the test tab, it show but in fact, I can't hear any sound. Another fact is, that I tried to use the sample audio from https://developer.amazon.com/en-US/docs/alexa/custom-skills/ask-soundlibrary.html and it is worked, but why it won't work when it comes from my own S3 Bucket ?


Notes :


I've tried to test the skill using my mobile phone also.


I've tried to encode the audio using FFmpeg.


I've tried to use Jovo to convert the audio. https://v3.jovo.tech/audio-converter


I don't know how to fix this error.


There is no error message on cloud watch.


Assumptions :
There is some problem related to the audio resources or there is more set to play audio from S3 Bucket since the sample audio is working.


Steps to reproduce :




Build the interaction model






Encode the audio to make it Alexa skill friendly (fulfill the requirements, like sample rate, etc), I used and tried all of these :




A :


ffmpeg -i -ac 2 -codec:a libmp3lame -b:a 48k -ar 16000 -write_xing 0 



B :


ffmpeg -i -ac 2 -codec:a libmp3lame -b:a 48k -ar 24000 -write_xing 0 



C :


ffmpeg -y -i input.mp3 -ar 16000 -ab 48k -codec:a libmp3lame -ac 1 output.mp3





Upload the audio resources on S3Bucket
Audio sample on s3 storage but none of them are produce any sounds






Use the link and insert it to APLA.json





 {
 "type": "APLA",
 "version": "0.91",
 "description": "Simple document that generates speech",
 "mainTemplate": {
 "parameters": [
 "payload"
 ],
 "type": "Sequencer",
 "items": [
 {
 "type": "Audio",
 "source": "https://72578561-d9d8-47b4-811c-cafbcbc5ddb9-us-east-1.s3.amazonaws.com/Media/one-small-step-alexa-24.mp3"
 }
 ]
 }
 }




notes : I change the link sources based on audio that I tried.




the intent on lambda_function.py :




def _load_apl_document(file_path):
 # type: (str) -> Dict[str, Any]
 """Load the apl json document at the path into a dict object."""
 with open(file_path) as f:
 return json.load(f)

class LaunchRequestHandler(AbstractRequestHandler):
 """Handler for Skill Launch."""
 def can_handle(self, handler_input):
 # type: (HandlerInput) -> bool

 return ask_utils.is_request_type("LaunchRequest")(handler_input)

 def handle(self, handler_input):
 # type: (HandlerInput) -> Response
 logger.info("In LaunchRequestHandler")

 # type: (HandlerInput) -> Response
 speak_output = "Hello World!"
 # .ask("add a reprompt if you want to keep the session open for the user to respond")

 return (
 handler_input.response_builder
 #.speak(speak_output)
 .add_directive(
 RenderDocumentDirective(
 token="pagerToken",
 document=_load_apl_document("APLA.json"),
 datasources={}
 )
 )
 .response
 )





Deploy






Test it






The result of the test on my end :

The response for testing




the JSON response :


{
 "body": {
 "version": "1.0",
 "response": {
 "directives": [
 {
 "type": "Alexa.Presentation.APLA.RenderDocument",
 "token": "pagerToken",
 "document": {
 "type": "APLA",
 "version": "0.91",
 "description": "Simple document that generates speech",
 "mainTemplate": {
 "parameters": [
 "payload"
 ],
 "type": "Sequencer",
 "items": [
 {
 "type": "Audio",
 "source": "https://72578561-d9d8-47b4-811c-cafbcbc5ddb9-us-east-1.s3.amazonaws.com/Media/one-small-step-alexa-24.mp3"
 }
 ]
 }
 },
 "datasources": {}
 }
 ],
 "type": "_DEFAULT_RESPONSE"
 },
 "sessionAttributes": {},
 "userAgent": "ask-python/1.16.1 Python/3.7.12"
 }
}





On my cloud Watch :
Cloud Watch




-
Why do you need analytics for your WordPress ?
7 avril 2020, par Joselyn Khor — Analytics Tips, Plugins -
use ffmpeg in java ubuntu
3 juin 2014, par Roylisto Putra Pradanai try to convert video using ffmpeg in ubuntu.
ffmpeg -i inputfile.flv -sameq outputfile.mpeg
this works if change directory to inputfile directory.
is that posible to use this command ?
ffmpeg -i "home/Documents/inputfile.flv" -sameq "home/Documents/outputfile.mpeg"
i don’t want to change directory when i use that command, because that command is using for my java code.
so my input file and output file is variable in my code .here’s my full code
package Converter;
import Controller.ConvertedButtonListener;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.URL;
import java.util.Arrays;
/**
*
* @author roylisto
*/
public class VideoConverter {
private String defaultFile;
private String convertedFile;
private ConverterThread myThread;
private ConvertedButtonListener butListener;
public VideoConverter(String fileDir,String convertOutput,ConvertedButtonListener buttonListener){
this.defaultFile=fileDir;
this.convertedFile=convertOutput;
this.butListener=buttonListener;
}
public void convertToMjpeg(){
String[] listCommands={"ffmpeg","-i","\""+defaultFile+"\"","-qscale","0","\""+convertedFile+"\""};
myThread=new ConverterThread(listCommands,this);
myThread.start();
}
public void setCommandStream(String stream){
butListener.setCommandOutput(stream);
}
class ConverterThread extends Thread{
VideoConverter vc;
String[] command;
ConverterThread(String[] command,VideoConverter vc){
this.command=command;
this.vc=vc;
}
public void run(){
synchronized(vc){
try{
String s = null;
Process process = new ProcessBuilder(command).start();
BufferedReader stdInput = new BufferedReader(new InputStreamReader(process.getInputStream()));
BufferedReader stdError = new BufferedReader(new InputStreamReader(process.getErrorStream()));
StringBuffer start= new StringBuffer();
// read the output from the command
while ((s = stdInput.readLine()) != null)
{
start.append(s);
vc.setCommandStream(s);
}
stdInput.close();
// read any errors from the attempted command
while ((s = stdError.readLine()) != null)
{
start.append(s);
vc.setCommandStream(s);
}
}catch(Exception ex){
System.out.println(ex.toString());
}
}
}
}
}until now my code works well in windows with some modification like change ffmpeg to ffmpeg.exe because ffmpeg isn’t native in my windows. but when i use my code in ubuntu
it show this error"/home/roylisto/Documents/Tugas Akhir/Video Master/3a.avi": No such file or directory
UPDATE
solve problem, here’s my code :)package Converter;
import Controller.ConvertedButtonListener;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.URL;
import java.util.Arrays;
/**
*
* @author roylisto
*/
public class VideoConverter {
private String defaultFile;
private String convertedFile;
private ConverterThread myThread;
private ConvertedButtonListener butListener;
public VideoConverter(String fileDir,String convertOutput,ConvertedButtonListener buttonListener){
this.defaultFile=fileDir;
this.convertedFile=convertOutput;
this.butListener=buttonListener;
}
public void convertToMjpeg(){
String[] listCommands={"ffmpeg","-i",defaultFile,"-qscale","0",convertedFile};
myThread=new ConverterThread(listCommands,this);
myThread.start();
}
public void setCommandStream(String stream){
butListener.setCommandOutput(stream);
}
class ConverterThread extends Thread{
VideoConverter vc;
String[] command;
ConverterThread(String[] command,VideoConverter vc){
this.command=command;
this.vc=vc;
}
public void run(){
synchronized(vc){
try{
String s = null;
Process process = new ProcessBuilder(command).start();
BufferedReader stdInput = new BufferedReader(new InputStreamReader(process.getInputStream()));
BufferedReader stdError = new BufferedReader(new InputStreamReader(process.getErrorStream()));
StringBuffer start= new StringBuffer();
// read the output from the command
while ((s = stdInput.readLine()) != null)
{
start.append(s);
vc.setCommandStream(s);
}
stdInput.close();
// read any errors from the attempted command
while ((s = stdError.readLine()) != null)
{
start.append(s);
vc.setCommandStream(s);
}
}catch(Exception ex){
System.out.println(ex.toString());
}
}
}
}
}