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

Digital Video Recorders and Eye Movements

How I do it.

Timothy C. Hain, MD Page last modified: March 30, 2015

Computers and multimedia have made a huge impact in the world at large, and also in the oculomotor laboratory. It is 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 the how to do this.

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


You should expect to spend about $4000 on your entire setup, almost all of it on the Micromedical goggle.  You should expect to spend several hours ordering these parts, and another hour to hook them all up.


Cost (roughly)

Real-eyes goggle (Micromedical Tech) 2500
PIP processor (see below) -- these are needed but fortunately cheap. 150
Room CCTV camera, and mounting mechanism. Panasonic wv-bp144 and mount. Doesn't matter much -- best to get one that adapts to light automatically. Don't forget to get cable (BNC), lens, and 12 volt power supply too. 200
Large monitor with Composite input (30" LCD) $400 (big is good).
Toshiba DVR of Panasonic recorder (various phono or BNC adaptors). Alternatively, a surveillance DVR (presently have a Honeywell DVR) $350, 100$
CE-labs audio and video amplifier, model 400 $40. (optional)

Video Input: I use a Micromedical Technology "Real-Eyes" system. This is a single camera set in a Scuba goggle. It is monocular, with a normal, "NTC" video output.

The other eye can be allowed to view or not, as the examiner desires. See this page for more comments.

We currently use the AMBERY 4 channel PIP processor (costs about $150) . The PIP box combines video from 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 current video camera that we use is a LX-620SHW High Resolution Sony CCD CCTV Security Camera - 1/3 540 Lines.

The camera must be mounted and angled properly -- many camera stores sell appropriate devices for between $20 and $30.  We like the system of putting the camera on an IV pole, using a universal mount that allows it to be positioned. The universal mounts are camera store gizmos.


Electrically,  the way this works is that the two cameras go to the PIP. The PIP goes to the DVR, and the DVR goes to the monitor. 

If you have the extra parts and cables, you can also set it up so that you also send the eye camera to the monitor 2nd input, so when you record you just see the eye, but when you play back, you see eye and what you were doing in the inset. However, we think it is generally a good idea to see the PIP, as sometimes it gets repositioned and then you have no idea that you are recording empty space.

The output of the PIP processor goes into a distribution amplifier (unnecessary in reality), and then an appropriate 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 DVR is a very handy device that writes a new title to the DVD for each patient. I currently have a Panasonic EZ-17, a Panasonic ES28, and a Panasonic EZ48. In the past I have used Sony and Toshiba DVR's. In the US market, these are now all unobtainable, and the ones I used to own all stopped working (sometimes software, sometimes mechanical). These things are old technology and are not used very heavily, so it is hard to see why they should break at all.

Watch out:

Sony: It is hard to find DVR's that convert between a composite input and a DVR are so hard to purchase in the US. Perhaps there is some anxiety about these devices being used to copy copyrighted material. In other words, companies that own content (e.g. like Sony) may also be attempting to prevent people from acquiring tools to copy it. In our opinion, someone must be doing something unethical (i.e. restraint of trade). Of course, Sony is the company that hacked it's own customers by putting a rootkit on 22 million CDs. When we used Sony DVRs in the past, we also noted that they were far more difficult to use than other vendors. We advise avoiding Sony DVRs (or for that matter, any digital product). Perhaps there is a reason that Sony market share keeps dropping year over year as it is a company that abuses their own customers.

European versions: I have gotten "burned" or maybe "cheated" would be a better word, when I ordered a DVR from a very large online store and ended up with one that was designed for European audiences, and 240 volt power. Watch out and read the fine print. Send the European versions back to wherever you bought them and get a refund.

Mystery nomenclature: Similarly, it is also difficult to comprehend what a "DMR" is, and how it differs from a "DVR". It seems likely that there are cheaper and better devices than the Panasonic DVRs available on the international scene, but we have not tried any of them as yet.

My suggestion for 2014 is to locate a known Panasonic device (such as a EZ17, 18, 28, or 48) and play it safe.

Alternatively -- you can use a surveillance type DVR.

I am presently (early 2015) using a Honeywell surveillance type DVR with 4 analog inputs. This device is EXTREMELY difficult to set up, it's hardware and software is buggy in many ways, and has a nearly useless user manual. For example, the remote control freezes, the mouse works intermittently, and there is only one USB port on this device that supposedly writes to a USB hard drive. That being said, with a huge amount of experimentation, one can get analog cameras (such as in the Micromedical goggles) to "stream" over the local area net, and save to a local drive, with reasonably good quality. This will likely be our future direction.

The CE-labs audio/video amplifier (optional) isolates your DVR-recorder and monitor from each other.  This is not necessary with the Panasonic DVR as everything you put into it can go right to your monitor, but might be useful for other situations. It is nice to be able to switch from full screen input to PIP mode on playback.

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.  The Toshiba is not very touchy about media, and I have never had a "bad" DVD produced from this system. The Panasonic EZ-17on the other hand fails (painfully) with bad media, and produces unusable coasters. Adding insult to injury, the Panasonic EZ-17 produces an error message suggesting that it will "recover" the disk, but this is just not true. At this writing (2015), I am investigating using surveillance DVR's such as the Honeywell system that writes to a NAS device. There is a far larger selection of surveillance devices than the older "DVR's", that in theory anyway, could also be used to duplicate movies.

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, or when I forget to turn the recorder off (still do this after years), I "finalize" the DVD, write the date on it with a sharpie, and stick it in a drawer. Finalization takes about 1 minute.

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.    If you want to give a talk and show that really neat case from last week, this is what you do next.

Extract the title you want --

At present, I use "Amersoft DVD ripper" to "rip" video from my own DVD's that I created myself using my DVR. Amersoft is a commercial "rip" program. It is very fast and also it is fairly stable (it doesn't crash that often -- say every 10th run). Amersoft can produce an AVI or WMV file. Both of these have their advantages.

There is now a branch point -- you can either continue with an "avi" file or a "wmv" file. Unfortunately, Microsoft powerpoint, as of about 2010, has "lost" the ability to process avi files (not invented by Microsoft), and only can process "wmv" files. Thus if you are a teacher, it is a good idea to have a methodology worked out to get into wmv files.

The method for wmv files. This is our current method of making teaching videos !

It is difficult to edit wmv files unless you use commercial software. I have tried several methods -- including various Adobe products, the Nero video editor, and Corel Video producer, and "videopad". The best right now seems to be the "cyberlink" video editing software. Here is a discussion of alternatives.

To proceed, one crops the video (in time) to remove any distractors and possible identifying material. Usually there is only about 20 seconds of any nystagmus video that is useful. Then one puts in a subtitle and copyright notice as you prefer.

The method of preparing teaching videos of nystagmus using avi files.

This method is far more complicated than the wmv method, but is free, and what you lose in time in setup, you get back in not having to learn the interface of your nonlinear editor (e.g. Premeire, Vegas, Cyberlink, whatever), usually optomized to make films of vacations rather than eyes. Although it is a lot of work to get these things going, it does work in the end.

    1. avisynth 2.5
    2. virtualdub

These are used to select the piece of video you want, put a subtitle on it, and compress it using a codec. I have tried using movie editing packages such as Adobe Premeire or Sony Vegas, but they just seem to be far more expensive, take longer to load and longer to write. Almost all of these programs also crash very frequently (i.e. every time I use them). Of course, Sony should be avoided anyway as they have a history of hacking their customers. Virtualdub is stable -- it doesn't crash.

A recent problem is that Microsoft Powerpoint now insists on wmv files, having mysteriously lost the ability to read avi files. This can be dealt with by using "avisynth", with the "DirectShowSource" input source. This gives you access to the same input codecs used by Microsoft. The output is still avi, so you have to do a conversion step.

Compressed vs. uncompressed:

These are big file, generally not usable for presentations because the files are too big. However, it is a good idea if you are planning to do more editing. If you save the output 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. In the past, we suggested 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" -- newer ones may not run on the PC that you plug your USB drive into. Any type of compression is going to take a lot longer (but use much less space) than uncompressed.

Asn of 2014, we use the "Aimersoft" program to read the DVD's and convert them directly into WMV files.

Making it prettier (this is back to using AVI format again) -- you can ignore this if you are using WMV format.

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 :

DirectShowSource("CN.wmv") # Use small names, not large ones.
# Directshow is to to load wmv files. Use avisource if avi.
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. 2014",text_color=$FFFFFF, size=28, align=1) # use your own name
ReduceBy2 # pretty small -- don't do this if you need high resolution. Makes a big difference in size.

Another (worse) way to do this is to use dgmpgdec

First, you run dgindex to convert out of the mpeg format.

This gets you an uncompressed video and audio stream. Then you use virtualdub, with an avs file something like this:

LoadPlugin("C:\Program Files (x86)\dgmpgdec\DGDecode.dll")
MPEG2Source("VIDEO_TS\vts_01_1.d2v") # serves AVI frames from MPEG source
# To get audio, you need to add an audio stream using virtual dub mod

ReduceBy2 # pretty small

ShowSMPTE(x=220, text_color=$ffffff, size=10) # Elapsed timer
SelectEvery(2,1) # decimate to 15 fps

Subtitle("Meniere's -- wrong way nystagmus", text_color=$FFFFFF, size=20)
Subtitle("Copyright Timothy C. Hain, M.D. 2011",text_color=$FFFFFF, size=10, align=1)

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.  The "filters" in Virtualdub will do almost everything but subtitles and showSMPTE - -in other words, you can reduce by 2 and select every other feature within virtualdub, rather than on in the AVS file.

At this point, you have an avi file that is generally pretty small, and suitable for use on the web. To use it in powerpoint you must convert it into a wmv file. The utility that we use for this is a commercial program called "aimersoft".





Copyright August 3, 2016 , Timothy C. Hain, M.D. All rights reserved. Last saved on August 3, 2016