-
Notifications
You must be signed in to change notification settings - Fork 135
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ingress capture card #204
Comments
Hello,
The easiest way is most likely to use that ffmpeg script.
If you use the same ffmpeg script to capture the device, make it TS or
Matroska format and ingest it into MistServer you should be good. That can
be done through:
ts-exec:ffmpeg COMMAND -f mpegts -
or
mkv-exec:ffmpeg COMMAND -f matroska -
There's also the option of using v4l2:
that should then show a select box of the V4L2 devices you can use, but if
the video device can only give RAW or JPEG data then you would need to
transcode it and it would be the same as running the ffmpeg command
manually.
With kind regards,
Balder Viëtor
Head of Testing
MistServer
…On Sat, Sep 7, 2024 at 4:55 PM JonnyTech ***@***.***> wrote:
I have a USB video capture device. Can access it with ffmpeg, vlc, etc.
How would I use that as an input source for Mist?
—
Reply to this email directly, view it on GitHub
<#204>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAN2RJHFX6VWHK5MY3U4OFLZVMHWNAVCNFSM6AAAAABN2C2SP6VHI2DSMVQWIX3LMV43ASLTON2WKOZSGUYTCNZSGI2DINY>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Thank you Balder @Rokamun
But I do not understand how to use these commands. Should I have commands called I found these, are they useful or a should I be doing something else?:
Mist was installed from Should I be running another version? I can also use Windows if that is easier. |
Hey,
The Linux version would definitely do this better than the Windows version,
so I wouldn't recommend switching.
The ts-exec and mkv-exec are sources within MistServer.
Both are a method of telling MistServer that whatever I fill in next should
be a command as performed in bash to run, and expect either TS or MKV
stream data coming from it.
So you'd fill this in as a source, which would have ffmpeg ingest the usb
device, then pass on ts or mkv data to MistServer which will then ingest it
after ffmpeg has made it compatible with MistServer.
One thing I forgot to mention: If your command uses ' or " then you'll
have to make a bash script out of the command. MistServer currently doesn't
handle commands with characters properly.
As an example:
[image: image.png]
This would run the script "videogen" available in path (in this case
/usr/bin/ ) add the " -g 25 -f mpegts - " to the script and then expect
TS data.
What the script does is available here:
https://news.mistserver.org/news/88/Generating+a+live+test+stream+from+a+server+using+command+line#1__Installing_videogen
Hope that clears up a few things!
With kind regards,
Balder Viëtor
Head of Testing
MistServer
…On Sun, Sep 8, 2024 at 2:54 AM JonnyTech ***@***.***> wrote:
Thank you Balder @Rokamun <https://github.com/Rokamun>
ts-exec:ffmpeg COMMAND -f mpegts -
or
mkv-exec:ffmpeg COMMAND -f matroska -
But I do not understand how to use these commands. Should I have commands
called ts-exec and mkv-exec? Because they do not exist on my system.
I found these, are they useful or a should I be doing something else?:
$ MistProcFFMPEG --help
Usage: MistProcFFMPEG [options] [configuration]
configuration (string) JSON configuration, or - (default) to read from stdin
--debug, -g (integer) The debug level at which messages need to be printed.
--help, -h Display usage and version information, then exit.
--json, -j Output connector info in JSON format, then exit.
--version, -v Display library and application version, then exit.
Version: 3.4, release Free_64
Built on Jul 31 2024, 12:56:41
$ MistInTS --help
Usage: MistInTS [options] [input] [output]
--datatrack, -D (string) Which parser to use for data tracks
--debug, -g (integer) The debug level at which messages need to be printed.
--headerOnly, -H Generate .dtsh, then exit
--help, -h Display usage and version information, then exit.
input (string) Name of the input file or - for stdin
--inputtimeout, -i (integer) Time in seconds to keep the input process loaded without activity
--json, -j Output MistIn info in JSON format, then exit
output (string) Name of the output file or - for stdout
--pagetimeout, -P (integer) For bufferless or live inputs like HLS, set the timeout in seconds for old, inactive pages to be deleted. A longer value results in more memory usage, but ensures that recently buffered data stays in memory for longer
--raw, -R Enable raw MPEG-TS passthrough mode
--realtime, -r Feed the results of this input in realtime to the buffer
--stream, -s (string) The name of the stream that this connector will provide in player mode
--version, -v Display library and application version, then exit.
Version: 3.4, release Free_64
Built on Jul 31 2024, 12:56:41
Mist was installed from mistserver_64V3.4.tar.gz and the web interface
shows Version:3.4 Free_64.
Should I be running another version? I can also use Windows if that is
easier.
—
Reply to this email directly, view it on GitHub
<#204 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAN2RJB6N2RSZKWWSEBAZRLZVON27AVCNFSM6AAAAABN2C2SP6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMZWGQ4TSNJXGA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
When posting via email, GitHub strips all attachments and images. Are you able to post your message directly at #204 so that I can see the image, please? If I understand correctly, I use my ffmpeg command and then another within the |
I followed the instructions from the linked page and created the file:
Then added the stream in the web interface: But get this error: So I try videogen from the command line:
The script produces a valid output because I can send it to a file correctly:
In the web interface, I deleted all protocols and enabled default protocols. No change. Any idea what I am doing wrong? |
Thank you for your continued assistance.
I am using latest build too: Reset server:
I hope that you don't mind the pictures, it is easier to show than write: Make sure the command works:
Can I supply any other logs? |
Hmm, One last thing I can think of is adding the path to the script. I wouldn't know why, but perhaps it isn't finding the script properly. So could you try adding the
Shouldn't be needed though, assuming MistServer runs as root it should find that as well.. Logs The logs themselves you can grab using: Alternatively, we can just push You sort of tried this using RTSP already, but we can also just push the streaming data into MistServer if the stream source is set to Once set to push, you can push into it using:
|
No change
SRT:
Mist log:
RTMP:
Logs
RTSP:
Logs
Is there another build that I could try? |
The disabled protocols aren't a problem, all of those require manual input to get to work so they cannot be automatically activated. How are you running MistServer however? If you're running it by booting up directly MistController I'd understand the logs not being there, or possibly you're running it on an OS that has systemd logging disabled bye default? Pushes To which you'd use As an example endpoint you could try pushing to one of our testing servers using: The playback url for this would be: You'll have to bring up a bit of patience for that server, it is quite slow. Version or as script: |
Aha! I have setup a
My init system is sysVinit, not systemd.
I did not understand the process before, but your patience has certainly educated me. So the missing link is the videogen ingest. I would love to get that working, seeing as you say that pushing is slower. |
It is indeed slower, though the measure of it is within the keyframe interval of things and it is startup related, once running it "should" be about the same. The biggest slowdown is most likely the ffmpeg buffer in this, but it would be present in both methods. Though it is still weird to me that TS/MKV-exec as source input doesn't work... The last thing you can try to possibly debug the why the process might not be working is to run it manually from the terminal:
That should boot it in the terminal and hopefully give some sensible feedback as to what might be going wrong. |
I have a USB video capture device. Can access it with ffmpeg, vlc, etc. How would I use that as an input source for Mist?
The text was updated successfully, but these errors were encountered: