www.webdeveloper.com
Page 1 of 2 12 LastLast
Results 1 to 15 of 25

Thread: A script to help the Deaf

  1. #1
    Join Date
    Sep 2008
    Posts
    36

    A script to help the Deaf

    Hello everyone. I just found this forum while researching for a possible way to make what I've dreamed up a reality.

    The reason I thought of this idea is because I'm deaf and it has to do with deaf and web videos. So I hope this is the right place to ask about this.

    With video so popular on the internet it can be a little frustrating for people like me who can't enjoy it to it's fullest. Yes, some online videos have subtitles but it's still a fairly rare thing. In my searching I'd say the number of online videos that are subtitled are less then 10 percent. I can' understand why this is of course for most people aren't deaf. But there are many hard of hearing people that would benefit from subtitles as well. Not to mention subtitling videos in other languages.

    So, I came up with an idea that might help people like me. It all started when I'd see friends and family watching things like TV shows on their computer. I looked around and quite often you can find the subtitles for those shows. They are usually (.SUB) or (.SRT) files. They can play with video players that have the right codec such as a DIVX player or Windows Media player. Currently the only way to add the subtitles to an online video is to Download the video and play it in a player that supports subtitles. But most sites don't allow videos to be downloaded.

    So here's a solution I came up with. To help explain I made these two images.
    Taken from tv.myyearbook.com



    This above image is what you would see if you watch the TV show on that site.



    This image above is an attempt to illustrate what I have in mind. A seperate subtitles file player with a transparent background. IT can be dragged on the screen and placed over the video and display the subtitles.

    Now I realize that the transparent background might be a challenge but if that's not possible then perhaps a subtitle played that I can place below or above the video will do.

    I'm not a programmer or developer. I do some graphic design work but I don't have the knowledge to make anything like this. Which is why I'm here. I'm not sure if this is the kind of forum for this kind of thing but I searched for developers and program designers in hopes that I might be able to find someone that can help.

    This could also be used for personal videos as well.

    Does anyone have any thoughts or advice on how I might make this idea a reality?

    Thanks for your time.

    Ron Jaxon

  2. #2
    Join Date
    Feb 2008
    Location
    NW Washington State
    Posts
    1,856
    I'd be interested in working with you on this project. Using .flv (Flash video) and embedding que points into the metadata would be one way to connect the video to outside captions. Another method could be to just measure the the time played in milliseconds and triggering events (captions) along the way.
    Humm... sounds like a very interesting project.
    Eye for Video
    www.cidigitalmedia.com

  3. #3
    Join Date
    Sep 2008
    Posts
    36
    Thank you for the replies guys.

    Let me share the thing that I have tried out. Keep in mind that I don't have much programming knowledge.

    I downloaded a SRT file. For example you can find them at http://www.opensubtitles.org/en

    Assuming a video is an hour long. Using windows media player I made a video that's a little over an hour long (Giving me room to adjust the timing on the subtitles if needed. This video had nothing but a black background image. To make the file smaller I converted it to a FLV video.

    Now I placed that video file in the same folder as the subtitles (SRT) file and gave them the same name so the subtitles will play on the video. What I ended up with is a video that only shows the subtitles. I used Total video player because it'll play FLV files and also supports subtitles.

    It's not as good as I hope it'll be but it's a start. I can make this video play any subtitles file and open the window over my browser screen. It's kind of hard to fallow though because your eye have to jump off the video to read the subtitles.

    Just thought I'd share what I've tried so far. I'll look into the links you provided and see if I can understand it all.

    Thanks again.

    Ron Jaxon

  4. #4
    Join Date
    Feb 2008
    Location
    NW Washington State
    Posts
    1,856
    Hey Ron,
    Just a quick question... Are you looking for a video player that will play as part of a Web browser? So for example, a video with subtitles is posted on the Internet and anyone with a standard browser can play the video? or are you looking to just download the video to your local machine and then play the video in a specific video player, set up just for that purpose?
    The reason I ask is that if this service to be very wide spread, you'll have to choose a video player which have Web browser pluggins available. Otherwise each and every user will have to download the specific player, then down the video file for later playback.
    Best wishes,
    EfV

  5. #5
    Join Date
    Sep 2008
    Posts
    36
    What I have in mind is something like this.

    Go to a site such as this one and find a show you want to watch.

    Then go to a site such as this one and find the subtitles file to that TV show.

    Now most sites like this that you can watch TV shows or movies from (Legally) will not allow you to download their videos. So I'm thinking that if some kind of player can be made that will play subtitles files in front of a video with a transparent background. I'd just be able to open the subtitles and drag and drop it over the video that is streaming on an HTML page.

    The above is how I hope it can work but I'm of course open to any other method that might work. Who knows, maybe there's a way to do it with some kind of AJAX or Javascript. But I'm thinking of an actual external player/program would prevent a lot of problem such as the issue with the different browsers that you pointed out.

    I think a big challenge will be the transparent background that plays the subtitles. If that isn't possibly then something like this image might work. Not as good but it could provide the subtitles.



    I can also think of other ways this could be used other then just for deaf or heard of hearing. For example if a video is one language then you could play the subtitles in another.

    How ever it could be accomplished would be great. Thanks for the offers to help out or put some thought into this. If there's anything I could do to help make this a reality let me know what I can do.

    Thanks again.

    Ron Jaxon

  6. #6
    Join Date
    Sep 2008
    Posts
    36
    Oops. I placed the wrong image on my last post. It should be this one.



    Ron Jaxon

  7. #7
    Join Date
    Feb 2008
    Location
    NW Washington State
    Posts
    1,856
    OK, I've got a better picture of the goal. A drag and drop subtitle application that can work with various Web videos.
    My first thoughts are that overlaying a Web browser with another application will present problems with what’s called “focus”. That is, generally speaking, your computer will normally give one program or the other the focus, or first in line for user interaction. An example would be opening two programs, get them on your screen at the same time. To click from one to another, you have to change the focus. You see that by trying to type into the program that doesn’t have focus, etc.
    Since the video is one application, the Web browser, and the caption reader on another, let’s just pretend we merged the two. Having the reader as part of the video application would greatly reduce the problems involved in creating this. So you just convince the video sites to install your new creation on their Web pages……Hey…what do you mean “Yeah right…”. It could happen you know…..????
    So back to rule one of goal setting “Begin with the end in mind”. As this project develops, how about including a component that could be included on the server side.
    The other branch of this project may require programming skills far beyond anything I can do…but I’ll experiment with a couple of ideas.
    Let us know how this develops for you.
    EfV

  8. #8
    Join Date
    Mar 2007
    Location
    localhost
    Posts
    2,036
    I would seriously advise against flash.

    Flash is not native to the web browser, it has to be installed and I for one do not like flash.

    Subtitles would be best served up in a web page along with an embedded media player. If you hide the subtitles in a hidden DIV and also the media player, then show the visitor a "Start video" button, when this is clicked, it kick starts the javascript to start the subtitles and video playback.

    Subtitling would be fairly straight forward in respect to when to display the subtitles and for how long.

    If you look into video subtitle formats for media, you can then see how they use a plain text file that imposes text over the video.
    Yes, I know I'm about as subtle as being hit by a bus..(\\.\ Aug08)
    Yep... I say it like I see it, even if it is like a baseball bat in the nutz... (\\.\ Aug08)
    I want to leave this world the same way I came into it, Screaming, Incontinent & No memory!
    I laughed that hard I burst my colostomy bag... (\\.\ May03)
    Life for some is like a car accident... Mine is like a motorway pile up...

    Problems with Vista? :: Getting Cryptic wid it. :: The 'C' word! :: Whois?

  9. #9
    Join Date
    Feb 2008
    Location
    NW Washington State
    Posts
    1,856
    What do you mean by
    not native to the web browser
    Are you referring to the Windows Media Player as a part of IE? It’s not an integral part of other browsers so the “native” part is a bit confusing.
    Other than Flash, what type of native “embedded media player” would you recommend?
    EfV

  10. #10
    Join Date
    Sep 2008
    Posts
    36
    Well, I've been experimenting and to be honest I almost have a possible method worked out. I stress the "Almost" because there are still some issues that I don't know how to fix.

    Let me tell you what I've done. I went over it a little a couple of posts up but if you have a few minutes you can try this out yourself so you can see what issues I'm now facing.

    Ok, this is the online video I found and I also found matching subtitles. Don't hold the movie against me. It's a musical and I'm deaf so I have no interest in it. LOL

    Anyway, here's the online movie.
    http://tv.myyearbook.com/view/8600889

    Below is a link to the hour long video I made that shows nothing but a black background. It's what the subtitles will play on. It's an FLV file and it's 65.2mb.
    Right click here to download.

    Now here's the Subtitles file (Extension SRT). It's a very tiny text file 95.0k.
    Right click here to download the subtitles.

    Place them both in the same folder. They already have the same name. So if your player supports FLV files and will show subtitles they should play on the video. If they don't then you might have to turn subtitles on on your player.

    In my experience not many players that play FLV show subtitles. I use Total Video player because it does support both (It's free and I never had any problems with it.

    Now I can run this video and it'll show the subtitles. Open it in front of my browser where the video is playing. and watch both. It's pretty tricky because the video also includes commercials and I have to spend some time trying to get the subtitles timed with the movie. Not an easy task when you are deaf (I sometimes need to get help with that part).

    Now there are two major problems I'm having with all this. First of all it would be great if I could remove the skin of the player so it has no border around it. This would allow me to place it right below the streaming video. I see the folder that came with total video player has a "Skins" folder and the images that made the skins. I wonder if I can manipulate them.

    Now I come to the biggest problem. If I can work this out I think I'd pretty much be set. Won't be the best but it would be usable. The problem is that when I shrink down the window of the total video player that's displaying the subtitles. The text on the screen also shrinks. So if I shrink it down to a size that will fit under the streaming video the text becomes too small to read.

    Here are a couple of screen shots.





    Like I said. Maybe there are other ways. I'm just trying to figure a way out with my limited knowledge. I appreciate all your replies.

    Thanks again.

    Ron Jaxon

  11. #11
    Join Date
    Feb 2008
    Location
    NW Washington State
    Posts
    1,856
    Looks like you're making progress Ron. I understand a lot better what you are trying to do. Thanks for the images to illustrate.
    Here is a thought.. can you get the .fla for the player you are using? This is the editable file for the player. Once you have that, it's possible to change what you see as a skin...slim it down..get rid of ALL the stuff that gets in the way of viewing the movie.
    Lacking that…..perhaps we can create a proper video player for this purpose. Problem with the player now is that it’s set to play regular shaped videos. So create a video player specifically for subtitles.. short, squat, no extra stuff along the top of the player (File, View, Play, etc…). If controls are needed, they could be below the subtitles. Determine the exact size so you don’t have to resize when you drag below the video (what size would that be???).
    I’m not sure if any players I’ve created will play subtitles…. I’ll have to look into that and try to learn a little about what that takes.
    Best wishes,
    EfV

  12. #12
    Join Date
    Sep 2008
    Posts
    36
    Thanks so much for looking into it. I have no idea how to make a player but I'll look around and see if I can find a place to learn.

    The player will definitely need to have controls because it'll take a little work to get the subtitles lined up with the movie/show. Many of them will start at a different time then the subtitles are set to. The first line of the subtitles might start at 00:01:25 but the first line of the actual movie might start at a different time. So sometimes I might need to adjust one to match the other. I'd also have to pause the subtitles when they place commercials on the shows.

    If it's a video I'd like to watch more then once. I could adjust the subtitles to match it better using a subtitles time adjuster program. So once it's set to match the video the playback will be much easier to watch the next time.

    When I did some research I found that there are an estimated 28.8 million people comprise the American deaf community. My point is if I can get this to work there are people who might find this useful other then just me.

    Thanks again for your help. I'm going to go see if I can learn how to manipulate my player.

    Ron

  13. #13
    Join Date
    Sep 2008
    Posts
    36
    Is this the file you where referring to EfV? IF so do you have any suggestion of what changes I should make. I have some HTML knowledge and can understand some of it but not all. I see there's a command "stretch" used quite often. I'm wondering if one of them would allow me to prevent the subtitles to not shrink when I shrink the player as it's playing.

    Here's the code of the entire file. This was found in the "Skins" folder of the player.

    Code:
    [General] 
    Author=jefflee
    Version=1.0
    Contact: swordm@gmail.com
    
    [Window]
    
    LeftBegin=18
    LeftEnd=6
    
    TopBegin=15
    TopEnd=3
    
    RightBegin=18
    RightEnd=3
    
    BottomBegin=10
    BottomEnd=10
    
    LeftImage=left.bmp
    LeftStyle=STRETCH
    
    TopImage=top.bmp
    TopStyle=STRETCH
    
    RightImage=right.bmp
    RightStyle=STRETCH
    
    BottomImage=bottom.bmp
    BottomStyle=STRETCH
    
    [Title]
    ShiftHor=0
    Clip=0
    ShiftVer=4
    Style=stretch
    TitleBegin=8
    TitleEnd=8
    Image=backtitle.bmp
    Alignment=TOP
    Font=MS Sans Serif
    ActiveColor=162,158,128
    InactiveColor=122,118,94
    Bold=YES
    Italic=NO
    Underline=NO
    
    [Close]
    ShiftHor=4
    ShiftVer=4
    Image=close.bmp
    Alignment=TOPRIGHT
    
    [Min]
    ShiftHor=34
    ShiftVer=4
    Image=min.bmp
    Alignment=TOPRIGHT
    
    [Max]
    ShiftHor=19
    ShiftVer=4
    Image=max.bmp	
    Alignment=TOPRIGHT
    
    [Restore]
    Image=min.bmp
    ShiftHor=34
    ShiftVer=1
    Alignment=TOPRIGHT
    
    [OnTop]
    Image=ontop.bmp
    ShiftHor=3
    ShiftVer=4
    Alignment=TOPLEFT
    
    [Icon]
    ShiftHor=4
    ShiftVer=4
    Style=noicon
    Alignment=TOPLEFT
    
    [Menu]
    MenuBegin=6
    MenuEnd=6
    ItemShiftHor=0
    ItemShiftVer=0
    ItemLeftThickNess=2
    ItemTopThickNess=2
    ItemRightThickNess=2
    ItemBottomThickNess=2
    Image=menu.bmp
    ItemImage=menubtn.bmp
    Font=MS Sans Serif
    NormalColor=000,000,000
    PushColor=000,000,000
    Bold=NO
    Italic=NO
    Underline=NO
    Style=stretch
    
    [Windows]
    MainWindow = tvp.exe,ID
    PlistWindow = pls.dll,ID
    AboutWindow = tvp.exe,ID
    VCtrlWindow = tvp.exe,ID
    
    [HookFilter]
    NotHook = MainWindow,PlistWindow
    
    [HookSpecial]
    Special = AboutWindow
    
    [MainWindowSCREEN]
    Mask=Mask.bmp
    Main=Normal.bmp
    Down=down.bmp
    Over=over.bmp
    Disabled=disable.bmp
    ReSize=FALSE
    
    [MainWindowMENU]
    BkPicName=Menu.bmp
    FontName=MS Sans Serif
    FontSize=12
    TextColor=0l
    DisabledTextColor=65535l
    
    [MainWindowBUTTONINFO]
    1=BTN_MAIN_PLAY,1001,31,92,31,30,Play,FALSE
    2=BTN_MAIN_PAUSE,1008,62,92,30,30,Pause,FALSE
    3=BTN_MAIN_STOP,1002,92,92,30,30,Stop,FALSE
    4=BTN_MAIN_NEXT,1009,121,92,28,26,Next,FALSE
    5=BTN_MAIN_PREV,1003,3,92,28,26,Previous,FALSE
    6=BTN_MAIN_PLAYLIST,1006,241,68,38,20,PlayList,FALSE
    7=BTN_MAIN_CYCLE,1007,241,24,38,20,Cycle,FALSE
    8=BTN_MAIN_OPEN,1011,241,45,38,20,Open,FALSE
    9=BTN_MAIN_VOLUME,1012,159,99,19,20,Volume,FALSE
    
    [maindelete]
    8=BTN_MAIN_NEXTFRAME,1010,341,143,35,30,Next Frame,FALSE
    9=BTN_MAIN_CAPTURE,1004,183,109,85,9,Capture,FALSE
    
    [MainWindowTRACKBARINFO]
    1=BAR_MAIN_LENGTH,1000,seeknormal.bmp,seekdown.bmp,0,75,244,11,H,0,5,0,5,0
    2=BAR_MAIN_SOUND,1005,volnormal.bmp,voldown.bmp,180,109,92,9,H,50,5,0,5,0
    
    [MainWindowTEXTINFO]
    1=TXT_MAIN_LENGTH,1021,digifacewide,FALSE,TRUE,-18,12775409l,20,13,70,30,
    2=TXT_MAIN_FILEINFO,1022,digifacewide,FALSE,TRUE,-13,12775409l,20,47,212,15,
    3=TXT_MAIN_KBPS,1024,small fonts,FALSE,TRUE,-8,12775409l,90,15,50,8,
    4=TXT_MAIN_KHZ,1025,small fonts,FALSE,TRUE,-8,12775409l,90,30,50,8,
    
    [MainWindowSPECTRUMINFO]
    1=SPT_MAIN_FFT,1032,12775409l,145,13,80,30
    
    [PlistWindowSCREEN]
    Main=PLButtonNormal.bmp
    Down=PLButtonDown.bmp
    Over=PLButtonOver.bmp
    Disabled=PLButtonNormal.bmp
    ReSize=TRUE
    TopStretchArea=183,0,20,21
    BottomStretchArea=183,0,20,21
    
    [PlistWindowMENU]
    BkPicName=Menu.bmp
    FontName=MS Sans Serif
    FontSize=12
    TextColor=0l
    DisabledTextColor=65535l
    
    [PlistWindowBUTTONINFO]
    1=BTN_PL_ADD,1010,2,0,43,21,Add,FALSE
    2=BTN_PL_DEL,1011,45,0,44,21,Delete,FALSE
    3=BTN_PL_SORT,1012,89,0,45,21,Sort,FALSE
    4=BTN_PL_FILTER,1013,133,0,46,21,Filter,FALSE
    
    [PlistWindowLISTCTRLINFO]
    1=PL_LISTCTRL,1009
    
    [PlistWindowLISTCTRLSTYLE]
    HeaderTextColor=0l
    HeaderFontName=small fonts
    HeaderFontSize=10
    BkColor=410467l
    TextColor=9627360l
    FontName=MS Sans Serif
    FontSize=10
    HiTextColor=16763080l
    SelBkColor=2911114l
    SelColor=9627360l
    ColumnHeaderSpan=ColumnHeaderSpan.bmp
    ColumnHeaderEnd=ColumnHeaderEnd.bmp
    ColumnHeaderStart=ColumnHeaderStart.bmp
    HorizontalScrollBarLeftArrow=HorizontalScrollBarLeftArrow.bmp
    HorizontalScrollBarRightArrow=HorizontalScrollBarRightArrow.bmp
    HorizontalScrollBarSpan=HorizontalScrollBarSpan.bmp
    HorizontalScrollBarThumb=HorizontalScrollBarThumb.bmp
    VerticleScrollbarBottom=VerticleScrollbarBottom.bmp
    VerticleScrollBarDownArrow=VerticleScrollBarDownArrow.bmp
    VerticleScrollBarSpan=VerticleScrollBarSpan.bmp
    VerticleScrollBarThumb=VerticleScrollBarThumb.bmp
    VerticleScrollbarTop=VerticleScrollbarTop.bmp
    VerticleScrollBarUpArrow=VerticleScrollBarUpArrow.bmp
    
    [VCtrlWindowSCREEN]
    Mask=Mask.bmp
    Main=vctrl_normal.bmp
    Down=vctrl_down.bmp
    Over=vctrl_over.bmp
    Disabled=vctrl_disable.bmp
    
    [VCtrlWindowRESIZEINFO]
    1=BGI_TOP, 70,0,90,30,STRETCH,H
    2=BGI_BOTTOM,268, 24, 15, 0,STRETCH,H
    3=BTN_VCTRL_CYCLE,-1,3, 8, -1, BLT, H
    4=BTN_VCTRL_PLAYLIST,-1,3, 34, -1, BLT, H
    5=BTN_VCTRL_OPEN,-1,3, 63, -1, BLT, H
    6=BAR_VCTRL_LENGTH,70,7,90,74,STRETCH,H
    7=TXT_VCTRL_FILEINFO,270, 35, 16, 1,STRETCH,H
    
    [VCtrlWindowBUTTONINFO]
    1=BTN_VCTRL_PLAY,1087,31,23,31,30,Play,FALSE
    2=BTN_VCTRL_PAUSE,1088,62,23,30,30,Pause,FALSE
    3=BTN_VCTRL_STOP,1089,92,23,30,30,Stop,FALSE
    4=BTN_VCTRL_NEXT,1098,121,23,28,26,Next,FALSE
    5=BTN_VCTRL_PREV,1086,3,23,28,26,Previous,FALSE
    6=BTN_VCTRL_PLAYLIST,1102,225,3,26,17,PlayList,FALSE
    7=BTN_VCTRL_CYCLE,1101,251,3,25,17,Cycle,FALSE
    8=BTN_VCTRL_OPEN,1100,200,3,21,17,Open,FALSE
    9=BTN_VCTRL_VOLUME,1099,159,34,19,20,Volume,FALSE
    
    [VCtrlWindowTRACKBARINFO]
    1=BAR_VCTRL_LENGTH,1090,seeknormal.bmp,seekdown.bmp,73,7,116,11,H,0,5,0,5,0
    2=BAR_VCTRL_SOUND,1091,volnormal.bmp,voldown.bmp,180,41,92,9,H,50,5,0,5,0
    
    [VCtrlWindowTEXTINFO]
    1=TXT_VCTRL_FILEINFO,1104,digifacewide,FALSE,TRUE,-13,2911114l,268,35,2,15,
    2=TXT_VCTRL_LENGTH,1103,digifacewide,FALSE,TRUE,-13,2911114l,0,3,70,20,
    
    [VCtrlWindowSPECTRUMINFO]
    1=SPT_VCTRL_FFT,1097,12775409l,145,13,80,30
    Thanks again. Just thought I'd show it to see if any obvious changes can be pointed out. Ideally the player has no border. Must still have controls though (Pause, play, etc...)

    Ron Jaxon

  14. #14
    Join Date
    Feb 2008
    Location
    NW Washington State
    Posts
    1,856
    Hello Ron,
    I use many video players that I've built myself. The code needed for a simple player is very short and straightforward. Set the doc size to short and squat... check to see how wide the typical video shows up in your browser. This player should fit in front of and just below it. So let's just say 400 wide by 60 pixels high (for two lines of subtitles plus one line of controls). You don't want to resize it. From the Library panel, far top right corner, click and open the little list box. Choose "New Video". Drag that video onto the stage. Set the video size to 400 X 40, leaving the rest of the space for the controls. Name that instance "video_screen".
    Here is all the ActionScript (AS2) you need for a simple player.
    Code:
    var nc:NetConnection = new NetConnection();
    nc.connect(null);
    
    var ns:NetStream = new NetStream(nc);
    video_screen.attachVideo(ns);
    
    ns.play("videos/TJ_Fast_Preview.flv");
    /*ns.pause(true); */
    It will play videos. Controls can be added fairly easily. Using a playlist will involve using an array and a little more involved AS.
    One thing I've never done is to create a player which will read the subtitle file. That will require some research.
    Here are a couple of sources for good tutorials:
    www.gotoandlearn.com
    www.learnflash.com
    Best wishes,
    EfV

  15. #15
    Join Date
    Sep 2008
    Posts
    36
    Hey check this out!

    Go to abc.com. You can watch full episodes of TV shows and some of them have closed captions. The captions shows up in a separate table below the streaming video a lot like I'm trying to make. But this is embedded in the page (Not drag and drop such as how I want it to be). But I wonder what they are using to make it and time it to the video.

    For those of you who have been looking into this with me (And I'm very thankful for your efforts). You can go there and see what I'm talking about.

    To check it out go to abc.com. Click the "Episodes" link. You might have to install some plug ins to watch their videos.

    If the show has closed captions you'll see a little "CC" down above the time line of the video. To make it easier to find one I know that the "Extreme makeover home edition" episodes are closed captioned. Click on "Settings" to turn closed captioning on. Then watch a few minutes of the show and you'll see how it displays the closed captions.

    The above may seem like a lot of work but it really isn't. Took me about 3 minutes (including installing the plug ins).

    I'd sure like to learn how they are doing it.

    Ron Jaxon

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles