i am try VLC media player to record a video from IP camera. i found this command line to record video from ip camera.
"C:\Program Files\VideoLAN\VLC\vlc.exe" -I dummy --dummy-quiet http://user:password#ipAddress.com:port/videostream.asf --run-time=120 :demux=dump :demuxdump-file=C:\output_test.avi vlc://quit
The command line is working, i can get video with sound from IP camera. The only problems is the recorded video only can be played using VLC itself, the video also only have information which is only size(KB,MB), the windows cannot get the other information such as video length, size(Width*Height), etc. And the most important is video cannot be played using Window Media Player.
**EDIT
"C:\Program Files\VideoLAN\VLC\vlc.exe" -I dummy --dummy-quiet http://user:password#ipAddress.com:port/videostream.asf --run-time=120 --sout "#std{access=file,mux=avi,dst="c:\test.avi"}" vlc://quit
using this command, now i got all the video's info and playable using window media player and other players as well, but this time the there is no sound in video.
I'm implementing this in web app. I got the code running fine.
Does anyone here can provide me the correct command line to get working video with sound and also video's information.
i tried searching but cannot find the correct command line(if any). Tried VLC forum but got Error 403.
**note: i am using windows 7 OS.
try transcoding & mux
vlc.exe -I dummy --dummy-quiet http://user:password#ipAddress.com:port/videostream.asf --run-time=120 :sout=#transcode{vcodec=h264,vb=1024,acodec=mp3,ab=128,channels=2,samplerate=44100}:std{access=file,mux=avi,dst="c:\test.avi"}
Related
I was publishing my first C# Windows Form Application with a built-in audio player (I used System.Media), but when I tried to run the program on another PC of mine, it returned an exception and then crashed every time I click on the button to play audio so I was wondering if there was a way to play the audio on another PC without crashing.
Here's the code part I used to play the sound:
System.Media.SoundPlayer player = new System.Media.SoundPlayer("mouse_click.wav");
player.Play();
Then the PC I used to run the program returned this error: verify that the audio file path is correct.
Thank you everyone for the help!
If you want to add a Wav file to Windows Form Application, you can refer to the following steps:
First, add the Wav file in the Resources File (Project>Properties>Resources):
Second, refer to the following code to play the Wav file in VS:
System.Media.SoundPlayer player = new System.Media.SoundPlayer(Properties.Resources._15035);//Use your own filename in place of _15035
player.Play();
I am using Luxand Library as a face detection for my application.
I can open the webcam but when i want to open an ip camera with FSDKCam.OpenIPVideoCamera() method, it returns -15 and camera does not open.
I tested the url with VLC and everything was ok.
Does anybody have experience with this problem?
hi you cant use rtsp you must use mjpeg stream also you must provide video stream cgi luxand face sdk support mjpeg stream only to know your camera is support mjpeg if not find on specification try open a ip camera from browser then press f 12 and click element on camera if found video.cgi on url you camera is support mjpeg and you can get url from this website https://www.foscam.com/faqs/view.html?id=128
or
https://www.ispyconnect.com/man.aspx?n=china
note : on url you can support your username and password and port forget about add it sprite on textbox filed just add a full url on ip filed
example
http://192.168.1.100:26239/videostream.cgi?user=admin&pwd=888888
after you sure your camera support mjpeg stream you can also with face sdk use difrent way to display your camera
go to this website https://ip-webcam.appspot.com/ and download this app after download add your camera url wish is support cgi and mjpeg
example
http://192.168.1.100:26239/videostream.cgi?user=admin&pwd=888888
note some camera not support full url you have to add only
http://192.168.1.100:26239/
then add your username and password
in next filed
next step you must change on camera list on example your camera number for example if your fron camera int number for it 1 you must change it to 2 or 0 it is up of your device
cameraName = cameraList[2];//1//2//0
play on that number to know your ip camera number
am sure that will help you and am sure you get a right answer
best regard
ibrahim ali
mam
I am using VLC plugin to run an rtsp stream. The stream works good. But I want to store these videos to a file destination. I use this code but does not work.
axVLCPlugin21.playlist.add("rtsp://192.168.10.222:554/h264", null, ":sout=#transcode{vcodec=theo,vb=800,acodec=flac,ab=128,channels=2,samplerate=44100}:file{dst=C:\\123.ogg,no-overwrite} :sout-keep");
axVLCPlugin21.playlist.play();
This code only plays the rtsp stream but does not store. However, the same options can be used to stream directly on the VLC player.
Try using this Option for Storing Videos and displaying videos simultaneously
original commad to play in vlc
%vlc path% vlc.exe -vvv rtsp://192.168.10.22:554/h264 :sout=#transcode{vcodec=theo,vb=800,acodec=flac,ab=128,channels=2,samplerate=44100}:duplicate{dst=file{dst=C:\\\\123.mp4},dst=display}:sout-keep
if this works try to use
:sout=#transcode{vcodec=theo,vb=800,acodec=flac,ab=128,channels=2,samplerate=44100}:duplicate{dst=file{dst=C:\\\\123.mp4},dst=display}:sout-keep
":sout=#transcode{vcodec=theo,vb=800,acodec=flac,ab=128,channels=2,samplerate=44100}:file{dst=C:\123.ogg,no-overwrite} :sout-keep
also try to work in VLC gui by using streaming option+displaylocally+dst=file
Refrence:HowTo Receive and Save a Stream
VLC does not support recording of streams via plugin. Check this Link
I got a work around for it. I record the stream by calling the VLC directly. However, the player is hidden. I use this code:
Process.Start("C://Program Files//Videolan//VLC//VLC.exe","\"rtsp://xxx.xxx.xxx.xxx:554/h264\" --qt-start-minimized --sout=#transcode{vcodec=theo,vb=800,acodec=flac,ab=128,channels=2,samplerate=44100}:file{dst=C:\\123.ogg,no-overwrite}");
When I try to play a sound with a media element on my local machine I can't hear any sound. But I can hear sound in the simulator(same thing almost right?) and on my surface when I test it on there. It Doesn't work on all my pages too not just one on the local machine only too.
load event goes off in simulator but not in local machine. Also stream isn't null.
StorageFile file = await StorageFile.GetFileFromApplicationUriAsync(new Uri("ms-appx:///Assets/Sound/" +selectedCharacterSets[currentCharacterSet].character[currentCharacter].romaji + ".mp3", UriKind.Absolute));
var stream = await file.OpenAsync(FileAccessMode.Read);
mdeSound.SetSource(stream, file.ContentType);
Media failed event going off. Error: MF_MEDIA_ENGINE_ERR_SRC_NOT_SUPPORTED : HRESULT 0x8000FFFF. Does anyone know how to fix this and why its only on local machine?
EDIT: converted mp3 to wma... still doesn't load. converted it to wmv now it plays on local machine... why? I'm still confused. Opening the mp3 in the music app throws an error too, windows media player plays it fine.
There is an issue with the file you are trying to play. This could be because of DRM or because of bitrates being too high, etc. Windows 8 Pro can play more codecs than Windows 8 RT, but you said it worked on your Surface which is interesting. Try using Audacity or another program to save it as a lower bitrate MP3 or even a basic .WAV file.
It's also interesting that you couldn't play it as WMA but you could as WMV. WMV is video while WMA is audio. You may have a corrupt media stack on your machine.
P.S. The simulator essentially uses Remote Desktop, so there is a difference in how the audio gets played.
I would like to create a streaming audio from a Nao to my WPF form.
The only way that i have found is that we can download a recorded sound on Nao over SSH.
But its not a real streaming ...
If anyone has an idea !
Thanks
run this command on your NAO (login via ssh) gst-launch-0.10 pulsesrc ! audioconvert ! vorbisenc ! oggmux ! tcpserversink port=1234
list via VLC: vlc tcp://IP:1234/
You should look at gstreamer that is embedded in the robot. It would be a bit slow, but it'll be real streaming...
For windows:
Download the latest pulseaudio (not the official one) and creat a config.pa file with these two lines:
load-module module-native-protocol-tcp listen=0.0.0.0 auth-anonymous=1
load-module module-waveout
Run pulseaudio on your windows machine first with pulseaudio -F config.pa
On your NAO:
pacmd load-module module-tunnel-sink sink_name=nao server=192.168.1.152
(change this address to your windows one. Also make sure pulseaudio is running on windows otherwise this wont work)
qicli call ALAudioDevice._listOutputs
The previous command will show you the index number of the pulseaudio device you just created. Use this number in the next commands
pacmd set-default-sink 1
qicli call ALAudioDevice._setDefaultOutput 1
Thats it. Now everything comes through your pc speakers. index 0 is NAO's soundcard
For Linux:
Run this on terminal:
pactl load-module module-rtp-recv
On NAO:
pactl load-module module-null-sink sink_name=nao (creates the sink)
qicli call ALAudioDevice._listOutputs (checks the index on sink)
qicli call ALAudioDevice._setDefaultOutput 1
pactl load-module module-rtp-send source=nao.monitor
I find the Linux approach more stable. The TCP one on windows might break after some time.