Announcement

Collapse
No announcement yet.

Watch YouTube from laptop to TV

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Aside, I noticed your Post #2 did mention audio issues versus versions. But I can't believe the 2018 TV won't play the sound, but, as I say, I'm a-v illiterate here.
    An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

    Comment


      #17
      Hmmm,

      https://www.videoconverterfactory.co...amsung-tv.html

      getting ready for some dinner here, just quickly scanned this, seems relevant, but not sure this actually applies or that I can do this.
      An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

      Comment


        #18
        There's other websites promoting audio/video codec converters, but I'm not yet finding one that works in Linux Kubuntu, only for Windows or Mac. Will keep messing with this as time permits. (I have a Windows 10 here on a laptop, but sure as hell would prefer not to boot into it and do all the many past-due updates and maintenance ...)
        An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

        Comment


          #19
          Ah, maybe Handbrake that SpecialEd mentioned in Post #7. Sorry for the rapid-fire posts, just talking to myself here.
          An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

          Comment


            #20
            VLC has a transcoder (under Media > Convert/Save), pretty nice. But (I think?) I need H.264 video with AAC audio codec -- under wrapper either mkv or mp4 (it shouldn't matter which I use), and that option is not offered in my VLC (I did try whatever they did offer, with no results, like a 264 with MP4 and so on). Handbrake's docs indicate that conversion (from mkv and whatever I have in that mkv) to h.264 + AAC may be possible. Learning about Handbrake will be for tomorrow, if I can swing it time-wise.
            An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

            Comment


              #21
              Solved:

              Get the youtube-dl PPA.
              Get the transcoder Handbrake to change video/audio codec(s) on the video.

              Thanks everyone for all the tips.

              Note: I did not yet try to solve the problem in the OP by using a HDMI cable. I'll try to do that sometime and post back with that. As shag00 says, that should be a piece of cake.

              Summary:

              I installed youtube-dl using my Muon Package Manager. (Suggested by SpecialED.)
              Then used youtube-dl to download the YouTube video. That didn't work.
              Oshunluvr says you must frequently update youtube-dl from its PPA.
              I installed the PPA for youtube-dl and ran an update (see below).
              Then successfully downloaded the video using youtube-dl.
              I did this for two videos.
              I copied each to the flashdrive, plugged that flashdrive into the Samsung TV.
              One video ran perfectly.
              The second video threw this message: Audio codec not supported. So I could get video but no sound for the second video.
              I googled this problem and found that I need a transcoder to change the audio codec associated with the second video.
              SpecialED suggested Handbrake.
              I got the PPA for Handbrake, downloaded it, ran it to change the audio codec in that problem video, and then the video ran OK on the Samsung TV. (Actually, I had to make one more simple change to the video to make my TV see it--simply changing the extension associated with the video--see below for details.)

              Done.

              - - - - - - - - - -

              Details, for fellow stumblers.

              For people like myself who are clueless on video-audio stuff, I'll include some details to help you stumble through this. Usually, when you go to a PPA webisite or a package Documentation-Guide, it will be (fairly) clear what you should do, step by step. But I'll record my stumbling here, if that might help you stumble better.

              For downloading YouTube videos, the package: youtube-dl

              But then you need to get frequent updates for it to run right. For that you need to install the PPA on to your system, as oshunuvr pointed out in Post #9.

              The website PPA (for updates etc.) is:
              https://www.ubuntuupdates.org/ppa/webupd8
              and follow the instructions given there for installing the PPA which manages youtube-dl.
              (Note: Main site is http://www.webupd8.org/)
              To add this PPA:
              sudo add-apt-repository ppa:nilarimogard/webupd8
              Then:
              sudo apt-get update
              Then install the package they tell you to install (in this case for Bionic):
              sudo apt-get install 0.5.2-1+git20191113~webupd8~bionic0
              Then I checked my Muon Package Manager, found the GUI youtube-dig and installed it.
              Open the GUI by running this command at Konsole:
              /usr/bin/youtube-dl-gui
              Then I entered the URL of the YouTube video:
              https://www.youtube.com/watch?v=_PLq0_7k1jk
              and pressed the Start icon (lower right), it downloaded the vid to my /home/mike, it appeared as an mp4 file, double-click to run it in Kubuntu--everything's OK.
              (You can also run the download directly without the GUI at Konsole:
              youtube-dl https://www.youtube.com/watch?v=_PLq0_7k1jk )
              I copied that mp4 video from my /home/mike to a flash drive, tested it on a Samsung TV, and it ran correctly.

              But then a problem with another YouTube video:
              I downloaded it, it is a (popular) .mkv file, copied it to the flashdrive, tried to run it on the Samsung TV, and got the message Audio codec not supported (the video, however, did play OK).

              I googled the phrase: Audio codec not supported on Samsung TV playing mkv video, and found out I need a transcoder.

              (Briefly, the extensions, like mkv in this case, are just containers, inside is the video codec and the audio codec, and maybe other stuff. Apparently, the video codec was OK, but I need a different audio codec the TV will play. The googling told me that a video codec called H.264 and an audio codec called AAC should work on my TV. So you need a transcoder that will change the codec(s) inside the .mkv container attached to that video.)

              VLC has a transcoder built in. But, as its options, it doesn't perform the changes it seems I needed.

              SpecialEd mentioned the transcoder Handbrake in Post #7.

              So try Handbrake:

              Features of Handbrake:
              https://handbrake.fr/features.php

              Guide:
              https://handbrake.fr/docs/en/

              I went here
              https://handbrake.fr/
              Then here
              https://handbrake.fr/downloads.php
              And finally here
              https://launchpad.net/~stebbins/+arc...brake-releases

              So add the PPA (to my repository in Kubuntu):
              sudo add-apt-repository ppa:stebbins/handbrake-releases
              and then:
              sudo apt-get update
              Then you need an interface, GUI or CLI, which you can install in two ways: using Muon or at the Konsole command line:
              GUI:
              apt-get install handbrake-gtk
              CLI:
              apt-get install handbrake-cli

              (I used Muon, entering handbrake, where it offered both the gtk graphical and the CLI interfaces.)
              Muon tells you (under installed files) that the graphical interface is at
              /usr/bin/ghb
              (and so you can run that as a command at Konsole and open Handbrake).
              I also found Handbrake at K > Applications > Multimedia

              Open Handbrake.
              For pre-sets I had to look around, found Devices as a big icon, upper right, under Devices I hovered the mouse over Android 1080p30 and saw H264 video and AAC audio in an MP4 container! Selected it.
              (Note: the Presets drop-down list did not show me this info on the 1080p30 choice.)

              Ran Handbrake. It went through OK, assigning the extension .m4v to the resulting video. I copied the resulting video to the flashdrive.

              But then my TVs didn't see it -- it had an .m4v extension, so I changed the extension to .mp4 (remembering that the extension is just a container for the codecs). Then the video ran OK on the TV.

              Done.
              (If you get stuck along the way, post back and someone will help.)

              If you ever get this: YouTube said: This video is unavailable.
              see the next post for a possible fix ...
              Last edited by Qqmike; Apr 10, 2020, 08:13 PM.
              An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

              Comment


                #22
                There's a problem with my posted solution (Post # ).

                It may work OK for some or even for many videos, but you may get this error on some:

                YouTube said: This video is unavailable.

                To fix this, you can try this: Remove the youtube-dl program that you installed using Muon or your package manager. Install it again in a certain way (see below). To update it, use at Konsole: sudo youtube-dl -U. And to use it to download videos use this syntax: youtube-dl <the URL of the video you want to download>. As explained here:

                The error, YouTube said: This video is unavailable.

                Generally, the video may be there, but you need the latest version of youtube -dl.

                From this:
                https://github.com/ytdl-org/youtube-...ate-youtube-dl

                they say this:

                If you have installed youtube-dl using a package manager like apt-get or yum, use the standard system update mechanism to update. Note that distribution packages are often outdated. As a rule of thumb, youtube-dl releases at least once a month, and often weekly or even daily. Simply go to https://yt-dl.org to find out the current version. Unfortunately, there is nothing we youtube-dl developers can do if your distribution serves a really outdated version. You can (and should) complain to your distribution in their bugtracker or support forum.
                As a last resort, you can also uninstall the version installed by your package manager and follow our manual installation instructions. For that, remove the distribution's package, with a line like
                sudo apt-get remove -y youtube-dl
                Afterwards, simply follow our manual installation instructions (https://ytdl-org.github.io/youtube-dl/download.html) :
                sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl
                sudo chmod a+rx /usr/local/bin/youtube-dl
                hash -r
                Again, from then on you'll be able to update with sudo youtube-dl -U.
                Run the download directly without the GUI at Konsole; e.g.,
                youtube-dl https://www.youtube.com/watch?v=xyxetc)
                An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                Comment


                  #23
                  Hi
                  I realize that the thread is closed but I just hook an HDMI cable into either a laptop, and boot with it as such and Kubuntu always found it, no problem. And same with my DEKSTOP. I previously used the old monitor cable because of the particular t.v. it has that and also HDMI but now I just use the HDMI and it automagically is found.

                  With the laptop you MAY have to go to System Settings / hardware / display and monitor and choose between the lappy and the t.v. but it should just work.

                  woodsmoke

                  woodsmoke
                  sigpic
                  Love Thy Neighbor Baby!

                  Comment


                    #24
                    Actually, Woody, the thread is not closed and any further ideas are welcome. Thanks for your input re the HDMI cable, as that was also on my list to try/experiment with. I don't have that cable and so must buy it and so keep putting it off!
                    An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                    Comment


                      #25
                      Hi
                      the only "problem" that I have ever actually "encountered" with HDMI is that, for me... my tired old eyes...

                      The presentation is SO GOOD on a regular moniter that it "looks harsh" to me and I actually have to "tone down" the resolution to make it comfortable.

                      But on a t.v. it is GREAT!!!

                      keep us informed, using a lappy AT ALL can be a problem and I'm sure that you will provide valuable user information to other people.

                      woody
                      sigpic
                      Love Thy Neighbor Baby!

                      Comment


                        #26
                        well sorry I have been absent for a wile ,,,,I do this all the time , both TV as monitor and "youtube-dl"

                        as you have discovered youtube-dl needs to be the one from their website and needs to be kept updated as youtube keeps changing little things hear and their every so often . I do not however try to get the TV to play them off a USB , the vids I DL are just some of my faves for off line viewing .

                        NOW the TV as monitor @hear goes like this ,,,,,,,(this is NOT a smart TV just a 1080p 38" VIZIO )

                        the TV has 2 HDMI in ports , HDMI-1 and HDMI-side , the HDMI-1 is the main port and on my TV has ARC (audio return channel) active on it , this allows audio from the TV to back feed to an AVR (audio video receiver) a HK-7.1 channel surround sound system , SO the HDMI-1 on the TV runs to the main HDMI ARC capable input on the AVR .

                        in corner next to the TV is a desktop computer connected to an 20" HP monitor through VGA and the TV through HDMI to the HDMI-side port on the TV .

                        now in this setup their is nothing to do really even if the power blinks out restarting the desktop reconnects to the TV even if it's off , I think the first time I set it up I MAY have had to go to system settings>display and monitor to activate the TV , but have never had to do that again in a Looooooong time now .

                        so setup like this we can be sitting hear watching TV , get board with it , grab the TV remote and select the HDMI-side input and bam theirs a web browser (firefox) and all the internet for our enjoyment (we have a small wireless keybord/trackpad hooked to the desktop), netflix amazon-prime hulu youtube , yada yada yada , ,,,,so we settle on some youtube music , turn down the TV's volume and turn on the AVR , Aaaaaa now we have 975 W of surround sound blasting youtube video's in a 12X18 living room

                        VINNY
                        Last edited by vinnywright; Apr 11, 2020, 09:53 AM.
                        i7 4core HT 8MB L3 2.9GHz
                        16GB RAM
                        Nvidia GTX 860M 4GB RAM 1152 cuda cores

                        Comment


                          #27
                          Originally posted by Qqmike View Post
                          ...
                          hash -r
                          ...
                          That's the first time in a LOOOONNNGGG time I've seen the hash utility being used, even if it is being used to reset the hash database. But, don't worry! The history command will bring it all back!
                          "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
                          – John F. Kennedy, February 26, 1962.

                          Comment


                            #28
                            Thanks, Woody for the added input.

                            GG, I copied that code directly from that link.

                            Vinny: so setup like this we can be sitting hear watching TV , get board with it , grab the TV remote and select the HDMI-side input and bam theirs a web browser (firefox) and all the internet for our enjoyment (we have a small wireless keybord/trackpad hooked to the desktop), netflix amazon-prime hulu youtube , yada yada yada , ,,,,so we settle on some youtube music , turn down the TV's volume and turn on the AVR , Aaaaaa now we have 975 W of surround sound blasting youtube video's in a 12X18 living room
                            Now there's some motivation to get things in order! Small house here, 4 TVs, two are old (one is very old but I found a digital converter at Amazon that also provided DVR capability, amazingly), one is too small, etc. Gotta get the house in order and get one good central unit like you describe.
                            An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                            Comment


                              #29
                              Vinny.

                              Your setup, aside from HULU etc. sounds almost exactly like mine, the living room I mean, only I use the "airmouse" and small keyboard.

                              kewl!

                              woody
                              sigpic
                              Love Thy Neighbor Baby!

                              Comment

                              Working...
                              X