[Purpose] To provide an image processing device, an image processing method, and an image processing program capable of performing image processing beneficial for producing an image having high visibility without giving a sense of incongruity to a user such as a doctor.[Resolution Means] An image processing device is provided, the image processing device being provided with a weighting determination unit and a brightness calculation unit, wherein: when a region made up of a plurality of pixels, which is at least one portion of an input image input to the image processing device, is defined as a noted region, and this input image, either originally or as a result of an operation after being input, is an image expressed in an RGB color space, that is, each pixel is made up of an R component configuring red, a G component configuring green, and a B component configuring blue, and these are collectively defined as RGB components, the weighting determination unit respectively determines a weighting coefficient corresponding to each RGB component based on a quantity of each RGB component in the noted region, and the brightness calculation unit calculates brightness of each pixel included in the noted region based on each of the weighting coefficients.