
Recherche avancée
Médias (1)
-
The Great Big Beautiful Tomorrow
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
Autres articles (107)
-
Websites made with MediaSPIP
2 mai 2011, parThis page lists some websites based on MediaSPIP.
-
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
Contribute to a better visual interface
13 avril 2011MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community.
Sur d’autres sites (15163)
-
JavaFX media issue on Ubuntu : Could not create player
14 mai, par parsa2820I am trying to play mp3 file on JavaFX-11.0.2 on Ubuntu-20.04 using JDK-13.0.2 but I keep getting this same error every time. While I was searching for that I found that JavaFX uses older version of some libraries(See this issue on github). So I compiled and installed ffmpeg-3.1.11 from source. But the same exception is thrown. I put my code and error message bellow. I stuck on this for days so I really appreciate any help. Thanks.


note : This is not duplicate qeustion. All other questions regarding to this error happend on different versions and had different causes. I tried most of them but none of them works for me.


/usr/lib/jvm/jdk-13.0.2/bin/java --module-path /opt/javafx-sdk-11.0.2/lib --add-modules=javafx.controls,javafx.fxml,javafx.media -Djava.library.path=/opt/javafx-sdk-11.0.2/lib -javaagent:/opt/idea-IU-201.7846.76/lib/idea_rt.jar=46237:/opt/idea-IU-201.7846.76/bin -Dfile.encoding=UTF-8 -classpath /home/parsa/Documents/welanner/target/classes:/opt/javafx-sdk-11.0.2/lib/src.zip:/opt/javafx-sdk-11.0.2/lib/javafx-swt.jar:/opt/javafx-sdk-11.0.2/lib/javafx.web.jar:/opt/javafx-sdk-11.0.2/lib/javafx.base.jar:/opt/javafx-sdk-11.0.2/lib/javafx.fxml.jar:/opt/javafx-sdk-11.0.2/lib/javafx.media.jar:/opt/javafx-sdk-11.0.2/lib/javafx.swing.jar:/opt/javafx-sdk-11.0.2/lib/javafx.controls.jar:/opt/javafx-sdk-11.0.2/lib/javafx.graphics.jar:/home/parsa/.m2/repository/com/google/code/gson/gson/2.8.6/gson-2.8.6.jar view.GUI
Exception in Application start method
java.lang.reflect.InvocationTargetException
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.base/java.lang.reflect.Method.invoke(Method.java:567)
 at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:464)
 at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:363)
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.base/java.lang.reflect.Method.invoke(Method.java:567)
 at java.base/sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:1051)
Caused by: java.lang.RuntimeException: Exception in Application start method
 at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:900)
 at javafx.graphics/com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:195)
 at java.base/java.lang.Thread.run(Thread.java:830)
Caused by: MediaException: UNKNOWN : com.sun.media.jfxmedia.MediaException: Could not create player! : com.sun.media.jfxmedia.MediaException: Could not create player!
 at javafx.media/javafx.scene.media.MediaException.exceptionToMediaException(MediaException.java:146)
 at javafx.media/javafx.scene.media.MediaPlayer.init(MediaPlayer.java:518)
 at javafx.media/javafx.scene.media.MediaPlayer.<init>(MediaPlayer.java:421)
 at view.GUI.start(GUI.java:13)
 at javafx.graphics/com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$9(LauncherImpl.java:846)
 at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runAndWait$12(PlatformImpl.java:455)
 at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:428)
 at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
 at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:427)
 at javafx.graphics/com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:96)
 at javafx.graphics/com.sun.glass.ui.gtk.GtkApplication._runLoop(Native Method)
 at javafx.graphics/com.sun.glass.ui.gtk.GtkApplication.lambda$runLoop$11(GtkApplication.java:277)
 ... 1 more
Caused by: com.sun.media.jfxmedia.MediaException: Could not create player!
 at javafx.media/com.sun.media.jfxmediaimpl.NativeMediaManager.getPlayer(NativeMediaManager.java:295)
 at javafx.media/com.sun.media.jfxmedia.MediaManager.getPlayer(MediaManager.java:118)
 at javafx.media/javafx.scene.media.MediaPlayer.init(MediaPlayer.java:474)
 ... 11 more
Exception running application view.GUI

Process finished with exit code 1
</init>


This is my code. I know path and other things are correct because I can run it on Windows properly.


package view;

import javafx.scene.media.Media;
import javafx.scene.media.MediaPlayer;
import javafx.stage.Stage;

import java.io.File;

public class GUI extends javafx.application.Application{
 public void start(Stage stage) throws Exception {
 String path = "/home/parsa/Music/Ninoush.mp3";
 Media media = new Media(new File(path).toURI().toString());
 MediaPlayer mediaPlayer = new MediaPlayer(media);
 mediaPlayer.setAutoPlay(true);
 stage.setTitle("Playing audio");
 stage.show();
 }

 public static void main(String[] args) {
 launch(args);
 }
}



This is my ffmpeg and libraries versions :


ffmpeg version 3.1.11 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 9 (Ubuntu 9.3.0-10ubuntu2)
configuration: 
libavutil 55. 28.100 / 55. 28.100
libavcodec 57. 48.101 / 57. 48.101
libavformat 57. 41.100 / 57. 41.100
libavdevice 57. 0.101 / 57. 0.101
libavfilter 6. 47.100 / 6. 47.100
libswscale 4. 1.100 / 4. 1.100
libswresample 2. 1.100 / 2. 1.100



Edit 3 : I can play wav file this way but I can't play mp3.


-
Node Media Server not stream when i try to pass the argument "transpose=1" to ffmpeg
28 mai 2020, par joao.jlf4I'm using node-media-server to stream to instagram, and i need to rotate the original vídeo, to be portrait. I know that there is a flag on ffmpeg called transpose (there is rotate too), but when i pass it on node_relay_session.js on 24 line at the argv array, it returns me a "[Relay end]" on console, and it does'nt stream. When I remove the transpose flag from argv array it backs to stream normaly. Here is my config to nms :



import NodeMediaServer from 'node-media-server';
import removeBarOfRtmpUrl from './utils/removeBarRtmpUrl';
import path from 'path';
import { remote } from 'electron';

export default function(data) {

const streams = data.map(stream => ({
endpoint: removeBarOfRtmpUrl(stream.endpoint),
key: stream.key,
}))

const config = {
rtmp: {
port: 1935,
chunk_size: 60000,
gop_cache: true,
ping: 30,
ping_timeout: 60
},
http: {
port: 8000,
allow_origin: '*'
},
relay: {
// C:\Users\Usuario\Desktop\multistream\node_modules.bin\ffmpeg.exe
ffmpeg: path.join(remote.app.getPath('appData'), '..', 'Local', 'Programs', 'multistream', 'app', 'ffmpeg', 'bin', 'ffmpeg.exe'),
tasks: streams.map(stream => ({
app: 'live',
mode: 'push',
edge: ${stream.endpoint}/${stream.key},

 }))
},
};

const nms = new NodeMediaServer(config);
return nms;
}

// {
// app: 'live',
// mode: 'push',
// edge: 'rtmp://a.rtmp.youtube.com/live2/keyyoutube',
// },```



-
Matching a specific media format with ffmpeg/avconv
5 mai 2020, par Markus A.I need to encode a video from static images in such a way that it format-matches another one so I can splice the video streams together.



Here is the
mediainfo
of the file I'm trying to match :


Video
Format : AVC
Format/Info : Advanced Video Codec
Format profile : Baseline@L3.1
Format settings, CABAC : No
Format settings, ReFrames : 1 frame
Codec ID : 7
Duration : 2mn 46s
Bit rate : 1 614 Kbps
Width : 1 280 pixels
Height : 720 pixels
Display aspect ratio : 16:9
Frame rate mode : Variable
Standard : NTSC
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Stream size : 32.0 MiB (87%)
Color primaries : BT.601 PAL
Transfer characteristics : BT.601
Matrix coefficients : BT.601




So far, what I have been able to come up with is the following :



avconv -f image2 -framerate 1.2 -i loop_%d.tif -c:v libx264 -preset veryslow -profile:v baseline -level:v 31 -b:v 1614K -refs 1 loop.flv




This gets me to :



Video
Format : AVC
Format/Info : Advanced Video Codec
Format profile : Baseline@L3.1
Format settings, CABAC : No
Format settings, ReFrames : 1 frame
Codec ID : 7
Duration : 2s 917ms
Bit rate : 1 614 Kbps
Width : 1 280 pixels
Height : 720 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 1.200 fps
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Bits/(Pixel*Frame) : 1.459
Stream size : 575 KiB
Writing library : x264 core 142 r2431 a5831aa
Encoding settings : cabac=0 / ref=1 / deblock=1:0:0 / analyse=0x1:0x131 / me=umh / subme=10 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=0 / me_range=24 / chroma_me=1 / trellis=2 / 8x8dct=0 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=6 / lookahead_threads=1 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=0 / weightp=0 / keyint=250 / keyint_min=1 / scenecut=40 / intra_refresh=0 / rc_lookahead=60 / rc=abr / mbtree=1 / bitrate=1614 / ratetol=1.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / ip_ratio=1.40 / aq=1:1.00




Which, unfortunately, still isn't good enough as VLC Media Player crashes hard (just closes), logging
main error: Failed to compensate for the format changes, removing all filters; main error: Failed to create video converter
as soon as the stream splice occurs. I tried splicing another stream in that does have the exact same encoding, and it works fine. I'm also making sure to only splice on key-frames and I am including the NALU containing the AVCDecoderConfigRecord, so I'm pretty sure I'm not doing anything else wrong, especially since a couple other programs are fine with the splice. It's just VLC that expects an even closer match.


Here are things I've tried :



- 

- Adding
-vsync 2
to get variable frame rate mode. Doesn't change anything. - Adding
-color_primaries bt470bg -color_trc gamma28 -colorspace bt470bg
to try to get BT.601 PAL settings (several websites mentioned this). Doesn't change anything. - Adding
-s ntsc
to set the standard to NTSC. This also changes the resolution to 720x480 (not OK), and specifying-s 1280x720
in addition gets rid of the NTSC tag again.









If anyone knows what flags I need to supply to get closer, that would be super-helpful ! The stream I'm trying to match is encoded on an Android device (it's a live-stream), so I'm assuming it is built using the standard Android MediaCoder framework, in case that helps.


- Adding