Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

Aaron's YouTube Television v2.2.2.7


  • Please log in to reply
136 replies to this topic
aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
Aaron's YouTube Television
v2.2.2.7 (Feb. 8th 2012)
- Assign videos permanently to 9999 available channels.
- Option to download any of your channels' videos to your computer.
- Never lose your saved channels, even with program updates!

Posted Image

System Requirements:
- Windows XP, Vista, 7+ (32 or 64-bit)
- Adobe Flash Player (latest version 11 required for 64-bit users)
- AHK_L v1.1.03.00+ (does not work on AHKv2 apparently)
- The ability to copy and paste YouTube URLs
- an MP4 codec to play downloaded videos on your computer
(I would suggest the K-Lite Codec Pack, the basic version)

Download latest version:
Aaron's YouTube Television.ahk (requires AHK_L v1.1.03.00+)
Aaron's YouTube Television.exe (recommended, works for all)

Information:
The power switch is on the top right of the window.
- Press 'On', animated snow is shown, channel buttons are now enabled.
- Change channels with the '<' or '>' buttons, or use 'PageUp' and 'PageDown'.
- Jump to any channel directly with the '!' button - type in requested channel
- Click '<<' and '>>' buttons to take you to the nearest empty channel
- Click 'Always on top' checkbox to toggle the TV as the topmost window
- Click 'Add' to assign video to current channel.
- Click 'Remove' to erase video from current channel.
- Click 'Download' to download current channel's video.
- Click 'Channel List' to see a HTML page with your currently assigned channels (the entries link to the YouTube host webpage for the video).
- Click the 'Always on top' Checkbox to toggle TV as the topmost window
- Press 'Off' and the TV screen goes black, channel-changer buttons are disabled.


The stored URLs and channel list files are created in:
YourDocuments\Aaron's YouTube Television

There are 9999 available channels the User can program.
Please use the "Add" and "Remove" buttons freely!

If there are any bugs, please report them to me...
Remember, not all YouTube videos can be assigned to channels or downloaded!

Version History:
[color=black]v1.0.0.0 - built gui and made some channels work
v1.1.0.0 - added channel up and down buttons, channels stored in .INI
v1.2.0.0 - added feature which programs television with YouTube videos of User's choice
v1.3.0.0 - optimized the YouTube player for the window with the best arrangement of embed tags
v1.4.0.0 - added "Remove" button for erasing channels, arranged and commented code for readability
v1.4.2.0 - Used nimda's idea to shorten and optimize button sections
v1.5.0.0 - made 9999 channels available instead of 999 (turns out to be very slow, must be changed back)
v2.0.0.0 - rebuilt tv to version 2, only 999 channels but this makes managing channels easier for now
v2.0.1.0 - repaired some faulty HTML code, removed extra 'object' tag (may cause problems displaying html)
v2.0.1.1 - renamed channel backup folder in Documents to "Aaron's YouTube Television"
v2.0.1.2 - blank screen image is now retrieved from URL instead of %A_Temp% folder, and displays properly
v2.0.1.3 - User can use either the URL from the browser's main address bar or from the 'Share' button
v2.0.2.0 - applied 'Loop' commands properly instead of incorrect 'GoSub' commands
v2.0.3.0 - when current channel is added or removed, it instantly refreshes to show the changes (usually)
v2.0.4.0 - replaced incorrect html code (which uses WMP) with proper flash 'object' and 'embed' code
v2.1.0.0 - "Fast INI Library" functions implemented by rseding91, speeds up creation of Channel List file
v2.1.1.0 - same functions extended into add/remove channels, to keep Channel List file always current
v2.1.2.0 - back to 9999 channels, made 'playlist URL maker' but it crashed flash player, working on it
v2.1.3.0 - added a UrlList.ini convertor, Users can use their existing channel list with its new layout
v2.1.4.0 - when channel list entries are clicked, User is now taken to video's host Youtube webpage
v2.1.5.0 - rseding91's function to delete any remaining empty keys in UrlList.ini is now active
v2.2.0.0 - User can now download videos at any time while on an active channel, thanks to Garry
v2.2.0.1 - implemented rseding91's function to numerically sort all the keys in the INI file
v2.2.0.2 - various optimizations, increased number of channels to 99999, added text fade function by ih57452
v2.2.0.3 - all fade text now fades at the same time. Buttons are now disabled if they have no current use.
v2.2.0.4 - added 'Please do not exit TV until completed!' underneath 'Downloading [video name]' for clarity
v2.2.0.5 - updated Garry's YouTube download code (YouTube changes their codes every once in a while)
v2.2.0.6 - removed COM.ahk function from inside script, as it was causing issues with x64 ahk users
v2.2.0.7 - added "Play All" button but have not yet figured out how to make it work
v2.2.0.8 - fixed glitch in "Jump To Channel" feature which was allowing letters to be accepted
v2.2.0.9 - channel title becomes default text in Download button's InputBox, I also validated all the HTML
v2.2.1.0 - video title is now retrieved from parent webpage, becomes default text in 'Add' button's InputBox
v2.2.1.1 - added buttons to skip down or up to the first available empty channel, add new videos easily
v2.2.1.2 - all input boxes now open up directly over the TV, even if it is not on the primary monitor
v2.2.1.3 - added more instructions to the 'About' message box and extended the height of the volume slider
v2.2.1.4 - added display text to the bottom of the volume slider, shows current volume level
v2.2.1.5 - volume level is now saved to the INI file when User exits, and restored next time TV is opened
v2.2.1.6 - added 'Always on top' checkbox which lets User toggle the window between always on top or not
v2.2.1.7 - "Always on top" setting is now saved to INI, all dependency on COM removed by nimda
v2.2.1.8 - fixed a problem that was causing TV to crash when x64 users closed the TV
v2.2.1.9 - added splash screens so User knows when channels are loading and unloading during opening and exit
v2.2.2.0 - added 'Searching, please wait' text while User is searching for the nearest empty channel
v2.2.2.1 - added loading/closing/button sounds to the TV, reverted back to 9999 channels for compatibility
v2.2.2.2 - changed the text shown while downloading, it is white and displays under the Channel Title
v2.2.2.3 - replaced the TV sounds with wav files (instead of Mp3) for more compatibility
  Oct 2011
v2.2.2.4 - exit button (x) is greyed out while video is downloading, ensures better chance of completion
v2.2.2.5 - fixed a small bug which keeps the 'X' button disabled after a video is downloaded
v2.2.2.6 - updated AHK_L to v1.1.05.01 and Compile AHK to v0.9.1 then I compiled the TV using them
  Feb 2012
v2.2.2.7 - updated Garry's YouTube download code (YouTube changes their codes every once in a while)
[/color]

Future plans:
[color=black]- Make the 'Channel Up' and 'Channel Down' buttons go to the next occupied channel, skipping any empty channels on the way
- Integrate function to detect when video is finished playing, to enable the "Play All" option
- Provide "Always open TV on last channel viewed" option
- Reference downloaded videos from channel list, which may require a non-editable save location, probably in the Documents\Aaron's YouTube Television folder
- Aaron's YouTube Radio should be built[/color]


SoggyDog
  • Members
  • 803 posts
  • Last active: Mar 04 2013 06:27 AM
  • Joined: 02 May 2006
Nice;
This is headed in the right direction!
:D

nimda
  • Members
  • 4368 posts
  • Last active: Aug 09 2015 02:36 AM
  • Joined: 26 Dec 2010
You make great Gui's. :)
Two things:
1.) Make it possible to add another channel without editing the script in multiple places.
2.) Your "Button1:", "Button2:" etc labels are very redundant. Stack them and use A_ThisLabel to determine what to do (SubStr(A_ThisLabel, 7))

Frankie
  • Members
  • 2930 posts
  • Last active: Feb 05 2015 02:49 PM
  • Joined: 02 Nov 2008
That's the best loading screen I've ever seen... I only wish it loaded something. It showed the snow, and then said loading when I pressed a button. The periods were animated but it never passed it. I gave it 30+ seconds.

Tested on Win 7 (SP1), WMM installed and a great internet connection.
aboutscriptappsscripts
Request Video Tutorials Here or View Current Tutorials on YouTube
Any code ⇈ above ⇈ requires AutoHotkey_L to run

aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
odd.. I have no thoughts on why that would be. The part that shows stuff from the net is shown on a created Internet Explorer control which shows on the GUI, maybe that has something to do with it in your case? I use Firefox for internet browsing but I still have IE on my system.

Frankie
  • Members
  • 2930 posts
  • Last active: Feb 05 2015 02:49 PM
  • Joined: 02 Nov 2008
I just installed IE9 this boot. It should be compatible, so I might need a reboot for it to work.

If I figure it out, I'll let you know.

Update: No luck.
aboutscriptappsscripts
Request Video Tutorials Here or View Current Tutorials on YouTube
Any code ⇈ above ⇈ requires AutoHotkey_L to run

aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
ok go in the code and remove this (it will remove that loading gif entirely) :
<span class="fixed">
    <img src="http://i1207.photobucket.com/albums/bb474/aaronbewza/loading.gif" width="455" height="323">
  </span>
it's in the "CodeVariableChange" subroutine.

I hope that helps :)

This thing uses Windows Media Player (the embedded version)... but it's supposed to work in most of the newest versions from the last however many years. I couldn't be sure what else to suggest, perhaps your Windows Media Player is not listed in your firewall options.

Frankie
  • Members
  • 2930 posts
  • Last active: Feb 05 2015 02:49 PM
  • Joined: 02 Nov 2008
I don't have all the includes, so I can't run the code. I used the .exe earlier.
aboutscriptappsscripts
Request Video Tutorials Here or View Current Tutorials on YouTube
Any code ⇈ above ⇈ requires AutoHotkey_L to run

aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
no includes required, my friend. one of the functions is by Rseding91, it lets images get stored in the .ahk itself.

aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
Updated to version 1.1.0.0 (links updated in first post, you DO need an included file now... URLlist.ini in your script directory)

Changes:
- lots of little code changes and optimizations
- volume slider control now works but only for YouTube videos (any help here would be awesome)
- added "Channel Up" and "Channel Down" buttons for flicking between videos (2 to 100)
- mapped "Arrow Left" and "Arrow Right" to "Channel Down" and "Channel Up" buttons
- filled first 24 channels with a variety of YouTube and embedded videos
- added "URLlist.ini" into script directory containing list of URLs you can customize yourself
("ahk-only" users, don't forget to download the included URLlist.ini in your script directory)

There are instructions in "URLlist.ini" how to add your own URLs...
please read carefully! It's not the easiest thing ever but it does work.

If anyone has suggestions, I'm all ears!

2.) Your "Button1:", "Button2:" etc labels are very redundant. Stack them and use A_ThisLabel to determine what to do (SubStr(A_ThisLabel, 7))

I'm working on this now, nimda, thanks for the props! :)

sumon
  • Moderators
  • 1317 posts
  • Last active: Dec 05 2016 10:14 PM
  • Joined: 18 May 2010
Aron Bewza. I think you're onto something! This is totally great!

I am left without words. Not only is this a very cozy way of watching videos, I think an application that allows online videowatching like this, could become very popular. I'm getting an overflow of ideas here... sharing videos, playing youtube videos embedded here instead, "newcast", etc.

aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
Thank you sumon... anything you can add, if you're interested, please feel free!
Remember to claim full credit for any additions or improvements you make so people don't
ask me for information on something that someone else has altered... I might not have the correct answer lol!

I think I like the idea of "security software" where the User
can patch in webcams from their house and make archives of images or have images
sent to his/her phone when motion is detected in the webcam's range...

Another idea is for the User to put all their uploaded family YouTube videos
(or whatever collection the User has) into this TV and then they can share it
with their family and friends.

EDIT: I will make a StringReplace for the "Share" URLs that YouTube offers under each video
(<!-- m -->http://youtu.be/<!-- m -->Video Number code here)! Then the correct video number
can be applied to a line in the .INI and I can then add a "Add Custom Channel" Input Box or something.

aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
UPDATED to version 1.2.0.0 (links updated in top post)

Changes:
- added feature which allows you to program television with your own choices of YouTube videos, very easily, 999 assignable channels available, can use custom display names
... hence the name change to "YouTube Television".
- fixed "<<" and ">>" (channel down and up) button functions, now when you flick to a channel lower than 2, you are taken to 999 (and vice versa).
- added "!" button, you can enter your own channel number to jump to directly.
- added "?" (about) button which shows version number, build date, and instructions.
- "left arrow" and "right arrow" keys still change channels, but I forgot to put that in the instructions.

I think I'll make 13 images of a rotary knob in 13 stages of rotation, and assign them to show up
where the rotary channel-changer is located on the GUI, just for some visual kicks whn the User changes the channel.

NOTE! "ahk-only" users must use the new .INI file and it must go into a folder called
"YouTube Television" in your Documents folder. You may have to delete all your temp internet files
to be able to download the new one, I kept ending up with the old one until I cleared all my temp internet files.

NEW IDEA: I've noticed the vast amount of music collections on YouTube.
How about a User-programmable "YouTube Jukebox"? I could style it like a Wurlitzer.
Posted Image

TheGreatSwami Woo
  • Members
  • 237 posts
  • Last active: Jan 22 2012 03:31 PM
  • Joined: 26 May 2011
I love the jukebox idea, lots of nice music videos on youtube. Would it just be for the sound?

aaronbewza
  • Members
  • 466 posts
  • Last active: Feb 05 2013 08:40 AM
  • Joined: 20 Feb 2011
No it would also show the CD cover...
For example, the following YouTube URL has a square CD cover on the screen:


I would put a screen somewhere in the middle of the jukebox, and that would
display the CD cover art, if there is any.
This screen, of course, will also play music videos and the User will be able to make it fullscreen.
I'll also need to find a few animated GIFs
of the cool bubbles that were on the front of these things. And I'll add a text area somewhere
on the jukebox which will display information.
Perhaps I'll gear it so it will accept playlists and not only single songs. yah?