JE-Random-Tech / ProJEcts

All code to the JE Random Tech Videos can be found here
0 stars 2 forks source link

Video with sound #1

Closed Vorosh closed 4 years ago

Vorosh commented 4 years ago

Is it possible to make the video that is played on the main layer with sound?

JE-Random-Tech commented 4 years ago

I haven't tested it but I think it should work. You might have to change line 65 of HapticBoard.py to

y= OMXPlayer(files[videoIndex], args=['--no-keys','--no-osd', '-b', '--layer', '1', '--video_queue', '1', '-n', '-1','-o','hdmi'], dbus_name='omxplayer.player'+str(videoIndex), pause=True)

or to

y= OMXPlayer(files[videoIndex], args=['--no-keys','--no-osd', '-b', '--layer', '1', '--video_queue', '1', '-n', '-1','-o','local'], dbus_name='omxplayer.player'+str(videoIndex), pause=True)

if you want the sound on the headphone jack. Hope that helps.

Vorosh commented 4 years ago

i did it but it doesn't work for me. Could you please test on your videos with sound and let me know if it works or not. Thanks

Vorosh commented 4 years ago

Hello! Did you manage to test with video with sound? I changed the line to this y= OMXPlayer(files[videoIndex], args=['--no-keys','--no-osd', '-b', '--layer', '1', '--video_queue', '1', '-n', '-1','-o','hdmi'], dbus_name='omxplayer.player'+str(videoIndex), pause=True)

but it gave no results... Do you know what the problem might be and how to fix it?

Vorosh commented 4 years ago

It looks like '-n', '-1'. If you remove this parameter, the sound appears.

Thanks for your project!

JE-Random-Tech commented 4 years ago

Perfect thanks for figuring it out! Works for me as well so I will update the file and reference your name.