menu

Contact Us Dizzy Patients Health Care Providers Dizzy Culture Research Site DVD BPPV DVD Tai Chi DVD Understanding Dizziness Acknowledgements Disclaimer Quoting


Digital Video Recorders and Eye Movements

Timothy C. Hain, MD Page last modified: March 27, 2010

Computers and multimedia have made a huge impact in the world at large, and also in the oculomotor laboratory. It is now possible to use readily available equipment to record video eye movements and public domain "free" programs to create movies out of your recordings.

Herein I have outlined how to do this using free programs. Unfortunately, there seems to be no commercial program that can do this.

Micromedical Technology monocular eye movement recording apparatus (Visual Eyes) Location of seondary camera -- a Panasonic security type camera.

Hardware

You should expect to spend about $5000 on your entire setup. This is cheap for medical equipment.

Video Input: I use a Micromedical Technology "Real-Eyes" system. This is a single camera set in a Scuba goggle. The other eye can be allowed to view or not, as the examiner desires. See this page for more comments. The video output signal goes to a AD PIP (picture-in-picture) processor (see below). This box combines another camera that views the room, so that there is an inset on the eye of the examiner and examinee. This makes the entire editing process much easier. Generally about all you can tell from the PIP is the gender of the patient, their hair color, and what is being done. This is a good situation.

 

The output of the PIP processor goes into a distribution amplifier (unnecessary, but handy), and then a Panasonic DVR recorder (see above). Then the output of the DVR goes to a very large TV monitor. The audio signal from the goggles also goes to the DVD recorder.

The Panasonic DVR is a very handy device that writes a new title to the DVD for each patient. I have also tried a Sony brand DVR, but I prefer the Panasonic. The Sony is much touchier with what type of video it will accept, and strangely enough, writes files that cannot be copied (easily). I guess Sony, in their zeal to prevent pirating, decided that their customers should not even be able to copy their own content ! Recall, Sony is the company that put a rootkit on their customer's music CD's !

Panasonic's DVR works fine and you don't have to fight with the Sony content management system to read your own material. I bought the DVR that has a 100gig hard disk, for about $400 at Best Buy. However, I never use the hard disk, and a cheaper model would likely do as well. These things seem a little touchy - - we keep a spare one around in case one fails.

Anyway, typically each patient consumes about 5 minutes of the DVD. Usually one can get by with one DVD/week, but on very busy weeks, or days where one forgets to stop recording after a patient, sometimes it takes two. This costs you about $1.00 in media costs. I use Ritek 8X DVD+ disks.

At the start of each patient, I scan the camera over the patient's demographic information. This is to allow me to match up patients with video's later.

A days worth of patients might thus include about 8 to 12 titles (patients). At the end of each week, I "finalize" the DVD, write the date on it with a sharpie, and stick it in a drawer. Finalization takes about 2 minutes.

Extraction of video content

At this point, you will have a DVD that you can play, but it will contain a lot of junk -- most recordings won't have anything worth preserving for posterity.

Index your DVD

Take the DVD, combine it with your schedule, match up the title numbers to the patient names. You can use any DVD player to do this -- a hardware one or a software one. I have used Nero Showtime. Others work as well so there is no need to buy this program. Close your DVD viewer.

Extract the title you want

Next, you need to extract the title(s) that you want. This is much harder than it should be, and I believe that the reason for this is that the movie industry is attempting to discourage piracy. Applications like this are innocent bystanders.

Anyway, the only way to do this that I have been able to get to work is to use DVD-Decrypter, which is an awesome free piece of software which can be found on the net. Most people use it to copy CSS encoded DVD's -- but we don't need to do this because our Panasonic DVD's are not CSS encoded. I am not sure what Sony is doing -- but you should stay away from them anyway given their aggressive approach. DVD decrypter will decrypt Sony DVR written DVD's anyway if you are stuck with it or something like it.

Run DVD-Decrypter in IFO mode (which is the default). Choose the title (PGC on the menu of things on the right) that you want to extract, and let DVD-Decryptor do it's thing. This will take several minutes for about 5 minutes of video, perhaps faster if your computer is better than mine.

This will get you a really big directory, which will have at least one "VOB" file in it. This file contains your video "title", basically a chapter from the DVD that you started with, which contains one patient.

If you can figure out which chapter you want, you can also run DVD-decrypter so that it only decrypts that particular chapter. This can save a lot of time and disk space.

Convert the VOB file into a usable format

What you want out of this whole process is an avi or mov file, edited so that it is small enough to be played in your powerpoint presentation or web or whatever. A VOB file is not what you want. So you need an application that will read and convert VOB files.

Again, commercial programs seem not to do this very well if at all. Adobe Premiere Elements will read a VOB, but doesn't do much of anything useful to it (other than clip). Nero Vision-express 3.0 will read VOB files but can't edit them either. Ulead Movie-Studio 4 doesn't work either.

At this writing, this method works pretty well:

You will need some additional freeware video editing programs:

  1. virtualdub-mod
  2. avisynth 2.5
  3. virtualdub

Yes, this is a bit strange -- using two different versions of "virtualdub". At least they are both free. Anyway, virtualdbub-mod reads the MPEG format VOB files produced by dvd decripter, and can save it as an avi file.

Compressed vs. uncompressed:

These are big files. The default is for virtualdubmod to save it "uncompressed". This is not usable for presentations because the file is too big. However, it is a good idea if you are planning to do more editing. If you save the output from virtualdudbod as an uncompressed avi file, it is best to select out the piece you want, and just save that rather than a long stretch (like 5 min). Practically, about the most you can easily deal with is 1 minute.

Allternatively, you can select out the piece you want, compress it, and you are done. We suggest using a very old codec, such as the "Cinepak codec by Radius", rather than something newer, as while files may be a little bigger, they will run on nearly any computer. You are taking your chances if you use a newer codec. It may work on your PC, but not run off of anything else. This is the big problem with all of these "codecs". Any type of compression is going to take a lot longer (but use much less space) than uncompressed.

Making it prettier

Assuming that you want to make it prettier, once you get the video out of the MPEG format into an avi format, you can manipulate it -- clip it, title it, with the combination of avisynth and virtualdub. If all you want to do is to just show it as a clip, you don't need to do anything other than recompress it.

The way this works is that you create a small "avs" file, and open this up with virtualdub. Virtualdubmod doesn't seem to do this as well.

An example of an avs file is :


ShowSMPTE(x=600, text_color=$ffffff, size=32) # elapsed time stamp
-- we think this is generally a very good idea. Can use smaller size.
SelectEvery(2,1) # decimate to 15 fps # reduce frame rate -- don't do this for saccadic nystagmus
Subtitle("Posterior canal BPPV", text_color=$FFFFFF, size=32) # use your own title
Subtitle("Copyright Timothy C. Hain, M.D. 2006",text_color=$FFFFFF, size=28, align=1) # use your own nameReduceBy2 # pretty small -- don't do this if you need high resolution. Makes a big difference in size.

Virtualdub allows you to cut what you want and save it as an avi file. Virtualdub is pretty crude with the subtitles, but it is very fast. Usually crude and fast is fine for a 10-60 second video.

At this point, you have an avi file that you can edit using standard commercial tools (like Adobe Premiere). I recommend this over using more freeware, because of the time it takes to master these arcane things.

References:

  1. http://www.avisynth.org/
  2. http://www.virtualdub.org/index

Dvddecrypter was bought by Macrovision Europe who announced that it's distribution is illegal. (boo). Copies can be easily located on the internet though, and as this use is entirely legal, it is difficult to see how anyone would object.

 

© Copyright April 14, 2010 , Timothy C. Hain, M.D. All rights reserved. Last saved on April 14, 2010