Real-time image analysis in endodontics opens new options of treatment support in dentistry. Imaging software was developed to detect the root canal orifices in video sequences of trepanated teeth acquired by a digital video microscope, the Motic DM 143. The software developed is capable of communicating with any video camera connected to it and can automatically detect almost all root canal orifices in trepanated teeth. To recognize the root canal orifices we used the so-called Minimum-Distance Classification. The Minimum-Distance Classification provides a color-based pattern recognition algorithm, which is directly implemented in the function accessing the video stream, and is therefore very fast. Processing speed varied between 30 and 64 ms per image with an input image resolution of 352 x 288 pixels on the Pentium 4 computer (2 GHz). The developed software was tested in this study on 78 trepanated teeth. The mean detection sensitivity of the software found for all 78 teeth is 97.01%.