quelea-projection / Quelea

Open source projection software for churches.
https://quelea.org
GNU General Public License v3.0
154 stars 145 forks source link

2024.0 Beta 1 - videos not recognized on the Videos tab #624

Closed DeeTigIT closed 6 months ago

DeeTigIT commented 6 months ago

When I add the 3 problematic videos, as mentionend in https://github.com/quelea-projection/Quelea/issues/622, to the Quelea Videos tab their codec seems to be not recognized. I also cannot add them to the schedule from the Videos.

S4

Is Gstreamer perhaps not yet "connected" to the Videos tab?

My config:

beng92 commented 6 months ago

I had a similar issue until I installed with the complete, but it worked after. Are there references to not being able to grab a duration or frame for the thumbnail in the logs?

berry120 commented 6 months ago

The video previews are still generated with jcodec at the moment so this makes sense - it grabs a 0 size preview image if it can't generate it, which is then making them non clickable too. I'll see if we can sensibly get gstreamer to generate the thumbnails too (and cache them.)

On Sun, 24 Dec 2023, 10:27 Ben Goodwin, @.***> wrote:

I had a similar issue until I installed with the complete, but it worked after. Are there references to not being able to grab a duration or frame for the thumbnail in the logs?

— Reply to this email directly, view it on GitHub https://github.com/quelea-projection/Quelea/issues/624#issuecomment-1868483941, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ6JDJTLDLZ3JWPXUL44ZTYK77Q7AVCNFSM6AAAAABBBNVPUGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNRYGQ4DGOJUGE . You are receiving this because you are subscribed to this thread.Message ID: @.***>

DeeTigIT commented 6 months ago

I was just digging up a log fragment:

Dec 24, 2023 11:39:36 AM org.quelea.windows.library.VideoListPanel$1 lambda$run$3 INFO: Grabbing frame for C:\Users\.quelea\vid\confetti-540.mpg

Dec 24, 2023 11:39:36 AM org.quelea.windows.library.VideoListPanel$1 lambda$run$3 INFO: Couldn't get video length java.io.IOException: Could not find movie meta information box at org.jcodec.containers.mp4.demuxer.MP4Demuxer.findMovieBox(MP4Demuxer.java:83) at org.jcodec.containers.mp4.demuxer.MP4Demuxer.(MP4Demuxer.java:77) at org.jcodec.containers.mp4.demuxer.MP4Demuxer.createMP4Demuxer(MP4Demuxer.java:50) at org.quelea.windows.library.VideoListPanel$1.lambda$run$3(VideoListPanel.java:163) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.base/java.lang.Thread.run(Unknown Source)

Dec 24, 2023 11:39:36 AM org.quelea.windows.library.VideoListPanel$1 lambda$run$3 INFO: Could not resize library video image org.jcodec.api.UnsupportedFormatException: MPEG PS is temporarily unsupported. at org.jcodec.api.FrameGrab.createFrameGrab(FrameGrab.java:63) at org.jcodec.api.awt.AWTFrameGrab.createAWTFrameGrab(AWTFrameGrab.java:39) at org.jcodec.api.awt.AWTFrameGrab.getFrame(AWTFrameGrab.java:108) at org.quelea.windows.library.VideoListPanel$1.lambda$run$3(VideoListPanel.java:177) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.base/java.lang.Thread.run(Unknown Source)

berry120 commented 6 months ago

@DeeTigIT I've now re-engineered the video previews to also use GStreamer - so this should now work out of the box with exactly the same compatibility as we have for video playback. If you could try the latest CI and let me know that'd be great!

DeeTigIT commented 6 months ago

Observations:

So, the Add videos button sometimes, but not allways, invokes the Gstreamer engine (apologies for my coal description :-)). Perhaps in relation with the thumbnail caching you mentionend? Even if a video isn't added as thumbnail: it is always added to the .quelea\vid folder Also: the missing thumbnails don't show up after Quelea restart (although they have the above debug logging).

berry120 commented 6 months ago

@DeeTigIT Hmm, that's an interesting one as I can't recreate it my side. There's no cache implemented (at least not yet) - so once the video is in the .quelea/vid folder it's treated the same as any other, or at least should be.

Is it always the same videos that don't show up in that panel after a restart?

berry120 commented 6 months ago

@DeeTigIT I've made a few changes regardless that should actually help speed up adding / removing videos by not refreshing the whole pane unless it's necessary, and just grabbing frames from the video(s) being added directly. This seems to work fine for me but again, definitely welcome your input and testing!

DeeTigIT commented 6 months ago

These 3 videos:

When such a video is present in vid: subsequent adding of new videos causes the strange behaviour described above.

https://mega.nz/file/j3AyxBzL

berry120 commented 6 months ago

Ah, gotcha - so the issue here is more that they can't be played (which by implication means that they can't have preview images generated since it uses the same decoder as for playing.) So this is more a supported video format issue than a code issue per se.

Let me do some digging and work out if there's a way we can sensibly support this format (looks to be VC-1 encoded WMV.)

DeeTigIT commented 6 months ago

Once such a video is present in .quelea\vid folder (but not on the Videos tab), subsequent added videos with valid format also do not appear anymore on the Videos tab when added. Is it possible to show these "problematic videos" on the tab with an "empty" thumbnail? (see also the first screenprint attached to this call)

berry120 commented 6 months ago

We could, but since we're now using the same mechanism for previews and playback, if we can't generate a preview then we can't play it either.

That being said, just "not appearing" is arguably rather confusing. Maybe a default thumbnail that has "unsupported" overlaid or something like that?

On Tue, 26 Dec 2023, 00:21 DeeTigIT, @.***> wrote:

Once such a video is present in .quelea\vid folder (but not on the Videos tab), subsequent added videos with valid format also do not appear anymore on the Videos tab when added. Is it possible to show these "problematic videos" on the tab with an "empty" thumbnail? (see also the first screenprint attached to this call)

— Reply to this email directly, view it on GitHub https://github.com/quelea-projection/Quelea/issues/624#issuecomment-1869164682, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ6JDNWI2HDKP2IUCF5R5LYLIKCJAVCNFSM6AAAAABBBNVPUGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNRZGE3DINRYGI . You are receiving this because you were assigned.Message ID: @.***>

DeeTigIT commented 6 months ago

default thumbnail that has "unsupported" overlaid : I think this is more informative than not showing the video on the tab. For me at least it would be a trigger trying to fix this issue by converting the video to mp4.

Some additional info:

S1

S2

Dec 26, 2023 10:50:25 AM org.quelea.windows.library.VideoListPanel updateVideos INFO: Updating videos

Dec 26, 2023 10:50:25 AM org.quelea.windows.library.VideoListPanel lambda$updateVideos$2 INFO: Checking file C:\Users\.quelea\vid\blue.avi

Dec 26, 2023 10:50:25 AM org.quelea.windows.library.VideoListPanel addVideoFile INFO: Adding video file C:\Users\.quelea\vid\blue.avi to panel

Dec 26, 2023 10:50:25 AM org.quelea.windows.library.LibraryPanel INFO: Creating library timer panel

Dec 26, 2023 10:50:25 AM org.quelea.windows.video.VidPreviewDisplay getPreviewImg INFO: PROCESSING URI file:/C:/Users//.quelea/vid/blue.avi

Dec 26, 2023 10:50:25 AM org.quelea.windows.main.MainPanel INFO: Creating preview panel

Dec 26, 2023 10:50:25 AM org.quelea.windows.main.MainPanel INFO: Creating live panel

Dec 26, 2023 10:50:25 AM org.quelea.windows.main.MainPanel INFO: Creating split panels

Dec 26, 2023 10:50:25 AM org.quelea.windows.main.MainPanel INFO: Created main panel

Dec 26, 2023 10:50:25 AM org.quelea.windows.library.VideoListPanel lambda$updateVideos$2 INFO: Checking file C:\Users\.quelea\vid\CameraDust.wmv

Dec 26, 2023 10:50:25 AM org.quelea.windows.library.VideoListPanel addVideoFile INFO: Adding video file C:\Users\.quelea\vid\CameraDust.wmv to panel

Dec 26, 2023 10:50:25 AM org.quelea.windows.video.VidPreviewDisplay getPreviewImg INFO: PROCESSING URI file:/C:/Users//.quelea/vid/CameraDust.wmv

Dec 26, 2023 10:50:26 AM org.quelea.windows.library.VideoListPanel lambda$updateVideos$2 INFO: Checking file C:\Users\.quelea\vid\classy-confetti-540.mpg

Dec 26, 2023 10:50:26 AM org.quelea.windows.library.VideoListPanel addVideoFile INFO: Adding video file C:\Users\.quelea\vid\classy-confetti-540.mpg to panel

Dec 26, 2023 10:50:26 AM org.quelea.windows.video.VidPreviewDisplay getPreviewImg INFO: PROCESSING URI file:/C:/Users//.quelea/vid/classy-confetti-540.mpg

Dec 26, 2023 10:50:26 AM org.quelea.windows.library.VideoListPanel lambda$updateVideos$2 INFO: Checking file C:\Users\.quelea\vid\clouds_moving_loop.wmv

Dec 26, 2023 10:50:26 AM org.quelea.windows.library.VideoListPanel addVideoFile INFO: Adding video file C:\Users\.quelea\vid\clouds_moving_loop.wmv to panel

Dec 26, 2023 10:50:26 AM org.quelea.windows.video.VidPreviewDisplay getPreviewImg INFO: PROCESSING URI file:/C:/Users//.quelea/vid/clouds_moving_loop.wmv

Dec 26, 2023 10:50:26 AM org.quelea.services.notice.NoticeFileHandler noticeFromFile WARNING: Cant get notice from folder: {0}

Dec 26, 2023 10:52:39 AM org.quelea.windows.main.actionhandlers.ExitActionHandler exit INFO: exit() called

berry120 commented 6 months ago

@DeeTigIT The issue with unsupported video files stopping valid ones from being processed should now be fixed. I've separately added #626 to track the WMV support in case we can get that sorted, and #627 to track the "unsupported" text on the overlay 👍

DeeTigIT commented 6 months ago

All 23 videos are loaded now on the tab:

afbeelding

The current thumbnail for the unsupported ones is striking already (it draws my attention):

afbeelding

DeeTigIT commented 6 months ago

Adding videos to the Videos tab, including unsupported ones, is no longer a problem. Previously I wrote:

When I add a new video to the Videos tab using the Add videos button on this tab, the behaviour is different now. With the previous CI releases the video would always appear on the tab. But with this CI: sometimes it does appear (and it has a thumnail and has debug logging as above) and sometimes it does not appear (no thumbnail, no debug logging). Whether it appears or not on the Videos tab: it is always added to the .quelea\vid folder.

But this is solved now as well! Great!

berry120 commented 6 months ago

@DeeTigIT Thanks very much! Is there anything outstanding on this one, or are you happy to close?

DeeTigIT commented 6 months ago

Closing is fine! Thanks!!