Login processing...

Trial ends in Request Full Access Tell Your Colleague About Jove


An Adjustable High-Definition Imaging System for Behavioral Studies of Drosophila Adults

doi: 10.3791/62533 Published: June 8, 2021
Tong Li*1,2, Yujia Weng*1,2, Daxiang Yang1
* These authors contributed equally


Drosophila melanogaster is a very powerful model in biological research, but a bad model for photography or videography. This paper describes a simple but effective method to observe and document the behavior or morphology of flies. Flies were placed in a translucent observation chamber c.a. Ø15 x 5mm (no food inside) or Ø15 x 12 mm (with an 8 mm-high piece of food inside). After covering with an ultraviolet (UV)/clear filter with high light transmittance, the chamber was placed under a 5-50x zoom stereo microscope, and mini light-emitting diode (LED) video lights were placed on both sides of the microscope to illuminate the chamber to obtain uniform, soft, bright, and nearly shadow-free light. Then, a compact digital camera with 3-5x optical zoom, which can record 1080 P high-definition or higher resolution video (at a frame rate of ≥30 fps), was connected to the eyepiece of microscope through a bracket, and photographs or videos were taken through the eyepiece. By adjusting the zoom knob of the zoom stereo microscope, it was very easy to track the flies and take panoramic or detailed close-up images as needed, while the camera recorded everything under the microscope. Because the flies can stay at any position in the chamber, they can be observed and recorded from all directions. The photographs or videos taken are of good image quality. This method can be used both for scientific research and teaching.


Drosophila melanogaster is an outstanding model in biological research; however, it is a bad model for photography or videography, as it is too small for a camera or a camcorder and too large for a compound microscope1. Despite excellent research described in the literature, most studies have only provided blurred, unclear images, rather than clear and sharp photographs with clear detail that illustrate the fly behavior being described. Moreover, although fly behaviors have been extensively studied (e.g., courtship and fighting), most of these papers have used illustrations to explain their research to readers.

This paper describes a simple and economical approach. Using this method, not only the various behaviors of Drosophila can be observed, but also all the details that can be observed under a stereo zoom microscope can be recorded clearly and sharply. Of course, this method can also be used to record the morphology of flies, as when they enter a sleep or semi-sleep state, the stationary model allows the user to take a photograph or a stack of photographs with different focal planes to get an extended depth of field photo. These methods can be realized without complicated technology and expensive equipment or even superb manual skills.

The video component of this article shows videos of several typical behaviors of flies. The purpose of showing these videos is twofold: one is to let audiences know what can be captured and present the image quality obtained by using this method; the other is to let new students who are interested in Drosophila, but thus far have not had the opportunity to actually observe the behavior of flies understand the behavior of flies (such as courtship, fighting) through these clear videos rather than illustrations or blurred images.

Subscription Required. Please recommend JoVE to your librarian.


1. Construction of the observing/documenting system

NOTE: The materials needed to construct the fly behavior observing/documenting system are shown in Figure 1, and the completed system is shown in Figure 2. The protocol to construct the system and how to use it are described below.

  1. Make a fly behavior observation chamber (FBOC).
    1. Obtain a small, translucent (not transparent) container to make an FBOC of size diameter (Ø) 15 mm x 20 mm. Use a translucent plastic bottle cap of size ~Ø17 mm x 22 mm to make an FBOC, or cut a section of ~17 mm from the thick end of a 5 mL pipette tip to make an FBOC.
    2. Pour 1% agar into the FBOC to adjust its depth. If food needs to be placed in the FBOC (see for the preparation method of the food), pour the agar to obtain a depth of 12 mm. If food does not need to be placed in the FBOC, pour the agar to a depth of 5 mm to track the whereabouts of fruit flies more easily.
    3. If using a pipette tip to make an FBOC, place the cut-off pipette tip section in a Ø35 mm or a Ø60 mm Petri dish. Pour the 1% agar gel into the Petri dish to a thickness of ~5 mm, wait for the agar to solidify, and seal the bottom of the FBOC. Then, pour the agar gel into the FBOC to the desired thickness.
  2. Make an FBOC base by boring a ~10 mm-deep hole in the center of a piece of a 60 mm x 60 mm x 15 mm ethylamine foam sheet with the same diameter as the FBOC. Insert the FBOC into the hole.
    NOTE: The FBOC base keeps the FBOC stable and prevents it from tipping over and facilitates the movement of the FBOC to track the flies during observation and videography.
  3. Make fly food, if necessary, with yeast medium2, artificial diet3, or pure sucrose/glucose (use 1% agar as gelling agent), depending on the purpose of observation.
    1. To visually determine whether flies are feeding and increase the contrast between flies and their environment, add food dyes (see the Table of Materials) to the food to a final concentration of 12.5 mg/100mL.
      NOTE: The abdomens of the flies change color immediately after feeding.
    2. Pour the prepared food into a Petri dish to a height of 8 mm. After solidification, use a razor blade to cut out a piece of food of size 8 mm x 4 mm x 8 mm, and place it on a piece of plastic (such as candy wrapper).
    3. Cut the food into a quadrangular pyramid or quadrangular frustum pyramid, as shown in Figure 3, to allow observation and recording of fly behavior from different angles as the flies land on the food randomly. Use the plastic under the food is to prevent the dye in the food from diffusing into the agar in the FBOC. Use tweezers to place the food in the center of the FBOC.
  4. In some behavioral observations, ensure that the flies are starved in advance. Pour 1% agar gel (1 g agar/100 mL water, 600 µL of propionic acid) into a clean empty bottle to a thickness of 1-2 cm, and place at room temperature for 1-2 h. Transfer flies to the bottle and place at 25 °C for ≥36 h.
    NOTE: Flies can absorb water from the agar gel, so there is no need to add water from time to time4,5.
  5. Transfer one or more flies into the FBOC using an aspirator. If using an aspirator is difficult, chill and inactivate the flies in crushed ice, sort them on an ice pack, and transfer them to the FBOC as described previously6.
    NOTE: The use of freezing greatly facilitates the transfer of flies; the chilled flies can regain consciousness within 1 min, much faster than those anesthetized with CO2. Although chilling could have detrimental effects on the behavior of flies, e.g., increased copulation latency of flies from 5 min7 to 40 min8, it does not change fly behavior (such as courtship behavior). Hence, the chilling method may be used to transfer flies for general observation (such as teaching experiments) and videography. However, if the observations are to be used in a scientific report, it is strongly recommended to not expose the flies to any anesthesia.
  6. After transferring the flies to the FBOC, cover it with a 30-40 mm UV/clear filter for the camera to form an FBOC complex (Figure 4). Place the FBOC complex under the stereomicroscope for observation.
    NOTE: To obtain clear and sharp images, it is strongly recommended to use high-quality UV/clear filter with high light transmittance (>98%) and reduced flare. Refer to some suggestions described previously9,10; although there is no need to buy expensive filters, avoid covering the FBOC with glass such as the lid of a Petri dish.
  7. Illuminate the FBOC. Mount mini LED video lights to flash hot shoe mount stands and place them on the left and right sides of the FBOC (Figure 2). Turn on the LED lights, and set the brightness to 100% and the color temperature to 5000-5600 K.
    NOTE: The mini LED video lights with dimmable light, 5600 K color temperature can provide uniform, bright, nearly shadow-free illumination. Using the top light source that comes with the stereo microscope, the LED Ring Light illuminator, or fiber optic illuminator did not yield satisfactory results. It is best to use continuous power supply (transformers) for LED video lights.
  8. Observation and videography of fly behavior
    1. Turn on the LED video lights, and adjust the stereo zoom microscope until the edge of the FBOC can be clearly seen with the naked eye. Move the FBOC to the center of the field of view.
    2. Attach the clamp of the universal telescope digital camera adapter to an eyepiece of the stereo microscope, and then attach a compact digital camera to the adapter securely by alternately turning the camera mounting screw and camera fixing screw (Figure 2).
    3. Turn on the digital camera, and turn the horizontal/vertical fine-tuning knobs until the FBOC edge clearly appears in the center of the bright circular field of view on the camera's LCD screen. Rotate the mode dial to Aperture-priority auto Mode, press focus on the multi selector, choose Macro close-up, and then press the OK button. Move the zoom switch from the wide-angle end to the telephoto end, and zoom into the circular image until its central portion fills the full LCD screen. Press the Movie-record button to start recording (press the button again to end recording).
      NOTE: If the image is too dark or too bright, press the side of the control dial close to the exposure compensation icon (Figure 1), and rotate the dial to alter the exposure value (EV) suggested by the camera to achieve the desired effect. Positive EVs make the image brighter, and negative EVs make the image darker. The image must be uniform, bright, without vignetting.
    4. Turn the focus knob of the microscope until the flies in the FBOC are clearly visible. Choose the fly behavior of interest for observation or video recording. Turn the zoom knob to zoom in and out to achieve the desired magnification for observation or video recording.
      ​NOTE: This method of taking images under the microscope through the eyepieces is applicable to any microscope with eyepieces. To take photographs of experimental results, use a camera that can shoot in RAW format, as RAW image files are preferable to JPEGs. Use the camera's LCD screen as a display to observe the behavior of fruit flies, and ensure that the stereo zoom microscope has at least 5-50x zoom.

2. Protocols for observation and videography of fly behavior

  1. Preparing the flies
    1. Culture the flies on cornmeal medium at 25 °C with 60% humidity and a 12 h light/dark cycle. Collect flies within 6 days of hatching for observation (except courtship and fighting behavior).
      NOTE: Here, the medium was composed of 1000 mL of water, 105 g of cornmeal flour, 75 g of sucrose, 15 g of agar, 40 g of yeast powder, 28 mL of 10% methyl paraben (w/v in 95% ethanol), and 6.25 mL of propionic acid.
  2. Regaining consciousness from anesthesia by chilling
    1. Chill the flies as described previously.6 Transfer the Drosophila from the ice box to the FBOC using tweezers. Record the fly's process from inactivity to normal posture on video.
  3. Fly sleep, feeding, excretion, and social behavior
    1. Starve flies for 36 h. Transfer 4-6 fruit flies to the FBOC with stained food. Observe and record fly behavior on video.
      NOTE: Flies that remain motionless for more than 5 min display sleep behavior11. Drosophila can sleep on food or on a vertical FBOC wall (the body is perpendicular to the observation chamber wall). Although the body does not move when sleeping, the abdomen can be seen to be undulating. Feeding behavior is manifested when the fly stretches out its proboscis, moves on the food while constantly sucking, and its abdomen turns blue. During group feeding or other activities, fruit flies stretch their feet to touch the bodies of other fruit flies in a friendly manner. This is a social behavior.
  4. Fly grooming behavior
    1. Chill the flies as described6. Throw the frozen flies into agar powder, and roll to cover them with agar powder. Transfer the flies to the FBOC. Observe and record grooming behavior.
      NOTE: When the fruit fly regains consciousness from the freezing, it will quickly shake off the agar powder from its body and clean every part of its body with its legs12,13. Grooming behavior can also be seen during feeding, courtship, and other behaviors.
  5. Fly courtship and fighting behavior
    1. Collect female and male flies as described previously7. To observe the courtship behavior of flies, place a female fly and a male fly into the FBOC to observe and record 6 courtship (successful and failed) behaviors.
    2. To observe the fighting behavior of flies, place two males in the FBOC. Observe and record their behavior of pushing and shoving each other.
  6. Fly egg-laying behavior
    1. Prepare female flies as described previously5. Transfer 4 female flies into FBOC with food.

Subscription Required. Please recommend JoVE to your librarian.

Representative Results

Shoot through a UV filter for clear and sharp images
Perform a simple experiment to observe the difference between a UV filter and ordinary glass in the laboratory. Take a fly culture vial, remove the stopper, place it under a stereo dissecting microscope, and cover it (alternately) with a UV filter and a Petri dish lid. The photographs taken in these two cases are shown in Figure 5. The photograph taken through the UV filter is clear and sharp, very similar to the photograph taken when the culture vial is not covered. The quality of the photo taken through the glass of the Petri dish is very poor even when the focus is accurate. Ordinary glass (or acrylic sheet) is not coated, the highest transmittance is 92%14,15, and the clear/UV filter with multi-layer coating has a light transmittance of 98-99%.

Thus, the image shot through ordinary glass (or acrylic sheet) is not as clear as the image shot through the clear/UV filter. Another important defect of ordinary glass, such as the lid of a laboratory dish, is its uneven surface. It can be seen in Figure 5 that due to the unevenness of the glass surface, part of the photo is clear and part blurred. Therefore, clear/UV filters should be used instead of using ordinary glass or acrylic sheets to cover the FBOC. The UV filter used in this protocol (Figure 5) was cheap (~$10), unbranded, and its light transmittance unknown. In other words, even if it is a cheap UV filter, the image captured through it may be much clearer and sharper than that captured through ordinary glass.

Good quality without expensive equipment
Fly behavior was recorded with a JPEG-only camera with a considerably smaller sensor (1/2.3'). Video resolution is 1920 x 1080 pixels (at 30 frames per second, fps); the quality of the movie is satisfactory. A cheap UV filter was used to cover the FBOC, and the stereo zoom microscope was unbranded. The cost of the LED light (e.g., GODOX led-p120) was approximately $70 for two packs (see the Table of Materials). In other words, the equipment used was very economical; however, the video quality is good, clearly showing the panorama of some behaviors of flies, such as courtship and fighting, and the details of some behaviors, such as oviposition and excretion. In other words, even if it is a cheap UV filter, the image captured through it may be clearer and sharper than that captured through ordinary glass. 

Figure 6 is a photograph taken from the video recording showing the details of each part of the fly's body. Obviously, the use of a camera and a stereo microscope with better image quality will yield videos or photographs with higher image quality. If the camera has a frame rate of ≥60 fps with good image quality, far more details can be captured in greater clarity in behavior with lots of action or movement. Another advantage of this system is that because the camera is connected to a zoom stereo microscope, it is very easy to shoot from panoramic to close-up shots using the zoom system.

All-round recording
Observation and videography are usually done from the top; however, as flies can stay on any part of the FBOC: the vertical FBOC wall, the inclined food surface, and even the UV filter (with the abdomen facing upwards), and their bodies are perpendicular to these surfaces, their behavior can be observed and documented from multiple viewing angles. For example, it can be clearly seen in Figure 7 that the female fly is constantly rubbing the ovipositor with her hind legs during the process of laying eggs. This detail of egg-laying behavior cannot be seen clearly from the side5.

Figure 1
Figure 1: Photographic equipment and other accessories used to construct fly behavior observing and documenting system. Abbreviation: LED = light-emitting diode. Please click here to view a larger version of this figure.

Figure 2
Figure 2: Drosophila behavior observation and recording system. Please click here to view a larger version of this figure.

Figure 3
Figure 3: Illustration of the size and shape of food. Please click here to view a larger version of this figure.

Figure 4
Figure 4: Illustration of the FBOC complex. Abbreviation: FBOC = fly behavior observation chamber. Please click here to view a larger version of this figure.

Figure 5
Figure 5: Comparison between the photographs taken through the UV filter, through the lid of the laboratory Petri dish, and taken directly without any cover. Please click here to view a larger version of this figure.

Figure 6
Figure 6: An image taken from the video recording. Please click here to view a larger version of this figure.

Figure 7
Figure 7: An unusual perspective to observe the egg-laying behavior of fruit flies. Please click here to view a larger version of this figure.

Subscription Required. Please recommend JoVE to your librarian.


Light is at the very heart of photography and videography and is the decisive factor for obtaining high-quality images16. Here, two LED video lights with adjustable brightness and color temperature were used as illuminators, and a translucent material was selected to make the FBOC. The LED light panels on both sides provided enough brightness, and the translucent material softened and scattered light, eventually producing uniform, soft, and bright light to illuminate the flies in the FBOC, without producing unpleasant overexposed or underexposed areas. The ideal illumination can be achieved without sophisticated and expensive lighting equipment. Here, the UV/clear filter used had very high light transmittance and low reflection to cover the FBOC, and the light loss is very small. These measures ensured clear and sharp images.

We connected a digital camera to the eyepiece of the stereo zoom microscope through a bracket and took photographs or videos through the eyepiece. All images that could be observed under the microscope could be recorded. By rotating the focusing button and lifting the microscope, it was very easy to track the flies in the narrow space of the FBOC and to zoom in or out as needed to record local details or overall dynamics, which cannot be achieved by using a video recorder or camera for direct videography of the FBOC. At the same time, the camera can be selected according to the image quality requirements. In fact, a digital camera can be connected to any microscope with an eyepiece through a bracket. The corresponding author of this paper has successfully recorded experimental results in this way for many years.

The compact digital camera used to record the behavior of fruit flies must have 3-5x optical zoom (digital zoom should not be used for video recording). The telephoto end of these cameras (~100 mm focal length) is used to enlarge the image in the center of the field of view to the entire screen, so that the final image obtained is a pleasant image with no vignetting around it. If a camera has only a wide-angle fixed focus lens, or an optical zoom lens above 7x, there will be more or less unpleasant vignetting around the captured image. Neither digital single-lens reflex cameras nor camcorders are suitable for the method described in this article. The camera must be capable of recording video with a resolution of at least 1080 P at 30 fps. If the camera cannot be powered by continuous power, more spare batteries must be purchased for replacement at any time.

The flies can stand on a plane at any angle, their bodies are perpendicular to this surface. Even when sleeping, they can stand motionless on the vertical culture bottle wall. Therefore, when shooting from top to bottom, as long as we provide them with a plane at an appropriate angle, the behavior of the fruit fly can be observed and photographed in all directions, without the need to shoot its behavior from the side of an FBOC. This is the reason for the quadrangular food pyramid design.

However, in this system, the camera cannot focus and lock the flies and shoot automatically as they move across the frame. The experimenter must always use the focus and zoom functions of the stereo microscope to track the flies for shooting. It is for this reason that the diameter of the FBOC should be small, and the depth of the FBOC should be shallow, so that the experimenter can quickly track the moving fruit flies. Some behaviors may need to be recorded in the dark17,18. This article does not discuss those aspects of fly behavior.

Subscription Required. Please recommend JoVE to your librarian.


The authors have nothing to disclose.


We thank Professor Li Xiangdong and photographer Mr. Cheng Jing for helpful discussions and suggestions. This work was supported by the Exploratory Project (20200101) of the Life Science Experimental Teaching Demonstration Center of China Agricultural University.


Name Company Catalog Number Comments
compact camera, Nikon P310 Nikon 3-5x optical zoom, cam record 1080 P HD video
ethylamine foam 60 mm x 60 mm x 15 mm
Food Blue No 1 CAS 3844-45-9
mini LED lights and transformer GODOX LED-P120 have 5000-5600 K color temperature
small container (e.g. bottle cap) about Ø 15 mm x 20 mm
UV / Clear filter high-quality UV/Clear filter with high transmittance, 30-40 mm
zoom stereo microscope 5-50x zoom



  1. Chyb, S., Gompel, N. Atlas of Drosophila morphology: Wild-type and classical mutants. Academic Press. (2013).
  2. Yang, D. Carnivory in the larvae of Drosophila melanogaster and other Drosophila species. Scientific Reports. 8, 15484 (2018).
  3. Piper, M. D., et al. A holidic medium for Drosophila melanogaster. Nature Methods. 11, 100-105 (2014).
  4. Shiraiwa, T., Carlson, J. R. Proboscis extension response (PER) assay in Drosophila. Journal of visualized experiments : JoVE. (3), e193 (2007).
  5. Yang, C. -H., Belawat, P., Hafen, E., Jan, L. Y., Jan, Y. -N. Drosophila egg-laying site selection as a system to study simple decision-making processes. Science. 319, (5870), 1679-1683 (2008).
  6. Yang, D. Simple homemade tools to handle fruit flies-Drosophila melanogaster. Journal Of Visualized Experiments: JoVE. (149), e59613 (2019).
  7. Nichols, C. D., Becnel, J., Pandey, U. B. Methods to assay Drosophila behavior. Journal of Visualized Experiments: JoVE. (61), e3795 (2012).
  8. Barron, A. B. Anesthetizing Drosophila for behavioural studies. Journal of Insect Physiology. 46, (4), 439-442 (2000).
  9. Cicala, R. My not quite complete protective filter article. Available from: https://www.lensrentals.com/blog/2017/06/the-comprehensive-ranking-of-the-major-uv-filters-on-the-market (2017).
  10. Carnathan, B. UV and clear lens protection filters review. Available from: https://www.the-digital-picture.com/Reviews/UV-and-Clear-Lens-Protection-Filters.aspx (2013).
  11. Shaw, P. J., Cirelli, C., Greenspan, R. J., Tononi, G. Correlates of sleep and waking in Drosophila melanogaster. Science. 287, (5459), 1834-1837 (2000).
  12. Barradale, F., Sinha, K., Lebestky, T. Quantification of Drosophila grooming behavior. Journal of Visualized Experiments: JoVE. (125), e55231 (2017).
  13. Szebenyi, A. L. Cleaning behaviour in Drosophila melanogaster. Animal Behaviour. 17, (4), 641-651 (1969).
  14. Arkema Inc. Plexiglas : optical and transmission characteristics. Available from: https://www.plexiglas.com/export/sites/plexiglas/.content/medias/downloads/sheet-docs/plexiglas-optical-and-transmission-characteristics.pdf (2000).
  15. Fluegel, A. Calculation of the light reflection and transmission. Available from: https://www.glassproperties.com/reflection/ (2007).
  16. Hunter, F., Biver, S., Fuqua, P. Light science & magic: an introduction to photographic Lighting. Routledge. (2015).
  17. Hendricks, J. C., et al. Rest in Drosophila is a sleep-like state. Neuron. 25, (1), 129-138 (2000).
  18. Rieger, D., et al. The fruit fly Drosophila melangaster favors dim light and times its activity peaks to early dawn and late dusk. Journal of Biological Rhythms. 22, (5), 387-399 (2007).
This article has been published
Video Coming Soon

Cite this Article

Li, T., Weng, Y., Yang, D. An Adjustable High-Definition Imaging System for Behavioral Studies of Drosophila Adults. J. Vis. Exp. (172), e62533, doi:10.3791/62533 (2021).More

Li, T., Weng, Y., Yang, D. An Adjustable High-Definition Imaging System for Behavioral Studies of Drosophila Adults. J. Vis. Exp. (172), e62533, doi:10.3791/62533 (2021).

Copy Citation Download Citation Reprints and Permissions
View Video

Get cutting-edge science videos from JoVE sent straight to your inbox every month.

Waiting X
simple hit counter