At step S1, a red image is acquired from among red, green, and blue images constituting a received endoscopic image. At step S2, M sampling-pixels (where M denotes an integer equal to or larger than 1) are selected from the data of the red image. At step S3, a gradient vector is calculated in order to determine the direction of a gradient in brightness represented by each sampling-pixel. At step S4, the direction of a lumen is detected. At step S5, the detected direction of a lumen is adopted as an inserting direction and arrow information is superposed on an image. The resultant image is displayed on a display device. Control is then returned to step S1, and the same steps are repeated relative to data of the next frame. Consequently, even if the lumen disappears from a field of view for imaging, the inserting direction can be detected.