-
-
Notifications
You must be signed in to change notification settings - Fork 226
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
Video is recorded but are saved as empty & hoax files #692
Comments
Try uncommenting this line. |
Ok, will try that.
ffmpeg 6.1.1 , last ffmpeg version supported by release 9.1.1 as it won't build with ffmpeg7 Edit: Used upstream patch to build successfully with ffmpeg7.
Final & valid patch for enabling logs: https://gitlab.com/sameersharma2006/webcamoid-snap/-/commit/d342a777fee1afd9612457e5151472028d251b22 |
Logs (Maybe Relevant );
Still no specific logs. These are the options configured for video settings ; Changing codecs etc. has no effect on output all behave same. |
The log is missing information, there is not an output similar to this before those lines?
|
Which other video codecs are available for Matroska? |
Nope, nothing like that.
|
Hmm, Consider these situations. I) In default config, that is at first launch after install no video format & codec appears being specified. II) If i change video format to Matroska, the app automatically selects video & audio codec as ; III) Available video codecs are ; IV) Available audio codecs are ; More audio codecs are available which i can't statically capture but most of the audio codecs seems useless & hoax . |
The webm format is not available? are there other formats beside Matroska? |
This is what i meant by: In default config although not visible but if we click in the format configure settings it says webm although it has also no effect. |
Try writing this line here:
and give me the output. |
Ok i will do it. Done via https://gitlab.com/sameersharma2006/webcamoid-snap/-/commit/c7777ed88590c078ad5ccad648c16f4febc0ae0f
Nope
Hmm, although am not using ffmpeg build flags for VP8/9, i will try explicitly using VP8/9 build flags for ffmpeg. Edit: Enabled libvpx support for ffmpeg via https://gitlab.com/sameersharma2006/webcamoid-snap/-/commit/b74827611054d0965246cbb31bd75c2431a06eed |
@hipersayanX After enabling libvpx support webm appears as the default format . See 👇 But, still it produces empty and hoax video files with no relevant output. |
@hipersayanX After patching the app with your suggestion, logs from startup to video record are ;
|
The problem is that I'm missing the FFmpeg configuration line, and I can't do blind debugging. Are you sure that did you enabled this line?
The message should be printed by |
Try selecting MP4, MPEG-4 part 2, ACC, and try recording, does it works? |
@hipersayanX Nope as i said before any combination of codecs & formats results in null video files. Same is for your suggested combination. P.S. As before no logs are generated relating to video encoding/decoding. |
@hipersayanX Can't say how much impact this will have, but i have now added support for libx264 & libx265 in the ffmpeg build of webcamoid Edit: Still no relief , the problem persists. |
If you select MP4 format, it show a different error message or it is still the same? |
Also try replacing this line
with:
|
Nope, no logs even with mp4. |
Edit: Got it viz.
|
Something of Interest ? When i replace ffmpeg with gstreamer in general settings, only sound is recorded (Very Poorly) but not video, P.S. v4l wont capture videos and even photos when ffmpeg is replaced by gstreamer. And as always No Logs... |
I have enabled the line see viz. https://gitlab.com/sameersharma2006/webcamoid-snap/-/blob/main/local/patches/log.patch?ref_type=heads |
Got it , will patch accordingly. Edit: Patched viz. https://gitlab.com/sameersharma2006/webcamoid-snap/-/commit/303dcf2056958417af2fb460fdb697b705a0f46f |
Nope, still no ffmpeg related logs are available.
|
@hipersayanX Does master branch builds with QT5 ?, as Qt6 SDKs are not currently matured in the snap side. If yes, i will try building with master branch to see if any changes occur. |
Its weird the av_dump_format is not printing nothing, I did not studied enough the FFmpeg source code, but could it be that av_log_set_level is setting AV_LOG_TRACE as a environment variable and the Snap environment is blocking it 😕 ❓
Webcamoid 9.1 does not build with Qt6, only the master branch does and it is the future 9.2, which right now I'm stepping on the accelerator for releasing it as fast as I can. Also
This answer is not clear to me yet. When you set MP4, the messages in the console are still referencing Matroska, like this
or shows a different message? |
Also, can you try packaging this simple program and see if this works?
|
This is the setting for MP4 ; The above lines appear before changing to mp4, after changing to mp4 no logs appear even the above highlighted one. MP4 doesn't have any output specific to it. |
Ok. |
@hipersayanX I packaged the simple program as snap, it gives an output of Saved it as |
Maybe the messages are printed in the stderr but not in the stdout (or vice-versa)?
|
@hipersayanX I did modify the code as per your suggestion. Now the output is
I am attaching a tar ball containing the code, snap yaml & the snap itself |
I you write this right after
|
Ok i will add a patch for this. |
@hipersayanX After adding that line, still nothing appears not even the hello world.
|
Try removing |
@hipersayanX Nope even after removing that ffmpeg flag, the output is similar to what i posted previously. No logs, the hello world snippet also doesn't seem to work. |
Tbh I'm out of ideas, it seems to be a bug on your FFmpeg build but I don't know what could it be 😕 |
@hipersayanX Hmm,my ffmpeg build is from source and i am using that same build instruction in celluloid,mpv,audacious snaps all works fine. |
In the last case, the problem could be the version of FFmpeg that you are building against. You are building against FFmpeg 7.0 and Webcamoid 9.1.1 was released 1 year ago, and FFmpeg constantly make many changes to their API. |
@hipersayanX Will that have any security trade-offs, i mean security vulnerabilities (CVEs) ? Nevertheless i think your prediction is true given the fact that webcamoid snap actually used to worked last year with older ffmpeg. I will try to build with ffmpeg-4.2.9 Also Note; |
If that the case, apply the required patches.
That is not a problem, the build environment is irrelevant here. Try building with the known working version, ultimately try upgrading to a newer one. If I remember well on that time Arch had ffmpeg 5.x and it was working fine there. Also, if possible, I will try to make a new release for June, but not sure because there are some bugs I still need to fix. |
@hipersayanX Unfortunately it still doesn't work. I tested with 4.2.9 (Bugfix release with similar code to 4.2.7) & ffmpeg-5.1.4 Both produces hoax files . I think the best bet is waiting till new release & then re-visit these situation. I am not sure why is this happening AFAIK last year webcamoid snap did record video with only mkv format, but still it atleast recorded video.
|
There is not any guarantee that this gonna be fixed for the next release because:
Instead of waiting for the next release, try building from master branch and check if the situation still persists. |
@hipersayanX Ok, started building webcamoid master branch with qt6 libs viz. https://git.launchpad.net/webcamoid-snap?h=canary |
Also @hipersayanX What do you mean by;
You mean to say the snap works for you ? or you are talking about native packaging formats / root build & install. |
I'm talking about the binaries I distribute and the source code. I did tried adding a Snap build to the actions, but the build always failed, so I have removed it. |
@hipersayanX If you are building snaps without helpers or extensions, you also probably need to add a build-environment part for building your app along with command scripts, hooks etc. Nevertheless i will continue debugging against master branch. |
I don't know how Snap packages work, I just took code from here and there. Also, isn't possible to use ffmpeg from Ubuntu repositories instead of building it from scratch? or in general, any pre-build binary package from repositories ? |
One can use ffmpeg from ubuntu repos but it's a bit chaotic as it will include managing dependencies & will also increase app size leading to slower startups. |
Hey there snap maintainer here, i have opened this to seek some help regarding an issue that pests the snap builds.
Video is captured successfully but are saved as empty files having size of 0-15kb.
I have staged gstreamer, libvlc & ffmpeg.
No specific logs indicate anything related to this.
Snap bug-tracker issue: https://gitlab.com/sameersharma2006/webcamoid-snap/-/issues/1
Build recipe: https://gitlab.com/sameersharma2006/webcamoid-snap/-/blob/main/snapcraft.yaml?ref_type=heads
The text was updated successfully, but these errors were encountered: