WO2011093317A1 - 画像処理装置、画像処理方法、コンピュータプログラム、記録媒体、画像処理モジュール、及び、電子機器 - Google Patents

画像処理装置、画像処理方法、コンピュータプログラム、記録媒体、画像処理モジュール、及び、電子機器 Download PDF

Info

Publication number
WO2011093317A1
WO2011093317A1 PCT/JP2011/051455 JP2011051455W WO2011093317A1 WO 2011093317 A1 WO2011093317 A1 WO 2011093317A1 JP 2011051455 W JP2011051455 W JP 2011051455W WO 2011093317 A1 WO2011093317 A1 WO 2011093317A1
Authority
WO
WIPO (PCT)
Prior art keywords
image
mcu
image processing
subject
mode
Prior art date
Application number
PCT/JP2011/051455
Other languages
English (en)
French (fr)
Inventor
上島 拓
大輔 倉
和生 清水
Original Assignee
新世代株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from JP2010001921U external-priority patent/JP3159906U/ja
Application filed by 新世代株式会社 filed Critical 新世代株式会社
Publication of WO2011093317A1 publication Critical patent/WO2011093317A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/50Depth or shape recovery
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/70Determining position or orientation of objects or cameras
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10016Video; Image sequence

Definitions

  • the present invention relates to an image processing apparatus, an image processing module, an electronic device, and related technology for processing an image in which a subject is reflected and outputting a processing result.
  • the electronic device of Patent Document 1 has a camera and automatically switches between a normal shooting mode and a close-up mode according to the distance of the subject.
  • the zoom lens moves in the first range
  • the zoom lens moves in a second range different from the first range.
  • the moving range of the zoom lens varies depending on the distance of the subject.
  • the golf game system disclosed in Patent Document 2 by the applicant of the present application includes a game machine and a golf club type input device, and an imaging unit is housed inside the housing of the game machine. It is composed of an infrared light emitting diode or the like. Infrared light is intermittently irradiated to a predetermined range above the image pickup unit by the infrared light emitting diode. Therefore, the image sensor intermittently applies a reflector provided in the golf club type input device moving within the range. Take a picture. By processing such a strobe image of the reflector, the speed to be input to the game machine is calculated. In this way, an input can be given in real time to a computer or game machine using a stroboscope.
  • Patent Document 1 it is convenient if the normal shooting mode and the close-up mode can be automatically switched. Although it is completely different from this, if the contents of the image processing can be automatically changed according to the distance of the subject, it is very convenient and has high utility value.
  • an object of the present invention is to provide an image processing apparatus capable of judging the distance of a subject and automatically setting an image processing mode according to the distance and related technology.
  • an imaging unit that captures a reflector, and a processor that calculates a motion of the reflector by processing a strobe image of the reflector are built in the game machine. It is a dedicated product for the machine and lacks versatility. Moreover, the processor not only calculates the movement of the reflector, but also executes a game program to control the game. For this reason, it is necessary for the programmer to create not only a game program but also a program for calculating the motion of the reflector by processing the strobe image of the reflector, which increases the burden.
  • another object of the present invention is to process a captured image of a subject, output the processing result to a computer of an external device, and use the processing result input by the computer of the external device as it is.
  • an image processing apparatus is configured to perform image processing on an image by a photographing unit that photographs a subject, and according to a distance between the subject and the photographing unit.
  • Switching means for switching the image processing mode is configured to perform image processing on an image by a photographing unit that photographs a subject, and according to a distance between the subject and the photographing unit.
  • the image processing mode is switched according to the distance between the subject and the photographing means, the image processing can be automatically changed according to the distance.
  • a relatively low resolution can be adopted, thereby reducing the cost.
  • a relatively distant subject even if the resolution is low, detailed analysis of the subject can be performed by image processing, and sufficiently practical results can be obtained.
  • sufficiently practical results can be obtained even with a low resolution by subjecting a relatively distant subject to different image processing than when the subject is nearby.
  • both near and far image processing can be performed with only one image processing apparatus.
  • the switching unit sets a first mode as the image processing mode according to a distance between the subject and the photographing unit, and a distance between the subject and the photographing unit. Is set longer than when the first mode is set, the second mode is set as the image processing mode, and the image processing means forms the subject imaged in the video when the first mode is set. All or part of the process for recognizing the image, the process for detecting the movement, the process for obtaining the coordinates, and the process for obtaining the area are performed, and the moving object as the subject is detected from the video when the second mode is set. All or part of the processing, the processing for obtaining the luminance of the photographing space, and the processing for detecting the presence of the subject is executed.
  • the first mode which is image processing for a short distance
  • processing for recognizing the form of the subject is performed in the first mode. It is possible to recognize the form even from a relatively low resolution image.
  • the second mode which is image processing for a long distance, even if the same image processing as in the first mode is performed, it is difficult to accurately recognize the form of the subject from the low-resolution image.
  • a process for detecting a moving object is executed. A moving object can be sufficiently detected from a relatively low resolution image. As a result of the above, it is possible to employ a relatively low resolution photographing means in both the near and far directions, thereby reducing the cost.
  • a sensor for recognizing the form of a subject at a short distance and a sensor (moving body sensor) for detecting a moving object at a long distance are provided.
  • a relatively high-resolution photographing means is usually employed as the form sensor, which is more expensive than a low-resolution photographing means.
  • the control device (CPU or the like) of the high-resolution photographing means becomes expensive.
  • the amount of processing increases in a high-resolution image, and it becomes difficult to cope with a case where an output result is requested at high speed.
  • a pyroelectric sensor is usually employed as the moving body sensor.
  • the pyroelectric sensor may be cheaper than a relatively low-resolution imaging means, it detects a change in room temperature, so that the occurrence of the change can be detected, but the coordinates of the object cannot be detected.
  • the pyroelectric sensor cannot detect the presence of an object when the object is detected and then the object does not move.
  • the image processing means executes processing for detecting and tracking the moving object when the second mode is set.
  • the image processing means executes a process of recognizing a shape as a form of the subject when the first mode is set.
  • the image processing unit executes a process of detecting a rotation operation as a movement of the subject when the first mode is set.
  • the switching unit is reflected in a difference image between the video by the photographing unit when the light emitting unit emits light and the video by the photographing unit when the light emitting unit is turned off.
  • Area calculating means for calculating the area of the subject, and setting means for determining the distance between the subject and the photographing means based on the area of the subject and setting the image processing mode.
  • the distance between the photographing unit and the subject can be easily determined based on the area.
  • the light from the light emitting means does not reach, or even if it reaches, the reflected light is weak and is not detected by the photographing means. This object is not reflected.
  • a nearby object reflects the light and appears in the photographed image. Therefore, since the background component is removed by the difference, only the object that reflects the light emitted by the light emitting means appears in the difference image. In this way, only an image of a nearby object can be extracted by a simple process such as difference.
  • the image processing unit captures the image by the photographing unit when the light emitting unit emits light and the photographing when the light emitting unit is turned off.
  • the image processing is performed on the video by the photographing unit when the light emitting unit is turned off.
  • the switching means includes first area calculation means for calculating an area of the subject reflected in the first difference image in the first mode, and the subject on the first difference image in the first mode.
  • the distance between the subject and the photographing unit is determined based on the area, and the first mode is set according to the distance, and the distance between the subject and the photographing unit is
  • the first setting means for setting the second mode when it is longer than the setting time of the first mode, and in the second mode, the image by the photographing means when the light emitting means emits light and the light emitting means is turned off.
  • Second area calculating means for calculating the area of the subject reflected in the second difference image with the video by the photographing means at the time, and in the second mode, the area of the subject on the second difference image And determining the distance between the subject and the photographing means, and setting the second mode according to the distance, wherein the distance between the subject and the photographing means is the second mode.
  • a second setting means for setting the first mode when it is shorter than the setting time.
  • the distance between the photographing unit and the subject can be easily determined based on the area.
  • the light from the light emitting means does not reach, or even if it reaches, the reflected light is weak and is not detected by the photographing means. This object is not reflected.
  • a nearby object reflects the light and appears in the photographed image. Therefore, since the background component is removed by the difference, only the object that reflects the light emitted by the light emitting means appears in the difference image. In this way, only an image of a nearby object can be extracted by a simple process such as difference.
  • the light emitting means does not need to emit light, but the light emitting means required in the first mode image processing is shared in the second mode for switching the image processing mode. . As a result, cost can be reduced.
  • the imaging cycle of the imaging unit for obtaining the second difference image in the second mode is longer than the imaging cycle of the imaging unit for obtaining the first difference image in the first mode. Is set.
  • the shooting cycle for switching the image processing mode in the second mode is shortened, power consumption can be suppressed.
  • the determination for switching the image processing mode does not need to be performed in the same cycle as the image processing, and does not substantially affect the performance.
  • an image processing apparatus is an image processing apparatus that processes an image output by an imaging unit that captures a subject, and includes a current image and a past image output by the imaging unit.
  • a difference means for calculating a difference between the first threshold value, a detection means for detecting a change in pixel value based on the difference, a first threshold value, and a second threshold value smaller than the first threshold value, and a frequency of change in the pixel value. If the frequency exceeds the first threshold or falls below the second threshold, the change is determined to be noise, and if the frequency is between the first threshold and the second threshold, the change is substantially Determining means for determining that the moving object is present.
  • the first threshold value since the first threshold value is provided, a motion with a high frequency of change of the pixel value, for example, a periodic motion with a relatively high frequency such as a flicker of a television can be removed as noise.
  • the second threshold value since the second threshold value is provided, it is possible to remove noise on the image caused by a movement with a low frequency of pixel value change, for example, a change in the shooting environment (the shooting space or the state of the shooting means).
  • an image processing apparatus is an image processing apparatus that processes an image output by an imaging unit that captures a hand as a subject, and the image processing apparatus is configured to process the hand from an image output by the imaging unit.
  • a finger specifying means for extracting a contour line and specifying a finger based on a pixel between an inflection point pixel of the contour line and a pixel at an inflection point next to the inflection point; and a predetermined reference line
  • an angle calculation means for calculating an inclination angle of each finger specified by the finger specifying means, and an angle formed by the adjacent finger specified by the finger specifying means based on the inclination angle of each finger.
  • Finger angle calculation means for calculating, and determination means for determining the shape of the hand based on the angle formed by the adjacent finger and the finger.
  • the finger is specified based on the pixel between the fingertip and the webbed, and the finger is not specified based on the center of gravity of the contour image.
  • the finger can be identified, and as a result, the shape of the hand can be determined with higher accuracy.
  • the center of gravity of the contour image and the center of gravity of the subject often do not match. In this case, if a finger is specified by the center of gravity, the accuracy of recognition is lowered.
  • the finger specifying unit includes a unit that specifies a pixel corresponding to a fingertip from pixels on the contour line of the subject, and the image processing unit is configured to detect the fingertip from the center of gravity of the contour image of the subject. Further comprising means for calculating a distance to the pixel corresponding to the determination means, based on the angle formed by the adjacent finger and the finger, and the distance to the pixel corresponding to the fingertip, Determine the shape of the hand.
  • the hand Since the shape is determined, more various hand shapes can be determined.
  • the present invention can be applied to an algorithm for determining that the shape of the hand is “pick”.
  • an image processing apparatus is an image processing apparatus that processes an image output by an imaging unit that captures a hand as a subject, and is located on a contour line from the center of gravity of the contour image of the hand.
  • Distance calculating means for calculating the distance to each pixel; and determining means for determining the shape of the hand based on the distance to each pixel.
  • the shape of the hand can be determined by a simple calculation such as obtaining the distance from the center of gravity to the pixel on the contour line. For example, when the distance from the center of gravity to the pixel on the contour line is within a certain range, it can be determined that the shape of the hand is “Goo”.
  • an image processing apparatus is an image processing apparatus that processes an image output by an imaging unit that captures a subject, the center of gravity of the contour image of the subject and pixels on the contour line.
  • a length calculating means for calculating the length of a connecting line segment, an angle calculating means for calculating an angle formed by the line segment with respect to a predetermined reference line, and the length as a function of the angle.
  • Rotation detection means for setting a phase difference as a rotation angle of the subject.
  • the rotation angle of the hand can be detected easily and accurately.
  • an image processing method is an image processing method for processing a video output by a photographing means for photographing a subject, wherein a computer performs image processing on the video output by the photographing means. And a step of switching the image processing mode according to a distance between the subject and the photographing means.
  • This configuration has the same effects as the image processing apparatus according to the first aspect.
  • an image processing method is an image processing method for processing an image output by an imaging unit that captures a subject, and includes a current image and a past image output by the imaging unit. Calculating a difference between the pixel value, detecting a change in pixel value based on the difference, and setting a first threshold value and a second threshold value smaller than the first threshold value, and the frequency of the pixel value change is When the first threshold value is exceeded or less than the second threshold value, the change is determined as noise, and when the frequency is between the first threshold value and the second threshold value, the change is regarded as a substantial change. Determining, and determining that the moving object is present.
  • This configuration has the same effect as the image processing apparatus according to the second aspect.
  • an image processing method is an image processing method for processing an image output by an imaging unit that captures a hand as a subject, and the image is output from the image output by the imaging unit. Extracting a contour line, identifying a finger based on a pixel between the pixel of the inflection point of the contour line and the pixel of the inflection point next to the inflection point, and a predetermined reference line, The step of calculating the inclination angle of each finger specified by the step of specifying the finger, and the angle formed by the adjacent finger specified by the step of specifying the finger are the inclination angle of each finger. And calculating the shape of the hand based on the angle formed by the adjacent fingers.
  • This configuration has the same effect as the image processing apparatus according to the third aspect.
  • an image processing method is an image processing method for processing an image output by a photographing means for photographing a hand as a subject, and the contour processing is performed on the contour line from the center of gravity of the contour image of the hand. Calculating a distance to each pixel; and determining a hand shape based on the distance to each pixel.
  • This configuration has the same effects as the image processing apparatus according to the fourth aspect.
  • an image processing method is an image processing method for processing an image output by a photographing means for photographing a subject, wherein the center of gravity of the contour image of the subject and pixels on the contour line are calculated.
  • This configuration has the same effect as the image processing apparatus according to the fifth aspect.
  • the computer program causes a computer to execute any one of the image processing methods according to the sixth to tenth aspects.
  • the recording medium is a computer-readable recording medium recording the computer program according to the eleventh aspect.
  • recording media include, for example, flexible disks, hard disks, magnetic tapes, magneto-optical disks, CDs (including CD-ROMs and Video-CDs), DVDs (DVD-Videos, DVD-DVDs).
  • CDs including CD-ROMs and Video-CDs
  • DVDs DVD-Videos, DVD-DVDs
  • ROM, DVD-RAM ROM cartridge
  • RAM memory cartridge with battery backup flash memory cartridge
  • nonvolatile RAM cartridge and the like.
  • the image processing module is an image processing module connected to an external computer, and is arranged in an MCU (Micro Controller Unit) and inside and / or outside the MCU, A memory for storing a program and data executed by the MCU, an image sensor for photographing a subject, a light emitting unit including an infrared light emitting diode for emitting infrared light, a power supply terminal and a signal terminal, and A connector for connecting to the external computer; a power supply line for supplying a power supply voltage applied to the power supply terminal from the outside to the MCU, the memory, the image sensor, and the light emitting unit; and the connector A signal line connecting the signal terminal and the MCU, the MCU, and the image Comprising a bus for connecting the sensor, and the.
  • MCU Micro Controller Unit
  • the MCU or the image sensor controls the switching transistor to intermittently drive the infrared light emitting diode, and when the light emitting unit does not include a switching transistor.
  • the infrared light emitting diode is intermittently driven by directly controlling the infrared light emitting diode.
  • the image sensor executes a photographing process when the infrared light emitting diode emits infrared light and when the infrared light emitting diode does not emit infrared light.
  • a difference image between a photographed image when external light is emitted and a photographed image when infrared light is not emitted is generated, and the difference image is transmitted to the MCU via the bus; or
  • a first captured image when infrared light is emitted and a second captured image when infrared light is not emitted are generated, and the first captured image and the second captured image are transmitted to the MCU via the bus.
  • the image sensor In the case where the image sensor generates the difference image, the image sensor generates the difference image at a constant cycle corresponding to intermittent driving of the infrared light emitting diode and transmits the difference image to the MCU.
  • the difference image includes a plurality of pixels, and the image sensor serially transmits one pixel at a time when transmitting the difference image to the MCU, and the MCU receives one pixel from the image sensor. Each time it is compared with a predetermined threshold value, it is binarized, stored in the memory, and the binarized difference image stored in the memory (hereinafter referred to as “analysis target difference image”).
  • analysis target difference image is analyzed, and the analysis result is represented by the signal line and The signal is transmitted to the external computer via the signal terminal of the connector.
  • the image sensor In the case where the image sensor generates the first captured image and the second captured image, the image sensor has the first captured image at a constant period corresponding to intermittent driving of the infrared light emitting diode. And the second captured image is generated and transmitted to the MCU, and the MCU generates a difference image between the first captured image and the second captured image, stores the difference image in the memory, and stores the difference image in the memory.
  • the difference image (hereinafter referred to as “analysis target difference image”) is analyzed, and the analysis result is transmitted to the external computer via the signal line and the signal terminal of the connector. .
  • the analysis of the analysis target difference image by the MCU is performed every time the analysis target difference image is newly stored in the memory, and the analysis result is obtained via the signal line and the signal terminal of the connector. Sent to an external computer.
  • the analysis of the analysis target difference image by the MCU includes recognition of the shape of the subject image reflected in the analysis target difference image, recognition of the color of the image, recognition of the pattern of the image, and calculation of the coordinates of the image. Calculating the area of the image, calculating the rotation amount or angle of the image, calculating the rotation direction of the image, calculating the velocity of the image, calculating the acceleration of the image, calculating the movement trajectory of the image, This includes all or part of the detection of the moving object as the subject and the detection of the presence of the subject in the analysis target difference image, and the analysis result is obtained via the signal line and the signal terminal of the connector. And transmitted to the external computer.
  • the MCU transmits an interrupt signal or command to the external computer via the signal line and the signal terminal of the connector when the analysis result of the analysis target difference image satisfies a predetermined condition. It is possible to mount.
  • the MCU, the memory, the image sensor, the light emitting unit, the connector, the power supply line, the signal line, and the bus are mounted on a predetermined substrate.
  • the image processing module further includes a lens unit fixed on the predetermined substrate.
  • the lens unit includes a lens and a lens holder that holds the lens, and the image sensor is on the predetermined substrate, below the lens, on the optical axis of the lens, and , Disposed inside the lens holder.
  • the image processing module further includes an infrared light filter that transmits only infrared light, and the infrared light filter is disposed between the image sensor and the lens inside the lens unit, or The lens unit is disposed outside the lens unit so as to cover the lens.
  • the external computer is a home appliance such as an air conditioner, a television, an audio device, a photo frame or a lighting device, an entertainment device such as an electronic toy or a video game machine, a security device, an in-vehicle electronic device such as a car navigation, or It can be a computer of a display device such as an LCD, or a personal computer.
  • the captured image of the subject is processed (recognition of the shape of the subject image reflected in the difference image to be analyzed, recognition of the color of the image, recognition of the pattern of the image, Calculation of coordinates, calculation of the area of the image, calculation of the rotation amount or rotation angle of the image, calculation of the rotation direction of the image, calculation of the speed of the image, calculation of the acceleration of the image, calculation of the movement trajectory of the image Calculation, detection of a moving object as a subject reflected in the difference image to be analyzed, and detection of the presence of the subject), and processing results thereof are output to an external computer.
  • the external computer can use the processing result input from the image processing module as it is.
  • this image processing module is provided as a module that performs only photographing and image processing, a computer that uses the processing result or an external device in which the computer is mounted is not limited to a specific one. Has high versatility.
  • the captured image is far away regardless of whether the light emitting part emits light or not. This object is not reflected.
  • a nearby object reflects the light and appears in the captured image. Therefore, since the background component is removed by the difference, only the object that reflects the light emitted by the light emitting unit appears in the difference image. In this way, only an image of a nearby object can be extracted by a simple process such as difference.
  • the present invention is particularly effective when the subject is located at a relatively short distance from the image sensor. This is because the subject is irradiated with infrared light and is photographed by the image sensor. Of course, this does not preclude the use of this image processing module when the subject is located relatively far from the image sensor. In this case, for example, the emission intensity of the infrared light emitting diode is increased and / or the number thereof is increased.
  • the image processing module is an image processing module connected to an external computer, and is arranged in an MCU (Micro Controller Unit) and inside and / or outside the MCU, A memory for storing a program and data executed by the MCU, an image sensor for photographing a subject, a power supply terminal and a signal terminal, and a connector for connecting to the external computer; A power supply voltage applied to a terminal for supplying power to the MCU, the memory, and the image sensor; a signal line for connecting the signal terminal of the connector; and the MCU; And a bus for connecting the image sensor.
  • MCU Micro Controller Unit
  • the image sensor executes shooting processing at regular time intervals, and transmits the shot image to the MCU via the bus.
  • the MCU receives the captured image from the image sensor, stores it in the memory, analyzes the captured image stored in the memory (hereinafter referred to as “analysis target image”), and analyzes the analysis result. Then, the signal is transmitted to the external computer via the signal line and the signal terminal of the connector.
  • the analysis of the analysis target image by the MCU is executed every time the analysis target image is newly stored in the memory, and the analysis result is obtained via the signal line and the signal terminal of the connector. Sent to the computer.
  • the analysis of the analysis target image by the MCU includes the recognition of the shape of the image of the subject reflected in the analysis target image, the recognition of the color of the image, the recognition of the pattern of the image, the calculation of the coordinates of the image, Calculation of area of image, calculation of rotation amount or rotation angle of image, calculation of rotation direction of image, calculation of speed of image, calculation of acceleration of image, calculation of movement trajectory of image, analysis target Detection of a moving object as the subject reflected in the image, calculation of luminance of the shooting space reflected in the analysis target image, calculation of luminance of the image of the subject reflected in the analysis target image, and All or part of the presence detection is included, and the analysis result is transmitted to the external computer via the signal line and the signal terminal of the connector.
  • the MCU has a function of transmitting an interrupt signal or a command to the external computer via the signal line and the signal terminal of the connector when an analysis result of the analysis target image satisfies a predetermined condition. It can be installed.
  • the MCU, the memory, the image sensor, the connector, the power supply line, the signal line, and the bus are mounted on a predetermined substrate.
  • the image processing module further includes a lens unit fixed on the predetermined substrate.
  • the lens unit includes a lens and a lens holder that holds the lens, and the image sensor is on the predetermined substrate, below the lens, on the optical axis of the lens, and , Disposed inside the lens holder.
  • the external computer is a home appliance such as an air conditioner, a television, an audio device, a photo frame or a lighting device, an entertainment device such as an electronic toy or a video game machine, a security device, an in-vehicle electronic device such as a car navigation, or It can be a computer of a display device such as an LCD, or a personal computer.
  • the photographed subject image is processed (recognition of the shape of the subject image reflected in the analysis target image, recognition of the color of the image, recognition of the pattern of the image, coordinate of the image Calculation of the area of the image, calculation of the rotation amount or rotation angle of the image, calculation of the rotation direction of the image, calculation of the speed of the image, calculation of the acceleration of the image, calculation of the movement trajectory of the image Detecting a moving object as a subject reflected in the analysis target image, calculating a luminance of a shooting space reflected in the analysis target image, calculating a luminance of an image of the subject reflected in the analysis target image, and existence of the subject Detection), and outputs the processing result to an external computer.
  • the external computer can use the processing result input from the image processing module as it is.
  • image processing by the external computer is not necessary, and the burden on the computer programmer can be reduced.
  • this image processing module is provided as a module that performs only photographing and image processing, a computer that uses the processing result or an external device in which the computer is mounted is not limited to a specific one. Has high versatility.
  • the present invention is particularly effective when the subject is located at a relatively long distance from the image sensor. This is because an object that reflects room light and / or outside light is photographed without providing an infrared light emitting diode. Of course, this does not preclude the use of this image processing module when the subject is located at a relatively close distance to the image sensor.
  • an image processing module is an image processing module connected to an external computer, and is arranged in an MCU (Micro Controller Unit) and inside and / or outside the MCU, A memory for storing a program and data executed by the MCU, an image sensor for photographing a subject, a light emitting unit including an infrared light emitting diode for emitting infrared light, a power supply terminal and a signal terminal, and A connector for connecting to the external computer; a power supply line for supplying a power supply voltage applied to the power supply terminal from the outside to the MCU, the memory, the image sensor, and the light emitting unit; and the connector A signal line connecting the signal terminal and the MCU, the MCU, and the image Comprising a bus for connecting the sensor, and the.
  • MCU Micro Controller Unit
  • the image sensor has a first shooting mode and a second shooting mode.
  • the MCU or the image sensor controls the switching transistor to drive the infrared light emitting diode intermittently when the light emitting unit includes a switching transistor, and the light emitting unit
  • the switching transistor When the switching transistor is not included, the infrared light emitting diode is directly controlled to drive the infrared light emitting diode intermittently.
  • the image sensor is configured so that the infrared light emitting diode emits infrared light and the infrared light emitting diode does not emit infrared light.
  • Executes photographing processing generates a difference image between a photographed image when infrared light is emitted and a photographed image when infrared light is not emitted, and transmits the difference image to the MCU via the bus.
  • generating a first photographed image when infrared light is emitted and a second photographed image when infrared light is not emitted, and the first photographed image and the second photographed image are The data is transmitted to the MCU via a bus.
  • the image sensor when the image sensor generates the difference image (hereinafter referred to as “first case”), the image sensor is intermittently connected to the infrared light emitting diode.
  • the difference image is generated and transmitted to the MCU at a fixed period corresponding to driving.
  • the difference image includes a plurality of pixels
  • the image sensor transmits the difference image serially pixel by pixel when transmitting the difference image to the MCU.
  • Each time one pixel is received from the sensor it is compared with a predetermined first threshold value, binarized, stored in the memory, and a binarized difference image (hereinafter, “ Analysis target difference image)), or in the first case, the MCU receives the difference image from the image sensor, stores it in the memory, and stores it in the memory.
  • the obtained difference image (hereinafter referred to as “analysis target difference image”) is analyzed.
  • the image sensor when the image sensor generates the first photographed image and the second photographed image (hereinafter referred to as “second case”), the image sensor performs the red photographing.
  • the first photographed image and the second photographed image are generated at a constant cycle corresponding to intermittent driving of the outer light emitting diode and transmitted to the MCU.
  • the MCU In the second case, the MCU generates a difference image between the first photographed image and the second photographed image, stores the difference image in the memory, and stores the difference image (hereinafter, “This is called “analysis target difference image”.
  • the analysis of the analysis target difference image by the MCU is executed every time the analysis target difference image is newly stored in the memory.
  • the image sensor executes shooting processing at regular time intervals, and transmits a shot image to the MCU via the bus.
  • the MCU receives the captured image from the image sensor, stores it in the memory, and stores the captured image stored in the memory (hereinafter referred to as “analysis target image”). To analyze.
  • the analysis of the analysis target image by the MCU is executed every time the analysis target image is newly stored in the memory.
  • the MCU has a first image processing mode and a second image processing mode.
  • the analysis of the analysis target difference image by the MCU is performed by recognizing the shape of the subject image reflected in the analysis target difference image, recognizing the color of the image, and determining the pattern of the image. Recognition, calculation of the coordinates of the image, calculation of the area of the image, calculation of the rotation amount or rotation angle of the image, calculation of the rotation direction of the image, calculation of the velocity of the image, calculation of the acceleration of the image, Including all or part of the calculation of the movement trajectory of the image, the detection of the moving object as the subject in the difference image to be analyzed, and the detection of the presence of the subject, and the analysis result includes the signal line and The signal is transmitted to the external computer via the signal terminal of the connector.
  • the MCU sends an interrupt signal or command to the signal line and the signal terminal of the connector when the analysis result of the analysis target difference image satisfies a first predetermined condition. It is possible to mount a function for transmitting to the external computer.
  • the analysis of the analysis target image by the MCU includes a process of detecting a moving object as the subject from the analysis target image, a process of obtaining a luminance of a shooting space reflected in the analysis target image, Including all or part of a process for obtaining the luminance of the image of the subject reflected in the analysis target image, and a process for detecting the presence of the subject from the analysis target image.
  • the signal is transmitted to the external computer via the signal terminal of the connector.
  • the MCU sends an interrupt signal or a command via the signal line and the signal terminal of the connector when the analysis result of the analysis target image satisfies a second predetermined condition.
  • the MCU sends an interrupt signal or a command via the signal line and the signal terminal of the connector when the analysis result of the analysis target image satisfies a second predetermined condition.
  • the image sensor operates in the first shooting mode
  • the MCU displays an analysis result of the analysis target difference image obtained in the first shooting mode as the signal line and the The signal is transmitted to the external computer via the signal terminal of the connector, and switching between the first image processing mode and the second image processing mode is performed based on the analysis target difference image.
  • the image sensor operates in the first shooting mode and the second shooting mode, and the MCU analyzes the analysis result of the analysis target image obtained in the second shooting mode.
  • the first image processing mode and the second image are transmitted to the external computer via the signal line and the signal terminal of the connector, and based on the analysis target difference image obtained in the first imaging mode. Switch between image processing modes.
  • the MCU calculates an area of the image reflected in the analysis target difference image, compares the area with a predetermined second threshold value, and the area is the predetermined second value. If the threshold is exceeded, the first image processing mode is maintained, and if the area is equal to or smaller than the predetermined second threshold, the first image processing mode is shifted to the second image processing mode.
  • the MCU calculates an area of the image reflected in the analysis target difference image, compares the area with the predetermined second threshold, and the area is the predetermined first value.
  • the threshold value is equal to or smaller than 2
  • the second image processing mode is maintained, and when the area exceeds the predetermined second threshold value, the second image processing mode is shifted to the first image processing mode.
  • the period when the infrared light emitting diode is intermittently driven in the first imaging mode is longer than or equal to the period in the first image processing mode.
  • the MCU, the memory, the image sensor, the light emitting unit, the connector, the power supply line, the signal line, and the bus are mounted on a predetermined substrate.
  • the image processing module further includes a lens unit fixed on the predetermined substrate.
  • the lens unit includes a lens and a lens holder that holds the lens, and the image sensor is on the predetermined substrate, below the lens, on the optical axis of the lens, and , Disposed inside the lens holder.
  • the image processing module further includes an infrared light filter that transmits only infrared light, and the infrared light filter is disposed between the image sensor and the lens inside the lens unit, or The lens unit is disposed outside the lens unit so as to cover the lens.
  • the external computer is a home appliance such as an air conditioner, a television, an audio device, a photo frame or a lighting device, an entertainment device such as an electronic toy or a video game machine, a security device, an in-vehicle electronic device such as a car navigation, or It can be a computer of a display device such as an LCD, or a personal computer.
  • the photographed subject image is processed (in the first image processing mode, the shape of the subject image reflected in the analysis target difference image, the color of the image, the recognition of the color of the image, Recognition of the pattern, calculation of the coordinates of the image, calculation of the area of the image, calculation of the rotation amount or rotation angle of the image, calculation of the rotation direction of the image, calculation of the velocity of the image, calculation of the acceleration of the image
  • the moving object as the subject is detected from the analysis target image in the second image processing mode, the calculation of the movement trajectory of the image, the detection of the moving object as the subject reflected in the analysis target difference image, and the presence of the subject.
  • processing processing for obtaining the luminance of the shooting space reflected in the analysis target image, calculation of the luminance of the subject image reflected in the analysis target image, processing for detecting the presence of the subject from the analysis target image), and processing results thereof The outside And outputs it to the computer.
  • the external computer can use the processing result input from the image processing module as it is.
  • image processing by the external computer is not necessary, and the burden on the computer programmer can be reduced.
  • this image processing module is provided as a module that performs only photographing and image processing, a computer that uses the processing result or an external device in which the computer is mounted is not limited to a specific one. Has high versatility.
  • the distance between the subject and the image sensor is determined, and the first image processing mode and the second image processing mode are switched. That is, since the area of the subject on the image correlates with the distance between the image sensor and the subject, the perspective between the image sensor and the subject can be determined based on the area.
  • the image processing mode is switched according to the distance between the subject and the image sensor, the image processing can be automatically changed according to the distance. For this reason, it is possible to easily cope with an electronic device that requires that image processing when the subject exists close to the image sensor be different from image processing when the subject exists relatively far from the image sensor. .
  • a relatively low resolution image sensor can be adopted, and the cost can be reduced.
  • For a nearby subject even if the resolution is low, detailed analysis of the subject can be performed by image processing, and sufficiently practical results can be obtained.
  • For a relatively distant subject it is difficult to obtain a result with the same accuracy as when the subject is close by performing the same image processing as when the subject is close when the resolution is low. . Therefore, if the image processing is the same regardless of the perspective at low resolution, it cannot be applied to subjects that are relatively far away, and a high-resolution image sensor is used to support both perspective. No choice but was.
  • sufficiently practical results can be obtained even with a low resolution by subjecting a relatively distant subject to different image processing than when the subject is nearby. In this way, by varying the image processing according to the distance, the low-resolution image sensor can handle both near and far subjects.
  • the first image processing mode that is image processing for a short distance
  • processing for recognizing the shape of the subject is executed.
  • Shape recognition is sufficiently possible even from relatively low-resolution images.
  • the second image processing mode that is image processing for a long distance
  • a process for detecting a moving object is executed.
  • a moving object can be sufficiently detected from a relatively low resolution image.
  • a relatively low-resolution image sensor can be employed in both the near and far directions, thereby reducing costs.
  • a sensor for recognizing the form (shape, pattern, color, or any combination thereof) of a subject at a short distance and a sensor (moving body sensor) for detecting a moving object at a long distance. It is assumed that
  • a relatively high resolution image sensor is usually employed as the form sensor, which is more expensive than a low resolution image sensor. Accordingly, a high-resolution image sensor control device (such as a CPU) is also expensive. Furthermore, the amount of processing increases in a high-resolution image, and it becomes difficult to cope with a case where an output result is requested at high speed.
  • a pyroelectric sensor is usually employed as the moving body sensor.
  • the pyroelectric sensor may be cheaper than a relatively low-resolution image sensor, but it detects a change in room temperature, so that the occurrence of the change can be detected, but the coordinates of the object cannot be detected.
  • the pyroelectric sensor cannot detect the presence of an object when the object is detected and then the object does not move.
  • the light emitting unit does not need to emit light, but the light emitting unit required in the first image processing mode is shared in the second image processing mode for switching the image processing mode. .
  • cost can be reduced.
  • the power consumption can be suppressed by making the period when the infrared light emitting diode is intermittently driven in the first imaging mode longer than that in the first image processing mode. .
  • the determination for switching the image processing mode does not need to be performed in the same cycle as the image processing, and does not substantially affect the performance.
  • the electronic device controls the predetermined device based on the processing result of the image processing unit that processes the image output by the imaging unit that captures the subject.
  • the image processing means divides the image into a plurality of blocks, detects pixel changes for each of the blocks, and the control means responds to the pixel changes for each block, The predetermined device is controlled.
  • control means performs control for directing or not directing a predetermined device or a part of the predetermined device to an area (in real space) corresponding to a block in which an image change (that is, movement of a subject) is detected. Can be done.
  • control unit performs output of a predetermined device directed to each region (in real space) corresponding to each block with respect to the region corresponding to the block in which the image change (that is, the movement of the subject) is detected. Alternatively, control that is not performed can be performed.
  • control means controls the output of the predetermined device, the direction of the predetermined device, or the direction of a part of the predetermined device in accordance with the change of the pixel for each block.
  • the photographing unit is installed at a position where the subject can be viewed from above, and the predetermined apparatus is installed on the ceiling.
  • the device since overhead view shooting is performed, compared to shooting from the horizontal direction, there is less frequency with which multiple subjects overlap and it is possible to omit the determination of overlapping of multiple subjects, so it is simple
  • the device can be controlled by simple processing. As a result, it is suitable for controlling equipment installed on the ceiling.
  • the predetermined device is an air conditioner installed on a ceiling
  • the air conditioner has a wind direction adjusting mechanism for adjusting a wind direction
  • the control means is provided for each block.
  • the wind direction adjusting mechanism is controlled according to the change of the pixel.
  • the present invention is suitable for controlling an air conditioner installed on a ceiling.
  • FIG. 7 It is a figure which shows the electrical constitution of the image processing module 1 by embodiment of this invention. It is a flowchart which shows an example of the flow of the whole process by MCU3 of FIG. It is a flowchart which shows an example of the flow of control of the image sensor 5 of step S707 of FIG. It is a flowchart which shows an example of the flow of the difference image data acquisition process of step S27 of FIG. 7 is a flowchart illustrating an example of the flow of image processing mode switching processing in step S719 in FIG. 3. It is a flowchart which shows an example of the flow of a process in the moving body detection mode of step S713 of FIG.
  • 10 is a flowchart illustrating an example of a flow of processing for determining “pick” in step S267 in FIG. 9.
  • 10 is a flowchart illustrating an example of a process flow for determining “go” in step S269 in FIG. 9. It is a flowchart which shows an example of the flow of a process which detects the rotation of the outline image of step S199 of FIG.
  • FIG. 9 is an explanatory diagram of a deviation angle ⁇ j detected in step S193 of FIG. It is explanatory drawing of the inflection point detected by step S195 of FIG. 7, and the fingertip detected by step S263 of FIG. It is an illustration figure of the rotation table produced by step S309 of FIG.
  • FIG. (C) is a timing diagram of signals on a data output line connecting the MCU 3 and the computer 13 of FIG. It is a figure which shows the detailed electrical structure of the image processing module 1 of FIG. (A) It is a top view of the image processing module 1 of FIG. (B) It is a side view of the image processing module 1 of FIG. (C) It is an external appearance top view of the image processing module 1 of FIG. It is sectional drawing by the AA line of the lens unit 62 of Fig.24 (a).
  • FIG. 1 is a diagram showing an electrical configuration of an image processing module 1 according to an embodiment of the present invention.
  • the image processing module 1 includes an MCU (Micro Controller Unit) 3, an image sensor 5, and an infrared light emitting diode 7.
  • the MCU 3 includes a memory 9.
  • the image sensor 5 can be used in either color or gray scale, and any number of pixels can be used. In the present embodiment, the image sensor 5 is gray scale and has a relatively low resolution of 64 ⁇ 64 pixels. Is used.
  • the infrared light emitting diode 7 emits infrared light.
  • the number of infrared light emitting diodes 7 is not limited to one, and a plurality of infrared light emitting diodes 7 can be provided according to the specifications of the image processing module 1.
  • the image sensor 5 a CMOS image sensor, a CCD image sensor, or the like can be employed.
  • the memory 9 of the MCU 3 is a semiconductor memory such as a RAM, a ROM, and a flash memory, and is used as a program storage area, a data storage area, a work area, a temporary storage area, and the like.
  • the MCU 3 executes various processes shown in the flowcharts described later in accordance with the program stored in the memory 9.
  • an optical disc such as a CD (including CD-ROM, Video-CD) and a DVD (including DVD-Video, DVD-ROM, DVD-RAM), a semiconductor
  • a memory card, a memory cartridge, a USB memory, a hard disk, a magneto-optical disk, a magnetic tape, a flexible disk, and the like equipped with a memory can be connected to the MCU 3.
  • programs and data can be stored in these.
  • the image processing module 1 is used by being connected to the electronic device 11.
  • the electronic device 11 includes a computer 13.
  • the electronic device 11 includes, for example, home appliances such as air conditioners, televisions, audio devices, photo frames, and lighting devices, entertainment devices such as electronic toys and video game machines, security devices, vehicle-mounted electronic devices such as car navigation systems,
  • a display device such as an LCD and a personal computer are not particularly limited.
  • the MCU 3 controls the image sensor 5 independently or in response to a command from the computer 13 of the electronic device 11 in accordance with a program stored in the memory 9.
  • the image sensor 5 shoots a subject under the control of the MCU 3 and controls the infrared light emitting diode 7.
  • a system including the image processing module 1 and the electronic device 11 may be referred to as an electronic device, and the electronic device 11 may be referred to as a device 11.
  • the image processing module 1 may be referred to as an image processing device 1.
  • the image processing module 1 has two image processing modes. One is a contour detection mode (first image processing mode), and the other is a moving object detection mode (second image processing mode).
  • the image processing module 1 automatically enters either the contour detection mode or the moving object detection mode according to the distance of the subject. That is, the image processing module 1 enters the contour detection mode when it is determined that the subject is present near, and enters the moving object detection mode when it is determined that the subject is present far away.
  • the outline detection mode will be described.
  • the image sensor 5 performs a photographing process when the infrared light emitting diode 7 is turned on and off, generates a difference image between the image at the time of lighting and the image at the time of turning off, and supplies the difference image to the MCU 3.
  • the infrared light emitting diode 7 emits infrared light intermittently. Assuming that the turn-on time and the turn-off time of the infrared light are one cycle, the image sensor 5 executes a difference image generation process every one cycle. Therefore, the MCU 3 performs the following difference image analysis processing for each cycle.
  • the MCU 3 detects the contour of the hand based on the difference image and determines one of goo, choki, par, and indefinite. Moreover, MCU3 detects the rotation angle of a hand. Further, the MCU 3 calculates the coordinates and area of the contour image. The MCU 3 transmits these pieces of information to the computer 13 of the electronic device 11. The computer 13 processes these pieces of information according to the specifications of the electronic device 11.
  • the computer 13 controls the cursor of the display device as the electronic device 11 in accordance with the coordinates of the contour image, recognizes goo, choki, and par as commands, and executes processes assigned to them.
  • Perform processing according to the hand rotation angle for example, rotate a virtual or real dial according to the hand rotation angle
  • the process according to is executed.
  • the user can operate the electronic device 11 without touching a panel or the like as in a conventional touch panel.
  • the computer 13 controls the screen of the display device as the electronic device 11 according to the movement of the coordinates of the contour image.
  • the computer 13 determines that the user has waved his hand in the horizontal right direction, and switches the screen so that the page is turned from left to right. Or, slide the display image from left to right to switch the screen.
  • the computer 13 switches the screen according to horizontal leftward movement, vertical upward movement, vertical downward movement, and the like of coordinates.
  • the moving object detection mode will be described.
  • the image sensor 5 performs a photographing process when the infrared light is extinguished, and gives the MCU 3 an image when extinguished (hereinafter also referred to as “moving object detection image”).
  • the image sensor 5 executes a photographing process for obtaining a moving object detection image (hereinafter also referred to as “moving object detection photographing process”) at regular time intervals.
  • MCU3 detects and tracks the moving object based on the moving object detection image. Moreover, MCU3 calculates the coordinate of a moving body. Further, the MCU 3 calculates the brightness of the photographed space. Furthermore, the MCU 3 detects whether the subject as a moving object is detected, but after that, when the subject is no longer detected, whether the subject no longer exists in the shooting space, or whether the subject exists in the shooting space but is stationary, Determine. For example, such a determination can be made by comparing a current image with a past image. The MCU 3 transmits these pieces of information to the computer 13 of the electronic device 11.
  • the computer 13 processes these pieces of information according to the specifications of the electronic device 11. For example, the computer 13 executes processing or control targeting a moving object. In this case, for example, the computer 13 directs the screen of the display device as the electronic device 11 toward the moving object, or directs the air outlet of the air conditioner as the electronic device 11 toward the moving object.
  • the computer 13 activates or stops the electronic device 11 using a change from a state in which no moving object is present to a state in which a moving object is present as a trigger.
  • the computer 13 activates or stops the electronic device 11 using a change from a state in which a moving object exists to a state in which no moving object exists as a trigger.
  • the MCU 3 determines that the subject exists nearby, maintains the contour detection mode, and the area of the contour image is equal to the predetermined threshold value. If it is equal to or less than THB, it is determined that the subject is located far away, and the mode is shifted to the moving object detection mode.
  • the image sensor 5 executes the same process as the imaging process in the contour detection mode before generating the next moving object detection imaging process to generate a difference image. To do.
  • the MCU 3 determines that the subject is nearby, and shifts to the contour detection mode, where the area of the contour image is equal to the predetermined threshold value THB. In the following cases, it is determined that the subject exists far away, and the moving object detection mode is maintained.
  • FIG. 23 is a diagram showing a detailed electrical configuration of the image processing module 1 of FIG.
  • the image processing module 1 includes a substrate 58. Mounted on the substrate 58 are the MCU 3, the image sensor 5, the infrared light emitting diode 7, the connector 30, the capacitors 31, 32, 34, 36, 40, the resistance elements 38, 48, and the NPN transistor 44.
  • the MCU 3 and the image sensor 5 are connected by a bus 56. Signals and data are transmitted and received between the MCU 3 and the image sensor 5 through the bus 56.
  • the bus 56 includes a signal line for a busy signal (see FIG. 20A to be described later), a signal line for a read signal (see FIG. 20B to be described later), and a data line for pixel data D. (See FIG. 20C described later) and the like.
  • the power supply voltage Vcc is applied from the power supply line 52 to the MCU 3.
  • Three bypass capacitors 34 are connected in parallel between the power supply line 52 and the ground to remove noise.
  • a capacitor 36 connected in parallel is provided to prevent oscillation of a regulator (not shown) provided inside the MCU 3. However, these capacitors 36 may be unnecessary depending on the specifications of the MCU 3.
  • a resistance element 38 and a capacitor 40 are connected in series between the power supply line 52 and the ground to constitute a delay circuit.
  • a connection point between the resistance element 38 and the capacitor 40 is connected to a reset terminal of the MCU 3.
  • the MCU 3 executes a reset process when the potential of the reset terminal becomes low level.
  • the delay circuit prevents the reset terminal from going to high level immediately after the power is turned on, and may be unnecessary depending on the specifications of the MCU 3.
  • the power supply voltage Vcc is applied to the image sensor 5 from the power supply line 52.
  • Two bypass capacitors 31 are connected in parallel between the power supply line 52 and the ground to remove noise.
  • the infrared light emitting diode 7 and the resistance element 48 are connected in series between the power supply line 50 and the ground.
  • the base of the transistor 44 is connected to the control terminal of the image sensor 5. When the control terminal of the image sensor 5 is at a high level, the transistor 44 is turned on, whereby the infrared light emitting diode 7 is turned on to emit infrared light.
  • the transistor 44 when the control terminal of the image sensor 5 is at a low level, the transistor 44 is turned off, whereby the infrared light emitting diode 7 is turned off and the emission of infrared light is stopped.
  • the transistor 44 functions as a switching transistor and amplifies the current flowing through the infrared light emitting diode 7 when it is on.
  • the transistor 44 is not essential, and the anode of the infrared light emitting diode 7 can be directly connected to the control terminal of the image sensor 5.
  • the power supply terminal T1 of the connector 30 (see FIG. 24A described later) is connected to the power supply line 50.
  • a power supply voltage Vcc (for example, 3.3 V) is supplied from the external electronic device 11 to the power supply terminal T ⁇ b> 1 and supplied to the power supply line 50.
  • the power terminal T2 (see FIG. 24A described later) of the connector 30 is connected to the power line 52.
  • a power supply voltage Vcc (for example, 3.3 V) is applied from the external electronic device 11 to the power supply terminal T ⁇ b> 2 and supplied to the power supply line 52.
  • a bypass capacitor 32 is provided between the power supply line 52 and the ground to remove noise.
  • the ground terminal T7 (see FIG. 24A described later) of the connector 30 is connected to the ground.
  • the terminals T3 to T6 of the connector 30 are connected to the signal line 54, and the signal line 54 is connected to the MCU3.
  • the signal line 54 includes four signal lines.
  • One signal line 54 is connected to a terminal T3 of the connector 30 (see FIG. 24A described later).
  • the computer 13 gives a clock signal to the terminal T3 and synchronizes with the MCU3.
  • Another signal line 54 is connected to a terminal T4 of the connector 30 (see FIG. 24A described later).
  • the computer 13 gives a slave select signal to the terminal T4 (see FIG. 22A described later).
  • Still another signal line 54 (that is, a data input line in FIG. 22B described later) is connected to a terminal T5 of the connector 30 (see FIG. 24A described later).
  • Still another signal line 54 (that is, a data output line in FIG. 22C described later) is connected to a terminal T6 of the connector 30 (see FIG. 24A described later).
  • FIG. 24A is a plan view of the image processing module 1 of FIG.
  • FIG. 24B is a side view of the image processing module 1 of FIG.
  • FIG. 24C is an external plan view of the image processing module 1 of FIG.
  • the connector 30 having the terminals T1 to T7, the infrared light emitting diode 7, the MCU 3, and the lens unit 62 are arranged on the substrate 58 in a straight line in this order. Be placed.
  • positioning and order are not limited to this, You may arrange
  • the board 58 on which the connector 30, the infrared light emitting diode 7, the MCU 3, and the lens unit 62 are mounted is disposed in the housing 60.
  • an opening having a trumpet shape is formed in the upper portion of the infrared light emitting diode 7, and the light emitting portion of the infrared light emitting diode 7 is exposed to the outside.
  • only the infrared light is applied to the upper portion of the lens unit 62 so as to cover the opening 66, that is, to cover the head (lens 72) of the cylindrical member 70 (see FIG. 25 described later).
  • a transmitting infrared light filter 64 is provided. Accordingly, only infrared light is incident on the image sensor 5 disposed inside the lens unit 62.
  • the housing 60 is not essential.
  • the infrared light filter 64 creates a dedicated base for holding the infrared light filter 64 and fixes it to the substrate 58.
  • a base 68 shown in FIG. 25 described later may be modified and used as a base for the infrared light filter 64. These fixing methods can be used even when the housing 60 is provided.
  • FIG. 25 is a cross-sectional view taken along line AA of the lens unit 62 in FIG.
  • the lens unit 62 includes a convex lens 72 and a lens holder 73 that holds the convex lens 72.
  • the lens holder 73 includes a base 68 and a cylindrical member 70. The insides of the base 68 and the cylindrical member 70 are hollow. An opening 66 (see FIG. 24A) is formed at the upper end of the head portion of the cylindrical member 70.
  • the cylindrical member 70 holds the lens 72 immediately below the opening 66.
  • a screw thread male screw
  • a screw thread female thread
  • a screw thread female thread
  • a screw thread female thread
  • the inner periphery of the base 68 so as to be able to be screwed with the screw thread of the body portion of the cylindrical member 70.
  • the image sensor 5 is fixed to the substrate 58 inside the base 68 so that the optical axis 74 of the lens 72 passes through the center of the image sensor 5. Then, the cylindrical member 70 is fixed to the base 68 so that the best focus area of the lens 72 comes to the photographing surface of the image sensor 5. Such adjustment is performed by moving the cylindrical member 70 up and down, and the cylindrical member 70 is fixed to the base 68 at an optimal position by an adhesive. Such adjustment is performed to absorb variations in the shape of the lens 72 during manufacturing, variations in fixing the lens 72 to the cylindrical member 70, variations in the image sensor 5 in manufacturing, and the like. .
  • FIG. 2 is a flowchart showing an example of the overall processing flow by the MCU 3 of FIG.
  • MCU 3 initializes registers, variables, and the like. Note that a variable N described later is initialized to 0.
  • step S703 the MCU 3 determines whether or not the falling edge of the slave select signal output from the computer 13 is detected. If not detected, the process returns to step S703, and if detected, the process proceeds to step S705.
  • step S705 the MCU 3 determines whether or not a start command has been received from the computer 13. If not received, the MCU 3 returns to step S705, and if received, advances to step S707.
  • the start command is given through a data input line that connects the MCU 3 and the computer 13. Further, after transmitting the start command to the MCU 3, the computer 13 sets the slave select signal to the high level.
  • step S707 the MCU 3 executes control of the image sensor 5.
  • step S709 the MCU 3 proceeds to step S711 when the image processing mode is the contour detection mode, and proceeds to step S713 when the image processing mode is the moving object detection mode.
  • step S711 the MCU 3 executes contour detection processing.
  • step S713 the MCU 3 executes a moving object detection process.
  • step S714 the MCU 3 determines whether or not the falling edge of the slave select signal is detected. If detected, the process proceeds to step S715. Otherwise, the process returns to step S714.
  • step S715 the MCU 3 determines whether or not a read command is received from the computer 13. If not received, the MCU 3 returns to step S715, and if received, advances to step S717.
  • the read command is given through a data input line that connects the MCU 3 and the computer 13.
  • step S717 the MCU 3 transmits the result of step S711 or S713 to the computer 13.
  • the computer 13 sets the slave select signal to a high level after receiving data from the MCU 3.
  • step S719 the MCU 3 executes image processing mode switching processing, and proceeds to step S707.
  • FIG. 3 is a flowchart showing an example of the control flow of the image sensor 5 in step S707 of FIG.
  • MCU 3 proceeds to step S5 if the current image processing mode is the contour detection mode, and proceeds to step S29 if it is the moving object detection mode.
  • the computer 13 gives the instruction to the MCU 3 at regular time intervals (for example, 1/30 second).
  • step S5 the MCU 3 sets the photographing mode of the image sensor 5 to the differential mode (first photographing mode).
  • step S7 the MCU 3 sets the exposure time ET of the image sensor 5 to a constant value.
  • step S ⁇ b> 9 the MCU 3 instructs the image sensor 5 to turn on the infrared light emitting diode 7. Then, the image sensor 5 turns on the infrared light emitting diode 7, whereby the infrared light emitting diode 7 emits infrared light.
  • step S11 the MCU 3 instructs the image sensor 5 to start exposure (photographing).
  • step S13 the MCU 3 proceeds to step S15 when the exposure time ET is completed, and returns to step S13 when it is not completed.
  • step S15 the MCU 3 instructs the image sensor 5 to end exposure (photographing).
  • step S17 the MCU 3 proceeds to step S19 when the lighting time of the infrared light emitting diode 7 is completed, and returns to step S17 when it is not completed.
  • step S ⁇ b> 19 the MCU 3 instructs the image sensor 5 to turn off the infrared light emitting diode 7. Then, the image sensor 5 turns off the infrared light emitting diode 7, and the infrared light emitting diode 7 thereby stops light emission.
  • step S21 the MCU 3 instructs the image sensor 5 to start exposure (photographing).
  • step S23 the MCU 3 proceeds to step S25 if the exposure time ET has ended, and returns to step S23 if it has not ended.
  • step S25 the MCU 3 instructs the image sensor 5 to end exposure (photographing).
  • step S27 the MCU 3 obtains the difference image data (64 ⁇ 64 pixel data) between the image when the infrared light emitting diode 7 is turned on and the image when the infrared light emitting diode 7 is turned off from the image sensor 5, and sequentially binarizes them.
  • PD [X] [Y] (sometimes referred to as pixel data PD [X] [Y].
  • X 0 to 63
  • Y 0 to 63
  • FIG. 4 is a flowchart showing an example of the flow of the difference image data acquisition process in step S27 of FIG.
  • FIG. 20A to FIG. 20C are explanatory diagrams of signal transmission / reception in the difference image data acquisition process.
  • X 0 to 63
  • Y 0 to 63
  • PD PD [X] [Y].
  • the upper left corner of the rectangular difference image is the origin O
  • the horizontal axis extending rightward from the origin O is the X axis
  • the vertical axis extending downward from the origin O is the Y axis.
  • step S63 the MCU 3 determines whether or not the busy signal from the image sensor 5 (see FIG. 20A) is at a low level, the process proceeds to step S65 if it is low, and returns to step S63 if it is high. .
  • step S65 the MCU 3 sets the read signal (see FIG. 20B) given to the image sensor 5 to a low level.
  • step S67 the MCU 3 reads pixel data D (corresponding to one pixel) of the difference image from the image sensor 5 (see FIG. 20C).
  • step S69 the MCU 3 determines whether or not the predetermined time t0 has elapsed. If it has elapsed, the process proceeds to step S71, and if not, the process returns to step S69.
  • step S71 the MCU 3 sets the read signal (see FIG. 20B) to a high level.
  • step S73 the MCU 3 compares the pixel data D with a predetermined threshold value THA.
  • step S75 the MCU 3 proceeds to step S77 if the pixel data D is larger than the threshold value THA, and proceeds to step S79 if the pixel data D is less than the threshold value THA.
  • step S77 the MCU 3 substitutes “1” (pixel of the subject image) into the array PD [X] [Y].
  • step S79 the MCU 3 substitutes “0” (background pixel) for the array PD [X] [Y]. In this way, each pixel of the difference image from the image sensor 5 is sequentially binarized.
  • step S81 the MCU 3 increments the variable X by one.
  • step S83 the MCU 3 determines whether or not the value of the variable X has reached 64, the process proceeds to step S85 if 64, otherwise the process proceeds to step S89.
  • step S85 the MCU 3 increments the variable Y by one.
  • step S87 the MCU 3 determines whether or not the value of the variable Y has become 64. If 64, all the pixels have been read and the process returns, otherwise the process proceeds to step S89.
  • step S89 the MCU 3 proceeds to step S61 when the rising edge of the busy signal (see FIG. 20A) is detected, otherwise returns to step S89.
  • the MCU 3 sequentially binarizes each time a pixel is read to obtain binarized difference image data.
  • step S29 the MCU 3 sets the shooting mode of the image sensor 5 to the standard mode (second shooting mode).
  • step S ⁇ b> 31 the MCU 3 instructs the image sensor 5 to turn off the infrared light emitting diode 7. Then, the image sensor 5 turns off the infrared light emitting diode 7, and the infrared light emitting diode 7 thereby stops light emission.
  • step S33 the MCU 3 instructs the image sensor 5 to start exposure (photographing).
  • step S35 the MCU 3 proceeds to step S37 if the exposure time ET has ended, and returns to step S35 if it has not ended.
  • step S37 the MCU 3 instructs the image sensor 5 to end exposure (photographing).
  • the image data acquisition process in step S39 is the same as the difference image data acquisition process in FIG. However, instead of the processing in steps S73 to S79 in FIG. 4, the pixel data D from the image sensor 5 is stored in the array PS [X] [Y] as it is without being binarized.
  • the difference image is read as an image
  • the array PD [X] [Y] is read as an array PS [X] [Y].
  • the upper left corner of the rectangular image is the origin O
  • the horizontal axis extending rightward from the origin O is the X axis
  • the vertical axis extending downward from the origin O is the Y axis.
  • step S41 the MCU 3 calculates an average value of the pixel data PS [X] [Y].
  • step S43 the MCU 3 sets the exposure time ET of the image sensor 5 to a value corresponding to the average value obtained in step S41. Since the pixel data PS [X] [Y] is a luminance value, the average value is an index representing the brightness of the shooting space (the space to be shot). Therefore, the image sensor 5 sets the exposure time ET shorter as the average value is larger and the photographing space is brighter, and the exposure time ET is set longer as the average value is smaller and the photographing space is darker. Thus, in the moving object detection mode, the exposure time ET in step S35 is dynamically set according to the brightness of the shooting space.
  • step S44 the MCU 3 increments the variable N by one.
  • step S45 the MCU 3 determines whether or not the value of the variable N has become 3. If the value is 3, the process proceeds to step S5 in order to perform shooting processing for switching the image processing mode. Will return. That is, in the moving object detection mode, the period of the imaging process for switching the image processing mode is three times the period of the imaging process for contour detection in the contour detection mode and moving object detection in the moving object detection mode. Set long. Therefore, power consumption can be suppressed. Note that the computer 13 can also issue a shooting processing instruction for switching the image processing mode in the moving object detection mode.
  • the difference image data in step S27 which is the result of steps S5 to S25 after the positive evaluation (YES) in step S45, is used only for switching determination of the image processing mode (see FIG. 5).
  • FIG. 5 is a flowchart showing an example of the flow of image processing mode switching processing by the MCU 3 of FIG.
  • MCU 3 proceeds to step S101 if the current image processing mode is the contour detection mode, and proceeds to step S100 if it is the moving object detection mode.
  • step S100 the MCU 3 determines whether or not the value of the variable N is 3, the process proceeds to step S101 if the value is 3, and otherwise the process returns.
  • step S101 the MCU 3 substitutes 0 for the variables X, Y, and A.
  • step S103 the MCU 3 determines whether or not the pixel data PD [X] [Y] of the difference image is “1”. If “1”, the MCU 3 proceeds to step S105, and if “0”, the MCU 3 proceeds to step S107. .
  • step S105 the MCU 3 increments the variable A by one.
  • step S107 the MCU 3 increments the variable X by one.
  • step S109 the MCU 3 determines whether or not the value of the variable X has become 64. If 64, the process proceeds to step S111. Otherwise, the process returns to step S103.
  • step S111 the MCU 3 increments the variable Y by one.
  • step S113 the MCU 3 determines whether or not the value of the variable Y has become 64. If 64, the process proceeds to step S115, otherwise the process returns to step S103.
  • step S115 the MCU 3 determines whether or not the value of the variable A indicating the area of the image of the subject in the difference image is larger than a predetermined threshold value THB, the process proceeds to step S117 if it is greater, and if not, The process proceeds to step S119.
  • step S117 the MCU 3 determines that the subject exists at a short distance, and sets the image processing mode to the contour detection mode.
  • step S118 the MCU 3 substitutes 0 for the variable N in FIG. 3, and proceeds to step S101.
  • step S119 the MCU 3 determines that the subject exists at a long distance, sets the image processing mode to the moving object detection mode, and proceeds to step S101.
  • FIG. 6 is a flowchart showing an example of a process flow in the moving object detection mode by the MCU 3 of FIG.
  • MCU 3 substitutes 0 for variables k, X, Y, AX, AY, TX, TY, and S [X] [Y].
  • the MCU 3 turns off the moving object flag.
  • the moving object flag is a flag that is turned on when a moving object is detected.
  • step S145 the MCU 3 calculates a difference value DIF between the pixel value PS [X] [Y] of the current image and the pixel value PS [X] [Y] of the previously acquired image.
  • step S147 the MCU 3 determines whether or not the difference value DIF is larger than a predetermined threshold value THC. If it is larger, the process proceeds to step S149, and if smaller, the process proceeds to step S151.
  • step S149 the MCU 3 adds a constant value IC (> 0) to the current value of the variable S [X] [Y], and substitutes it for the variable S [X] [Y].
  • step S151 the MCU 3 subtracts a constant value DC (> 0) from the current value of the variable S [X] [Y], and substitutes it for the variable S [X] [Y]. In this case, DC ⁇ IC.
  • step S153 the MCU 3 determines whether or not the value of the variable S [X] [Y] is smaller than the threshold value THH and larger than the threshold value THL, and in the case of an affirmative determination, the pixel value PS [X] [ It is determined that the change in Y] is valid, and the process proceeds to step S155. If the determination is negative, the change in pixel value PS [X] [Y] is determined to be invalid (noise), and the process proceeds to step S161.
  • the value of the variable S [X] [Y] is an index indicating the frequency of change of the corresponding pixel value PS [X] [Y]. The larger the value, the higher the change frequency, and the smaller the value, the more the change. Is less frequent.
  • step S155 the MCU 3 turns on the moving object flag.
  • step S157 the MCU 3 increments the variable k by one.
  • the variable k indicates the number of pixels for which it is determined that the change in the pixel value PS [X] [Y] is effective.
  • step S159 the MCU 3 adds the value of the variable X to the current value of the variable AX and substitutes it for the variable AX. Further, the MCU 3 adds the value of the variable Y to the current value of the variable AY and substitutes it for the variable AY.
  • step S161 the MCU 3 increments the variable X by one.
  • step S163 the MCU 3 determines whether or not the value of the variable X has become 64, the process proceeds to step S165 if 64, otherwise the process proceeds to step S145.
  • step S165 the MCU 3 increments the variable Y by one.
  • step S167 the MCU 3 determines whether or not the value of the variable Y has become 64, the process proceeds to step S169 if 64, otherwise the process proceeds to step S145.
  • step S169 the MCU 3 stores the value obtained by dividing the value of the variable AX by the value of the variable k in the variable TX, and stores the value obtained by dividing the value of the variable AY by the value of the variable k in the variable TY.
  • the coordinates (TX, TY) are the coordinates of the moving object image included in the image from the image sensor 5.
  • step S171 the MCU 3 obtains the total value of the pixel values PS [X] [Y] and divides this by the exposure time ET of the image sensor 5 (step S43 in FIG. 3), thereby reducing the luminance of the shooting space. Ask. Then, the MCU 3 returns.
  • the MCU 3 transmits the moving object flag, the coordinates of the moving object (TX, TY), and the luminance of the imaging space to the computer 13 of the electronic device 11.
  • FIG. 7 is a flowchart showing an example of a processing flow in the contour detection mode by the MCU 3 of FIG.
  • MCU 3 extracts the contour line of the subject image from the difference image data (PD [X] [Y]).
  • the value J indicates the total number of pixels Pj on the contour line. Further, it is assumed that the contour line extraction process is executed counterclockwise.
  • a well-known algorithm can be used for extracting the contour line. For example, in a method using a mask made up of 3 ⁇ 3 small pixel regions, the mask is sequentially moved to extract the contour line, although the center of the mask is always kept on the contour line.
  • step S193 the MCU 3 calculates the argument ⁇ j of the vector Vj of each pixel Pj on the extracted contour line.
  • FIG. 16 is an explanatory diagram of the deviation angle ⁇ j detected in step S193 of FIG.
  • a vector Vj of the pixel Pj is defined as a vector from the pixel Pj toward the next pixel Pj + 1.
  • the deflection angle ⁇ j of the vector Vj of the pixel Pj is defined as an angle formed by the vector Vj with respect to the vector Vj ⁇ 1 of the pixel Pj ⁇ 1 immediately before the pixel Pj.
  • the sign of the counterclockwise deflection angle ⁇ j is positive, and the sign of the clockwise deflection angle ⁇ j is negative.
  • the MCU 3 detects the inflection point of the extracted contour line.
  • the inflection point is a point where the direction of the outline changes, and a convex point and a concave point are defined.
  • FIG. 17 is an explanatory diagram of the inflection point detected in step S195 of FIG.
  • inflection points I0 to I8 are given as points at which the direction of the extracted outline 21 changes.
  • Inflection points I0, I2, I4, I6 and I8 are convex points.
  • Inflection points I1, I3, I5 and I7 are concave points.
  • step S197 the MCU 3 determines the shape of the extracted contour line (contour image) (goo, choki, par, indefinite).
  • step S199 the MCU 3 detects the rotation of the extracted contour line (contour image) and returns.
  • step S717 of FIG. 2 the MCU 3 displays the results of steps S191 to S199 (the center of gravity coordinates, area, shape, rotation angle, and rotation direction of the contour image) of the computer 13 of the electronic device 11. Send to.
  • FIG. 8 is a flowchart showing an example of the flow of the inflection point detection process in step S195 of FIG.
  • MCU 3 assigns 0 to variables DA, ADA, j, and CF [j].
  • the MCU 3 acquires from the memory 9 the deviation angle ⁇ j of the pixel Pj on the contour detected in step S193 in FIG.
  • the MCU 3 adds the deflection angle ⁇ j to the current value of the variable DA and substitutes it for the variable DA.
  • the MCU 3 obtains the absolute value of the variable DA and assigns it to the variable ADA.
  • step S229 the MCU 3 determines whether or not the value of the variable ADA has become 135 degrees. If the value is 135 degrees, the MCU 3 determines that the direction of the contour has changed, regards the pixel Pj as an inflection point, and performs step S231. Otherwise, the process proceeds to step S237.
  • step S231 the MCU 3 determines whether or not the sign of the variable DA is positive. If it is positive, the process proceeds to step S233, and if negative, the process proceeds to step S235.
  • step S233 the MCU 3 assigns 01 indicating that the inflection point is a convex point to the convex / concave flag CF [j]. On the other hand, in step S235, the MCU 3 substitutes 10 indicating that the inflection point is a concave point.
  • step S236 the MCU 3 substitutes 0 for the variable DA.
  • step S237 the MCU 3 increments the variable j by one.
  • FIG. 9 is a flowchart showing an example of the flow of processing for determining the shape of the contour image in step S197 in FIG.
  • the MCU 3 calculates information related to the contour line.
  • the MCU 3 detects a pixel corresponding to the fingertip of the hand from the contour image.
  • the MCU 3 obtains a line segment 23 that connects two pixels located a certain number of pixels Np away from the convex point As, and calculates the length Lv of the perpendicular line 25 drawn from the convex point As to the line segment 23. When the length Lv exceeds the predetermined value CL, the MCU 3 sets the convex point As as a candidate for the fingertip.
  • the MCU 3 determines whether or not the concave point Bt exists on both sides or one side of the convex point As that is a fingertip candidate, and if it exists, regards the convex point As as the fingertip.
  • the MCU 3 calculates the tilt angle ⁇ v necessary for determining “par” and “goo”.
  • the inclination angle ⁇ v is an angle formed by a perpendicular line 25 drawn from the convex point As regarded as the fingertip to the line segment 23 with a line 27 parallel to the X axis of the difference image.
  • step S ⁇ b> 265 the MCU 3 determines whether or not the shape of the contour image is a “par” hand shape.
  • step S 267 the MCU 3 determines whether or not the shape of the contour image is the shape of a hand that has been “stiff”.
  • step S269 the MCU 3 determines whether or not the shape of the contour image is a “goo” hand shape, and then returns.
  • FIG. 10 is a flowchart showing an example of the processing flow for calculating the contour information in step S261 of FIG.
  • MCU 3 substitutes 0 for variables XG, YG, and j.
  • the MCU 3 substitutes the variable XG for the value obtained by adding the X coordinate XO [j] of the pixel Pj on the contour line to the current value of the variable XG.
  • the MCU 3 substitutes the variable XG for the value obtained by adding the Y coordinate YO [j] of the pixel Pj on the contour line to the current value of the variable YG.
  • the MCU 3 increments the variable j by one.
  • the MCU 3 determines whether or not the value of the variable j has become the value J. If the value has become the value J, the MCU 3 proceeds to step S299, otherwise proceeds to step S293.
  • step S299 the MCU 3 substitutes the value of the variable XG divided by the value J for the variable Xg. Further, the MCU 3 substitutes the value of the variable YG divided by the value J for the variable Yg.
  • the coordinates (Xg, Yg) indicate the barycentric coordinates of the contour image.
  • step S301 the MCU 3 substitutes 0 for the variables j, LS, and L [j].
  • step S303 the MCU 3 calculates a distance L [j] between the barycentric coordinates (Xg, Yg) and the coordinates (XO [j], YO [j]) of each pixel Pj on the contour line by the following equation. To do.
  • step S305 the MCU 3 substitutes the variable LS for a value obtained by adding the value of the variable L [j] to the current value of the variable LS.
  • step S307 the MCU 3 determines that the line segment connecting the barycentric coordinates (Xg, Yg) and the pixel Pj coordinates (XO [j], YO [j]) on the contour line is parallel to the X axis according to the following equation. And the inclination angle ⁇ c [j] is calculated. In this case, the angle after the decimal point is rounded down.
  • step S309 the MCU 3 creates a rotation table based on the tilt angle ⁇ c [j] and the distance L [j].
  • FIG. 18 is a view showing an example of the rotation table created in step S309 of FIG. Referring to FIG. 18, the MCU 3 creates a rotation table by associating the inclination angle ⁇ c [j] of the pixel Pj on the contour line with the distance L [j].
  • step S311 the MCU 3 increments the variable j by one.
  • step S313 the MCU 3 determines whether or not the value of the variable j has become the value J. If the value has become the value J, the process proceeds to step S315, otherwise the process proceeds to step S303.
  • step S315 the MCU 3 calculates the average value AVL of the distance L [j] by dividing the value of the variable LS by the value J.
  • step S317 the MCU 3 counts the contour line and the pixels in the contour line, and calculates the area of the contour image.
  • step S319 the MCU 3 completes the rotation table of FIG. 18 by linear interpolation.
  • the tilt angle ⁇ c [j] calculated in step S307 and the distance L [j] calculated in step S303 are substituted into the rotary table, but all the tilt angle and distance columns of the rotary table are necessarily filled. Do not mean. Therefore, when there is a blank in the rotary table, the blank is filled by linear interpolation using the distance before and after the blank. Note that linear interpolation is an example, and other interpolations can be performed.
  • FIG. 11 is a flowchart showing an example of the processing flow for detecting the fingertip in step S263 of FIG.
  • MCU 3 assigns 0 to variable j and FP [j].
  • step S343 the MCU 3 determines whether or not the flag CF [j] is set to 01 indicating a convex point. If the determination is affirmative, the process proceeds to step S345. If the determination is negative, the process proceeds to step S349.
  • step S345 the MCU 3 determines whether or not there is a pixel in which 10 indicating a concave point is set in the flag CF [j] on both sides or one side of the pixel Pj that is a convex point. If the case pixel Pj is regarded as a fingertip candidate, the process proceeds to step S347, and if not, the process proceeds to step S349. In step S347, the MCU 3 sets 1 indicating that the pixel Pj is a fingertip candidate to the flag FP [j].
  • step S349 the MCU 3 increments the variable j by one.
  • step S351 the MCU 3 determines whether or not the value of the variable j has become the value J. If it becomes the value J, the MCU 3 proceeds to step S353, and otherwise proceeds to step S343.
  • step S353 the MCU 3 substitutes 0 for variables j, q, TF [j], ⁇ v [q], XT, YT, Q, and ⁇ v.
  • step S355 the MCU 3 determines whether or not 1 indicating a fingertip candidate is set in the flag FP [j]. If the determination is affirmative, the process proceeds to step S357. Otherwise, the process proceeds to step S371.
  • step S357 the MCU 3 calculates the length Lv of the perpendicular 25 drawn from the pixel Pj to the line segment 23 connecting the pixel Pj + Np and the pixel Pj ⁇ Np (see FIG. 17).
  • step S359 the MCU 3 determines whether or not the length Lv exceeds the predetermined value CL. If the length Lv exceeds the value, the MCU 3 regards the pixel Pj as a fingertip and proceeds to step S361. Otherwise, the process proceeds to step S371.
  • step S361 the MCU 3 sets 1 indicating that the pixel Pj is the fingertip to the fingertip flag TF [j].
  • step S363 the MCU 3 substitutes the X coordinate of the pixel Pj for the variable XT [q]. Further, the MCU 3 substitutes the Y coordinate of the pixel Pj for the variable YT [q].
  • the coordinates (XT [q], YT [q]) are the coordinates of the fingertip.
  • step S365 the MCU 3 calculates the inclination angle ⁇ v of the perpendicular 25 (see FIG. 17).
  • step S367 the MCU 3 substitutes the tilt angle ⁇ v for the variable ⁇ v [q].
  • the tilt angle ⁇ v [q] is the tilt angle of the finger corresponding to the fingertip indicated by the coordinates (XT [q], YT [q]).
  • step S369 the MCU 3 increments the variable q by one.
  • step S371 the MCU 3 increments the variable j by one.
  • step S373 the MCU 3 determines whether or not the value of the variable j has become the value J. If the value has become the value J, the process proceeds to step S375. Otherwise, the process proceeds to step S355.
  • step S375 the MCU 3 assigns the value of the variable q to the variable Q and returns.
  • the value of variable Q represents the number of detected fingertips.
  • FIG. 12 is a flowchart showing an example of a process flow for determining “par” in step S265 of FIG.
  • the MCU 3 determines whether or not the value of the variable Q (number of fingertips) is 3 or more, the process proceeds to step S403 if it is 3 or more, otherwise the process returns.
  • the MCU 3 substitutes 0 for the variables q and m.
  • the MCU 3 calculates the absolute value of the difference between the array ⁇ v [q] and the array ⁇ v [q + 1] and substitutes it in the variable ⁇ d.
  • the variable ⁇ d represents the angle formed between adjacent fingers.
  • step S407 the MCU 3 determines whether or not the value of the variable ⁇ d is less than 100 degrees. If the determination is affirmative, the process proceeds to step S409. If the determination is negative, the process proceeds to step S411. In step S409, the MCU 3 increments the variable m by one. In step S411, the MCU 3 increments the variable q by one.
  • step S413 the MCU 3 determines whether or not the value of the variable q has become the value Q. If the value has become the value Q, the process proceeds to step S415. Otherwise, the process proceeds to step S405.
  • step S415 the MCU 3 determines whether the value of the variable m is 6 or less and 3 or more. If the determination is affirmative, the MCU 3 determines that the hand shape is “par” and proceeds to step S417. Return in case of judgment.
  • the value of the variable m is the number of occurrences of the case where the angle ⁇ d formed by the adjacent fingers is less than 100 degrees.
  • step S417 the MCU 3 sets the flag SH to 01 indicating “par”, and proceeds to step S199 in FIG.
  • FIG. 13 is a flowchart illustrating an example of a flow of processing for determining “pick” in step S267 of FIG. Referring to FIG. 13, in step S441, MCU 3 proceeds to step S443 if the value of variable Q (number of fingertips) is 2 or 3, and otherwise returns.
  • step S443 the MCU 3 substitutes 0 for the variables q, p, and SH.
  • step S445 the MCU 3 calculates a distance Lgt0 between the center-of-gravity coordinates (Xg, Yg) of the contour image and the coordinates of the fingertip (XT [q], YT [q]).
  • step S447 the MCU 3 determines whether or not the distance Lgt0 is equal to or greater than the average value AVL (see step S315 in FIG. 10) multiplied by 1.1, that is, the distance Lgt0 is 110% or more of the average value AVL. If the determination is affirmative, the process proceeds to step S449. If the determination is negative, the process proceeds to step S459.
  • step S449 the MCU 3 calculates a distance Lgt10 between the center-of-gravity coordinates (Xg, Yg) of the contour image and the coordinates of the fingertip (XT [q + 1], YT [q + 1]).
  • the fingertip of coordinates (XT [q + 1], YT [q + 1]) is the fingertip next to the fingertip of coordinates (XT [q], YT [q]).
  • step S451 the MCU 3 determines whether or not the distance Lgt1 is greater than or equal to the value AVL multiplied by 1.1, that is, determines whether or not the distance Lgt1 is 110% or more of the average value AVL. In the case of determination, the process proceeds to step S453, and in the case of negative determination, the process proceeds to step S459.
  • step S453 the MCU 3 calculates the absolute value of the difference between the array ⁇ v [q] and the array ⁇ v [q + 1] (that is, the angle formed between the adjacent fingers) and substitutes it in the variable ⁇ d.
  • step S455 the MCU 3 determines whether or not the value of the variable ⁇ d is less than 90 degrees. If the determination is affirmative, the process proceeds to step S457. If the determination is negative, the process proceeds to step S459. In step S457, the MCU 3 increments the variable p by one.
  • step S459 the MCU 3 increments the variable q by one.
  • step S461 the MCU 3 determines whether or not the value of the variable q has become the value Q. If the value has become the value Q, the process proceeds to step S463, otherwise the process proceeds to step S445.
  • step S463 the MCU 3 determines that the shape of the hand is “choke” when the value of the variable p is 1 or 2, proceeds to step S465, and returns otherwise.
  • step S465 the MCU 3 sets the flag SH to “10” indicating “pick”, and proceeds to step S199 in FIG.
  • FIG. 14 is a flowchart showing an example of the flow of processing for determining “go” in step S269 of FIG.
  • MCU 3 determines whether or not the value of variable Q (number of fingertips) is 2 or more, and proceeds to step S493 in the case of a positive determination, and in the case of a negative determination. The process proceeds to step S503.
  • step S493 the MCU 3 substitutes 0 for the variable j.
  • step S495 the MCU 3 determines that the distance L [j] (see step S303 in FIG. 10) is equal to or greater than the average value AVL (see step S315 in FIG. 10) multiplied by 0.6, and the value AVL. Whether or not the distance L [j] is 60% or more of the average value AVL and 140% or less of the average value AVL. If the determination is affirmative, the process proceeds to step S497. If the determination is negative, the process proceeds to step S503.
  • step S499 the MCU 3 determines whether or not the value of the variable j has become the value J. If the value J has reached the value J, the hand shape is determined to be “goo”, and the process proceeds to step S501. Otherwise, the process proceeds to step S495. Proceed to In step S501, the MCU 3 sets the flag SH to 11 indicating “Goo” and returns. On the other hand, in step S503, the MCU 3 sets the flag SH to 00 indicating “indefinite” and returns.
  • FIG. 15 is a flowchart showing an example of the flow of processing for detecting the rotation of the contour image in step S199 of FIG. Referring to FIG. 15, in step S521, MCU 3 substitutes 0 for variable M and substitutes FFFFh for variable RA.
  • step S523 the MCU 3 obtains a distance corresponding to an inclination angle of M degrees from the current rotation table (see FIG. 18).
  • step S525 a distance corresponding to a tilt angle of 0 degree is acquired from the previous rotation table (see FIG. 18).
  • step S527 if the absolute value of the difference between the distance acquired in step S523 and the distance acquired in step S525 is within a certain range, the MCU 3 regards the two as matching and proceeds to step S529. Otherwise, the process proceeds to step S531 (see FIG. 19).
  • step S529 the MCU 3 substitutes the value of the variable M for the variable RA.
  • step S531 the MCU 3 obtains a distance corresponding to a tilt angle of (360-M) degrees from the current rotation table (see FIG. 18).
  • step S533 a distance corresponding to a tilt angle of 0 degree is acquired from the previous rotation table (see FIG. 18).
  • step S535 if the absolute value of the difference between the distance acquired in step S531 and the distance acquired in step S533 is within a certain range, the MCU 3 regards the two as matching and proceeds to step S537. Otherwise, the process proceeds to step S539.
  • step S537 the MCU 3 substitutes a value obtained by multiplying the value of the variable M by ( ⁇ 1) for the variable RA.
  • step S539 the MCU 3 increments the variable M by one.
  • step S561 the MCU 3 determines whether or not the variable RA value is FFFFh, the process proceeds to step S563 if the determination is affirmative, and returns if the determination is negative.
  • step S563 the MCU 3 determines whether or not the value of the variable M has reached 360 (the number of tilts stored in the rotation table). If 360, the process returns, otherwise the process proceeds to step S523. .
  • the value of the variable RA is the length L [j] of the line segment connecting the barycentric coordinates of the contour image of the subject and the pixel Pj on the contour line.
  • This is a phase difference between the current time and the previous time when expressed as functions 100 and 102 of an angle ⁇ c [j] made with respect to a line (a line parallel to the X axis).
  • the absolute value of this phase difference represents the rotation angle of the contour image, and the sign of this phase difference represents the rotation direction.
  • processing in steps S523 and S525 means that the rotation table is processed (scanned) from the upper column to the lower column.
  • the processing in steps S531 and S533 means that the rotation table is processed (scanned) from the lower column to the upper column. Then, in the bidirectional scanning, the phase difference when the current distance quickly coincides with the previous distance is used as the rotation angle of the contour image.
  • the image processing mode can be switched according to the distance between the subject and the image sensor 5, the image processing is automatically changed according to the distance. Can be made.
  • a relatively low resolution image sensor 5 can be adopted, and the cost can be reduced.
  • a relatively distant subject even if the resolution is low, detailed analysis of the subject can be performed by image processing, and sufficiently practical results can be obtained.
  • sufficiently practical results can be obtained even with a low resolution by subjecting a relatively distant subject to different image processing than when the subject is nearby. In this way, by varying the image processing according to the distance, the low-resolution image sensor 5 can handle both near and far subjects.
  • the contour detection mode that is image processing for a short distance
  • processing for recognizing the form of the subject is performed. It is possible to recognize the form even from a relatively low resolution image. Even if the same image processing as that in the contour detection mode is performed in the image processing mode for a long distance, it is difficult to accurately recognize the form of the subject from the low-resolution image.
  • a moving object is detected by a method different from the contour detection process (FIG. 6). Detection of moving objects by this method is sufficiently possible even from a relatively low resolution image. As a result, since the image sensor 5 having a relatively low resolution can be employed in both near and far, the cost can be reduced.
  • both near and far image processing can be performed with only one image processing module 1.
  • a sensor for recognizing the form of a subject at a short distance and a sensor (moving body sensor) for detecting a moving object at a long distance are provided.
  • a relatively high-resolution imaging device is usually employed as the form sensor, which is more expensive than a low-resolution imaging device.
  • the control device (CPU or the like) of the high-resolution photographing apparatus becomes expensive.
  • the amount of processing increases in a high-resolution image, and it becomes difficult to cope with a case where an output result is requested at high speed.
  • a pyroelectric sensor is usually employed as the moving body sensor.
  • the pyroelectric sensor may be cheaper than a relatively low-resolution imaging device, it detects a change in room temperature, so that the occurrence of the change can be detected, but the coordinates of the object cannot be detected.
  • the pyroelectric sensor cannot detect the presence of an object when the object is detected and then the object does not move.
  • the present embodiment it is possible to track a moving object and perform processing or control targeting the moving object.
  • a part or all of the electronic device can be controlled to always face the moving object in response to the tracking result of the moving object.
  • processing is also possible in the contour detection mode.
  • the movement of the pixel value changes frequently, for example, a relatively relatively periodic frequency such as television flickering. High motion can be removed as noise.
  • the second threshold value THL (see step S153 in FIG. 6) is provided, an image generated due to a motion with a low frequency of change in pixel value, for example, a change in the shooting environment (the shooting space or the state of the image sensor 5). The above noise can be removed.
  • the electronic device 11 can execute information processing using the shape of the subject (goo, choki, par) as an input in the contour detection mode.
  • the finger is specified based on the pixel between the fingertip and the web (see steps S357 and S359 in FIG. 11 and FIG. 17), and the finger is not specified by the center of gravity of the contour image.
  • the finger can be specified with high accuracy (FIG. 11), and the shape of the hand can be determined with higher accuracy (FIGS. 12, 13).
  • the center of gravity of the contour image and the center of gravity of the subject often do not match. In this case, if a finger is specified by the center of gravity, the accuracy of recognition is lowered.
  • the shape of the hand is determined based on the distance from the center of gravity to the pixel corresponding to the fingertip, as well as the angle between the adjacent finger and the finger obtained based on the pixel between the fingertip and the web. Therefore (steps S445 to S451 in FIG. 13), more various hand shapes can be determined (FIG. 13). For example, it can be determined that the shape of the hand is “pick”.
  • the shape of the hand can be determined (FIG. 14) by simple calculation such as obtaining the distance from the center of gravity to the pixel on the contour line (step S303 in FIG. 10). For example, when the distance from the center of gravity to the pixel on the contour line is within a certain range, it can be determined that the shape of the hand is “Goo”.
  • the electronic device 11 can execute information processing using the rotation of the subject (see FIG. 15) as an input in the contour detection mode.
  • the length L [j] of the line segment connecting the barycentric coordinates of the contour image of the subject and the pixel Pj on the contour line is set to a predetermined reference line (a line parallel to the X axis). ),
  • the rotation angle of the hand can be detected easily and accurately by calculating the phase difference between the current time and the previous time as a function of the angle ⁇ c [j].
  • the distance between the image sensor 5 and the subject can be easily determined based on the area.
  • the light from the infrared light emitting diode 7 does not reach, or the reflected light is weak and is not detected by the image sensor 5 even if it reaches, so regardless of whether the infrared light emitting diode 7 emits light or turns off. , Distant objects do not appear in the captured image.
  • a nearby object reflects the light and appears in the photographed image. Therefore, since the background component is removed by the difference, only the object that reflects the light irradiated by the infrared light emitting diode 7 appears in the difference image. In this way, only an image of a nearby object can be extracted by a simple process such as difference.
  • the infrared light emitting diode 7 is not required to emit light, but the infrared light emitting diode 7 required in the image processing (contour detection processing) in the contour detection mode is imaged. Shared in motion detection mode for switching processing modes. As a result, cost can be reduced.
  • the imaging cycle for switching the image processing mode in the moving object detection mode is shorter than the imaging process cycle for the contour detection in the contour detection mode and the moving object detection in the motion detection mode. Can be suppressed.
  • the determination for switching the image processing mode does not need to be performed in the same period as the image processing (contour detection and moving object detection), and does not substantially affect the performance.
  • the captured image of the subject is processed (in the contour detection mode, the center of gravity coordinates, area, shape, rotation angle, and rotation direction of the contour image are calculated, and in the moving object detection mode, the moving object is detected.
  • Detection moving object flag
  • calculation of coordinates (TX, TY) of moving object, and calculation of luminance of photographing space) are output to the computer 13 of the electronic device 11. Therefore, the external computer 13 can use the processing result input from the image processing module 1 as it is.
  • image processing by the external computer 13 is not required, and the burden on the programmer of the computer 13 can be reduced.
  • the image processing module 1 is provided as a module that performs only photographing and image processing, the computer 13 that uses the processing result or the external device 11 that includes the computer 13 is not limited to a specific one.
  • the image processing module 1 has high versatility.
  • the setting of the MCU 3 is fixed to the contour detection mode.
  • the MCU 3 outputs an interrupt signal to the computer 13.
  • the MCU 3 cannot transmit data to the computer 13 without an instruction from the computer 13.
  • the MCU 3 transmits an interrupt signal to the computer 13 when the contour image satisfies the interrupt condition. For this reason, the computer 13 in the standby state or the sleep state can be brought into an operation state or returned by an interrupt signal from the MCU 3.
  • FIG. 21 is a flowchart showing an example of the overall processing flow of the MCU 3 in the modification of the embodiment of the present invention.
  • FIG. 22A to FIG. 22C are explanatory diagrams of signal transmission / reception between the MCU 3 and the computer 13 in a modified example.
  • step S751 MCU 3 executes initialization of registers and variables.
  • step S753 the MCU 3 sets the potential of the data output line to a high level (see FIG. 22C). This data output line connects the MCU 3 and the computer 13.
  • step S755 the MCU 3 sets a timer in order to generate a timer interrupt at regular time intervals.
  • step S757 the MCU 3 determines whether or not the falling edge of the slave select signal output from the computer 13 is detected. If detected, the process proceeds to step S761. Otherwise, the process proceeds to step S759. In step S759, the MCU 3 determines whether or not a timer interrupt has occurred. If it has occurred, the process proceeds to step S765. Otherwise, the process returns to step S757.
  • step S761 the MCU 3 releases the timer.
  • step S763 the MCU 3 determines whether or not a start command is received from the computer 13. If received, the process proceeds to step S765. Otherwise, the process returns to step S763.
  • the computer 13 sets the slave select signal to the high level after transmitting the start command to the MCU 3.
  • step S765 the MCU 3 controls the image sensor 5.
  • the processing in this case is the same as the processing in steps S7 to S27 in FIG.
  • step S767 the MCU 3 executes contour detection processing. This process is the same as the contour detection process in step S711 in FIG.
  • step S771 the MCU 3 determines whether or not the contour image detected in step S767 satisfies the set interrupt condition. If satisfied, the process proceeds to step S773. If not satisfied, the MCU 3 proceeds to step S773. The process proceeds to S775. In step S ⁇ b> 773, the MCU 3 outputs an interrupt signal to the computer 13. However, in this case, the MCU 3 can also output a command to the computer 13.
  • This interrupt condition is preset in a register (not shown) of MCU3. Of course, the interrupt condition can be changed by the computer 13. In this embodiment, an interrupt condition for generating an interrupt signal only when the contour image is “Goo”, an interrupt condition for generating an interrupt signal only when the contour image is “Cho”, and the contour image is “Par”.
  • Interrupt conditions that generate an interrupt signal only when the contour image is “Goo” or “Che” Interrupt conditions that generate an interrupt signal when the contour image is "Goo” or “Par”
  • An interrupt condition for generating an interrupt signal, an interrupt condition for generating an interrupt signal when the contour image is “Cho” or “Par”, and a interrupt when the contour image is “Goo”, “Choki” or “Par” It is possible to set an interrupt condition for generating an interrupt signal and an interrupt condition for generating no interrupt signal when the contour image is “GOO”, “CHOKI”, or “PAR”.
  • step S775 the MCU 3 sets the potential of the data output line to the low level (see FIG. 22C).
  • step S777 the MCU 3 determines whether or not the falling edge of the slave select signal (see FIG. 22A) output from the computer 13 has been detected. If detected, the process proceeds to step S781, and has not been detected. If yes, go to Step S779.
  • step S779 the MCU 3 proceeds to step S791 if there is a timer interrupt, otherwise proceeds to step S777.
  • step S781 the MCU 3 releases the timer.
  • step S783 the MCU 3 determines whether or not a start command has been received from the computer 13, and if received, proceeds to step S789, otherwise proceeds to step S785.
  • the computer 13 sets the slave select signal to the high level after transmitting the start command to the MCU 3.
  • step S785 the MCU 3 determines whether or not a read command (see FIG. 22B) from the computer 13 has been received. If received, the process proceeds to step S787, and if not received, the process returns to step S783.
  • the read command is given through a data input line that connects the MCU 3 and the computer 13.
  • step S787 the MCU 3 transmits the result data (centroid coordinates, area, shape, and rotation angle of the contour image) of step S767 to the computer 13 via the data output line (see FIG. 22C).
  • the computer 13 sets the slave select signal to a high level after receiving data from the MCU 3.
  • step S789 the MCU 3 sets a timer.
  • step S791 the MCU 3 sets the potential of the data output line to the high level (see FIG. 22C), and returns to step S765.
  • the MCU 3 when the computer 13 is in the operation state, the MCU 3 operates under the control of the computer 13 (slave select signal, start command, and read command). However, when the computer 13 is in the standby or sleep state, the MCU 3 controls the image sensor 5 (step S765), contour detection processing (step S767), and interrupt signal generation processing (steps S771 and S773) by timer interruption. ).
  • the contour image, that is, the photographing object (“hand” in the modified example) is an interrupt condition.
  • the computer 13 can be put into an operation state or returned. That is, by controlling the object to be photographed (in the above example, the user matches the shape of the hand with the interrupt condition), the computer 13 in the standby state or the sleep state can be put into an operation state or returned. it can.
  • the modified example is useful for the operation of a car navigation system, for example.
  • a car navigation system is controlled by a driver operating a touch panel of a display. In this case, it is often difficult to operate by moving only the arm or hand, and it is necessary to move the upper body, and it may not always be safe.
  • the car navigation system is integrated with a television device or an audio device. As described above, many car navigation systems in recent years have high functions, and if all the operations are performed with the touch panel, the safety is further lowered.
  • the icons and map images displayed on the display can be operated in a non-contact manner, so the driver can operate by moving only his arms and hands and move the upper body. Since it is not necessary, it can contribute to the improvement of safety.
  • the car navigation system corresponds to the electronic device 11, and the computer of the car navigation system corresponds to the computer 13.
  • application examples when the modification is applied to a car navigation system will be described.
  • the computer 13 of the car navigation system 11 selects an icon displayed on the display according to the moving direction of the hand coordinates.
  • the computer 13 changes the color of the selected icon.
  • the computer determines that the selection is confirmed when the selection state of the same icon continues for a certain time or longer.
  • the computer 13 displays a cursor linked to the hand coordinates on the display.
  • the computer 13 determines that the icon has been selected when the cursor is over the icon. Also in this case, of course, the color of the selected icon may be changed. In this case, the computer determines that the selection has been confirmed when the cursor continues to overlap the same icon for a certain time or more.
  • the computer 13 can also recognize a predetermined hand shape as a selection confirmation command. For example, when a hand with one finger raised is photographed, it can be used as a selection confirmation command.
  • the function (computer program) for determining whether or not the contour image is a hand with one finger raised is not installed, but of course, it can also be installed.
  • the computer 13 can scroll the map displayed on the display in a direction corresponding to the moving direction of the hand coordinates.
  • the computer 13 scrolls the map at a constant initial speed and stops after moving a certain distance.
  • the computer 13 can also scroll the map in the direction according to the moving direction of the hand coordinates at the initial speed corresponding to the moving speed of the hand coordinates.
  • the computer 13 stops scrolling assuming a constant coefficient of friction.
  • the computer 13 can also recognize a predetermined hand shape as a scroll stop command even during scrolling. For example, when a hand with a “par” is photographed, it can be used as a scroll stop command.
  • the computer 13 can enlarge / reduce the map using a predetermined hand shape and area as a command.
  • the computer 13 enlarges the map when the area of the “Goo” shape increases, and reduces the map when the area of the “Goo” shape decreases.
  • the computer 13 can enlarge the map when the area of the “Goo” shape decreases, and can reduce the map when the area of the “Goo” shape increases. Then, the computer 13 stops the enlargement / reduction operation when the shape of the “par” hand is photographed.
  • the computer 13 can control the audio device mounted on the car navigation system 11 based on the result data of the image processing module 1. Examples of applications in this case are given below. Of course, the modification can also be applied to a single car audio device.
  • the computer 13 scrolls the music list displayed on the display (assuming that the music is arranged in the vertical direction) in a direction corresponding to the movement direction of the hand coordinates (limited to the vertical direction). can do.
  • the computer 13 scrolls the music list at a constant initial speed, and stops after moving a certain distance.
  • the computer 13 can also scroll the music list at an initial speed corresponding to the moving speed of the hand coordinates, in a direction corresponding to the moving direction of the hand coordinates (limited to the vertical direction).
  • the computer 13 stops scrolling assuming a constant coefficient of friction.
  • a predetermined hand shape can be recognized as a scroll stop command. For example, when a hand with a “par” is photographed, it can be used as a scroll stop command.
  • the computer 13 controls to stop one music title at a predetermined position on the display. Then, the computer 13 recognizes that the music stopped at the predetermined position is in the selected state. For example, when a predetermined hand shape (for example, “goo”) is photographed, the computer 13 reproduces the music stopped at the predetermined position.
  • a predetermined hand shape for example, “goo”
  • the computer 13 can advance to the next music or return to the previous music according to the movement direction of the hand coordinates (limited to the horizontal direction) during reproduction of the music. Further, for example, the computer 13 can control the volume according to the rotation angle of the hand during the reproduction of the music. In this case, the computer 13 can also display a dial image that rotates in accordance with the rotation angle of the hand on the display.
  • the computer 13 can also control the television device mounted on the car navigation system 11 based on the result data of the image processing module 1.
  • the operation example in this case is the same as the operation example of the audio device.
  • the modification can be applied to a single on-vehicle television receiver.
  • the computer 13 stops the processing (for example, navigation, music playback, television image display) being executed, and the menu is displayed. You can return to the screen.
  • a predetermined shape for example, “Choki”
  • the computer 13 stops the processing (for example, navigation, music playback, television image display) being executed, and the menu is displayed. You can return to the screen.
  • the computer 13 can accept not only the non-contact operation according to the modified example but also the operation using the touch panel and use both of them together.
  • the present invention is not limited to the above-described embodiment, and can be implemented in various modes without departing from the gist thereof.
  • the following modifications are possible.
  • two image processing modes are mounted according to the distance.
  • three or more image processing modes can be mounted depending on the distance.
  • the MCU 3 calculates the centroid coordinates, area, shape, rotation angle, and rotation direction of the contour image based on the difference image (analysis target difference image).
  • the object is not limited to these.
  • the MCU 3 recognizes the color of the subject image reflected in the difference image, recognizes the pattern of the image, calculates the rotation amount of the image, and calculates the image. It is also possible to calculate the speed of the image, calculate the acceleration of the image, calculate the movement trajectory of the image, detect the moving object as the subject in the difference image, and / or detect the presence of the subject.
  • the MCU 3 detects a moving object (moving object flag), calculates the coordinates of the moving object (TX, TY), and calculates the luminance of the shooting space based on the image (analysis target image).
  • the object is not limited to these.
  • the MCU 3 recognizes the shape of the image of the subject in the image, recognizes the color of the image, recognizes the pattern of the image, and coordinates of the image. Calculation of the area of the image, calculation of the rotation amount or rotation angle of the image, calculation of the rotation direction of the image, calculation of the speed of the image, calculation of the acceleration of the image, calculation of the movement trajectory of the image And / or the luminance of the image of the subject in the image can be calculated.
  • a high-resolution image sensor is used instead.
  • the image processing mode is automatically switched according to the distance.
  • the setting of the MCU 3 can be fixed to the contour detection mode according to the specifications of the electronic device 11, or only the contour detection mode can be mounted.
  • the photographed subject image is processed (recognition of the shape of the subject image reflected in the difference image, recognition of the color of the image, recognition of the pattern of the image, calculation of the coordinates of the image, Calculation of the area of the image, calculation of the rotation amount or rotation angle of the image, calculation of the rotation direction of the image, calculation of the velocity of the image, calculation of the acceleration of the image, calculation of the movement trajectory of the image, Detection of a moving object as a captured subject and detection of the presence of the subject) and the processing result are output to the external computer 13.
  • the external computer 13 can use the processing result input from the image processing module as it is.
  • this image processing module is provided as a module that performs only photographing and image processing, the computer 13 that uses the processing result or the external device 11 that includes the computer 13 is not limited to a specific one.
  • the image processing module has high versatility.
  • this is effective when only the contour detection mode is installed in the image processing module, particularly when the subject is located at a relatively short distance from the image sensor 5. This is because the subject is irradiated with infrared light and is photographed by the image sensor 5. Of course, this does not exclude the use of this image processing module when the subject is located at a relatively long distance from the image sensor 5. In this case, for example, the emission intensity of the infrared light emitting diode 7 is increased and / or the number thereof is increased.
  • the same effect as the contour detection mode is obtained.
  • the function of the modified example can be mounted as it is.
  • the setting of the MCU 3 can be fixed to the moving object detection mode, or only the moving object detection mode can be mounted.
  • the captured image of the subject is processed (recognition of the shape of the subject image reflected in the image, recognition of the color of the image, recognition of the pattern of the image, calculation of the coordinates of the image, Area calculation, image rotation amount or rotation angle calculation, image rotation direction calculation, image speed calculation, image acceleration calculation, image movement trajectory calculation, image reflection Detection of a moving object as a subject, calculation of luminance of a shooting space reflected in the image, calculation of luminance of an image of the subject reflected in the image, and detection of the presence of the subject), and processing results thereof to an external computer 13 is output.
  • the external computer 13 can use the processing result input from the image processing module as it is.
  • this image processing module is provided as a module that performs only photographing and image processing, the computer 13 that uses the processing result or the external device 11 that includes the computer 13 is not limited to a specific one.
  • the image processing module has high versatility.
  • the MCU 3 sends an interrupt signal or command to the external computer 13 via the signal line 54 and the connector 30 when the analysis result of the image satisfies a predetermined condition.
  • a function to transmit can also be installed.
  • the infrared light filter 64 is disposed outside the lens unit 62 so as to cover the opening 66.
  • the infrared light filter may be disposed between the lens 72 and the image sensor 5 in the lens unit 62.
  • the memory 9 is built in the MCU 3.
  • the memory 9 may be disposed outside the MCU 3, and the memory may be provided both inside and outside the MCU 3.
  • the image sensor 5 generates and outputs a difference image.
  • the image sensor 5 can also output to the MCU 3 an image when the infrared light is turned on (may be grayscale or color) and an image when the light is turned off (may be grayscale or color).
  • the MCU 3 generates a difference image between the on-time image and the off-time image.
  • the MCU 3 can perform analysis processing based on the difference image, or can binarize the difference image and perform analysis processing.
  • the MCU 3 executes a generation process and an analysis process of a difference image between the lighting image and the extinguishing image every cycle.
  • the MCU 3 sequentially binarizes the pixel data D input serially from the image sensor 5 pixel by pixel.
  • the MCU 3 may binarize after storing all the pixel data D in the memory 9.
  • the MCU 3 can also execute analysis processing without binarization.
  • the control performed by the computer 13 of the electronic device 11 based on the information given from the MCU 3 of the image processing module 1 is not limited to mechanical / mechanical control, but is software, image, or sound control. May be.
  • the image processing module 1 can also recognize the shape of a hand with one finger raised.
  • an interrupt condition can be that the coordinate locus of the contour image satisfies a predetermined condition.
  • an interrupt condition may be that a predetermined different shape of a contour image is detected within a predetermined time (the order does not matter) (for example, the first contour image is detected within a predetermined time).
  • the interruption condition may be that a shape (for example, “par”) and a second shape (for example, “chough”) are detected.
  • an interrupt condition may be that a predetermined different shape of the contour image is detected in a predetermined order within a predetermined time (for example, the first shape of the contour image (eg, “par”)).
  • it can also be set as interruption conditions combining these examples.
  • the modification can be applied to a home audio device as well as an audio device of a car navigation system. Further, for example, similar to the television device of the car navigation system, the modification can be applied to a home-use television receiver.
  • the image processing module 1 performs processing in synchronization with the instruction from the computer 13 when there is an instruction from the computer 13, and synchronizes with the timer interrupt when there is no instruction from the computer 13. And processed.
  • the image processing module 1 can also perform processing in synchronization with only the timer interrupt.
  • the image sensor 5 controlled the on / off of the infrared light emitting diode 7.
  • the MCU 3 can also control on / off of the infrared light emitting diode 7 by connecting the base of the transistor 44 to the control terminal of the MCU 3.
  • step S153 if a positive determination is made even once in step S153, the moving object flag is turned on.
  • the moving body flag can be turned on when the value of the variable k (step S157) exceeds a predetermined value (an integer of 2 or more).
  • the predetermined value is determined experimentally and empirically.
  • step S157 In FIG. 6, among all the pixels of the image (64 ⁇ 64 pixels) from the image sensor 5, the number k of pixels in which an effective change was detected was counted (step S157). An example of this application is shown below.
  • N is an integer of 2 or more
  • the blocks BL1 to BLN are collectively referred to as a block BLn.
  • the MCU 3 counts the number kn of pixels in which effective changes are detected for each block BLn, and transmits the number of pixels kn for each block BLn to the computer 13.
  • the computer 13 determines that the movement of the subject is detected in the block BLn in which the number of pixels kn exceeds the predetermined value CV.
  • the predetermined value CV is determined experimentally and empirically.
  • the computer 13 performs control for directing or not directing the electronic device 11 or a part of the electronic device 11 to an area (in real space) corresponding to a block in which an image change (that is, movement of a subject) is detected. Can be done.
  • the computer 13 outputs the electronic apparatus 11 to each area (in real space) corresponding to each block with respect to the area corresponding to the block in which the image change (that is, the movement of the subject) is detected.
  • control that is not performed can be performed.
  • This application example can be applied, for example, when the electronic device 11 is an air conditioner that is used by being embedded in a ceiling.
  • the image sensor 5 is installed at a position where the subject can be viewed from above.
  • the image sensor 5 is attached to the ceiling together with the air conditioner (for example, a decorative panel of the air conditioner), or attached in the vicinity of the air conditioner.
  • the computer 13 of the air conditioner controls the vertical flap and / or the horizontal flap of the air conditioner to adjust the wind direction to the area corresponding to the block in which the movement of the subject is detected.
  • the computer 13 of the air conditioner outputs wind to the area corresponding to the block where the motion of the subject is detected, while outputting the wind to the area corresponding to the block where the motion of the subject is not detected. To stop.
  • the vertical flap is a flap that rotates around the vertical axis and adjusts the horizontal wind direction.
  • the horizontal flap is a flap that rotates around a horizontal axis and adjusts the wind direction in the vertical direction. These flaps are sometimes called a wind direction adjusting mechanism or a wind direction adjusting plate.
  • the electronic device 11 installed on the ceiling is not limited to the air conditioner.
  • a lighting device for example, a light emitting diode.
  • the installation place of the electronic device 11 and the image sensor 5 is not limited to the ceiling, and can be installed in any place according to the nature and application.
  • the electronic device 11 can be controlled by the processing. As a result, it is suitable for controlling the electronic device 11 installed on the ceiling.
  • the image processing module 1 is equipped with an infrared light emitting diode 7.
  • the infrared light emitting diode 7 can be omitted.
  • the MCU 3 processes a normal image, not a difference image.
  • the computer 13 can perform all or part of the processing performed by the MCU 3. In short, which process is to be performed can be arbitrarily determined according to the specification.
  • Processing steps that describe a program for causing the MCU 3 to perform various processes do not necessarily have to be processed in time series in the order described in the flowchart, and are executed in parallel or individually. It also includes processing.
  • means does not necessarily mean physical means, but includes cases where the functions of each means are realized by software. Further, the function of one means may be realized by two or more physical means, or the functions of two or more means may be realized by one physical means.
  • the present invention can be used in the fields of home appliances, entertainment devices, security devices, in-vehicle electronic devices, display devices, and personal computers.
  • SYMBOLS 1 ... Image processing module, 3 ... MCU, 5 ... Image sensor, 7 ... Infrared light emitting diode, 9 ... Memory, 11 ... Electronic device, 13 ... Computer, 30 ... Connector, 44 ... Transistor, 50, 52 ... Power supply line, 54 ... signal line 56 ... bus 58 ... substrate 60 ... housing 62 ... lens unit 64 ... infrared filter 66 ... opening 68 ... base 70 ... cylindrical member 72 ... convex lens 73 ... Lens holder, 74 ... optical axis, T1 to T7 ... terminals.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Studio Devices (AREA)
  • Image Analysis (AREA)

Abstract

 画像処理モジュールは、被写体がイメージセンサから近距離にある場合は、画像処理のモードを輪郭検出モードに設定する(ステップS117)。画像処理モジュールは、被写体がイメージセンサから遠距離にある場合は、画像処理のモードを動体検出モードに設定する(ステップS119)。画像処理モジュールは、輪郭検出モードでは、手の形状、回転、座標、及び面積を求める。画像処理モジュールは、動体検出モードでは、動体を検知し、座標を求める。被写体の遠近を判断して、遠近に応じた画像処理モードを自動的に設定することができる。

Description

画像処理装置、画像処理方法、コンピュータプログラム、記録媒体、画像処理モジュール、及び、電子機器
 本発明は、被写体が写り込んだ画像を処理して、処理結果を出力する画像処理装置、画像処理モジュール、電子機器、及び、その関連技術に関する。
 特許文献1の電子機器は、カメラを有し、被写体の遠近に応じて、通常撮影モードと接写モードとを自動的に切り替える。通常撮影モードでは、ズームレンズが第1範囲で移動し、接写モードでは、ズームレンズが第1範囲と異なる第2範囲で移動する。このように、被写体の遠近に応じて、ズームレンズの移動範囲が異なる。
 本件出願人による特許文献2に開示されているゴルフゲームシステムは、ゲーム機及びゴルフクラブ型入力装置を含み、ゲーム機のハウジングの内部には撮像ユニットが収納され、この撮像ユニットは、イメージセンサ及び赤外発光ダイオード等から構成される。赤外発光ダイオードによって撮像ユニットの上方の所定範囲に赤外光が間欠的に照射され、したがって、イメージセンサは、その範囲内で移動するゴルフクラブ型入力装置に設けられた反射体を間欠的に撮影する。このような反射体のストロボ映像を処理することによって、ゲーム機の入力となる速度などを計算する。このように、ストロボスコープを用いてコンピュータやゲーム機にリアルタイムで入力を与えることができる。
特開2006-58572号公報 特開2004-85524号公報
 確かに、特許文献1のように、通常撮影モードと接写モードとを自動的に切り替えることができれば便宜である。これと全く異なるものではあるが、被写体の遠近に応じて、自動的に画像処理の内容を異ならせることができれば、非常に便宜であり、利用価値も高い。
 そこで、本発明は、被写体の遠近を判断して、遠近に応じた画像処理モードを自動的に設定することができる画像処理装置及びその関連技術を提供することを目的とする。
 また、特許文献2のゴルフゲームシステムでは、反射体を撮影する撮像ユニット、及び、その反射体のストロボ映像を処理して、反射体の動きを算出するプロセッサは、ゲーム機に内蔵され、このゲーム機の専用品となっており、汎用性に乏しい。しかも、プロセッサは、反射体の動きを算出するだけでなく、ゲームプログラムも実行して、ゲームを制御する。このため、プログラマは、ゲームプログラムだけでなく、反射体のストロボ映像を処理して、反射体の動きを算出するプログラムも作成する必要がり、その負担が大きくなる。
 そこで、本発明の他の目的は、撮影された被写体の画像を処理して、その処理結果を、外部機器のコンピュータに出力し、当該外部機器のコンピュータが入力された処理結果をそのまま利用できるようにして、当該外部機器のコンピュータによる画像処理を不要とし、そのコンピュータのプログラマの負担を軽減し、かつ、高い汎用性を持つことができる画像処理モジュール及びその関連技術を提供することである。
 本発明の第1の観点によれば、画像処理装置は、被写体を撮影する撮影手段による映像に対して画像処理を施す画像処理手段と、前記被写体と前記撮影手段との間の距離に応じて、前記画像処理のモードを切り替える切替手段と、を備える。
 この構成によれば、被写体と撮影手段との間の距離に応じて、画像処理のモードが切り替えられるので、遠近に応じて、自動的に画像処理を異ならせることができる。
 このため、被写体が撮影手段から近くに存在する場合の画像処理を、被写体が撮影手段から比較的遠くに存在する場合の画像処理と異ならせることを要求する電子機器に、容易に対応可能となる。
 また、撮影手段として、比較的低解像度のものを採用でき、コストを削減できる。近くの被写体に対しては、低解像度であっても、画像処理により、その被写体の詳細な解析が可能であり、十分実用的な結果を得ることができる。一方、比較的遠くの被写体に対しては、低解像度の場合、被写体が近くに存在する場合と同じ画像処理により、被写体が近くに存在する場合と同等の精度の結果を得ることは困難である。従って、低解像度で、遠近に関係なく画像処理が同じであれば、比較的遠くにある被写体に対しては適用不可能であり、遠近双方に対応するためには、高解像度の撮影手段を採用せざるをえない。しかし、比較的遠くの被写体に対して、被写体が近くに存在する場合と異なる画像処理により、低解像度であっても十分実用的な結果を得ることもできる。このように、遠近に応じて、画像処理を異ならせることにより、低解像度の撮影手段によって、遠近双方の被写体に対応可能となる。
 さらに、近距離用のセンサと遠距離用のセンサとを別個に設ける必要がなく、コストを削減できる。つまり、1つの画像処理装置だけで、遠近双方の画像処理を行なうことができる。
 この画像処理装置において、前記切替手段は、前記被写体と前記撮影手段との間の距離に応じて、前記画像処理のモードとして第1モードを設定し、前記被写体と前記撮影手段との間の距離が、前記第1モードの設定時より長い場合に、前記画像処理のモードとして第2モードを設定し、前記画像処理手段は、前記第1モードの設定時に、前記映像に写った前記被写体の形態を認識する処理、動きを検出する処理、座標を求める処理、及び面積を求める処理の全部又は一部を実行し、前記第2モードの設定時に、前記映像から、前記被写体としての動体を検出する処理、撮影空間の輝度を求める処理、及び前記被写体の存在を検出する処理の全部又は一部を実行する。
 この構成によれば、近距離のための画像処理である第1モードでは、被写体の形態を認識する処理等が実行される。比較的低解像度の画像からでも、形態の認識は十分可能である。仮に、遠距離のための画像処理である第2モードにおいて、第1モードと同じ画像処理を行なっても、低解像度の画像からは、被写体の形態を精度良く認識することは困難である。しかし、第2モードでは、動体を検出する処理を実行する。動体の検出は、比較的低解像度の画像からも十分可能である。以上の結果、遠近双方において、比較的低解像度の撮影手段を採用できるので、コストを削減できる。
 ここで、近距離で被写体の形態を認識するためのセンサ(形態センサ)と遠距離で動体を検出するためのセンサ(動体センサ)とを設けることを想定する。
 このような場合、通常、形態センサとしては比較的高解像度の撮影手段が採用され、低解像度の撮影手段と比べて高価である。また、それに応じて、高解像度の撮影手段の制御装置(CPUなど)も高価になる。さらに、高解像度の画像では、処理量が多くなり、高速に出力結果を要求される場合は対応困難になる。
 また、このような場合、通常、動体センサとしては、焦電センサが採用される。焦電センサは、比較的低解像度の撮影手段より安価な場合もあるが、室温の変化を検出するものであるので、変化の発生は検知できるが、物体の座標を検出することができない。また、焦電センサでは、物体を検知して、その後、その物体が動かない場合は、その物体の存在を検知できない。
 以上のように、近距離のための形態センサと遠距離のための動体センサとを設ける場合には、本発明にはない不利益を伴うが、そのような不利益がない点で本発明は有利である。
 この画像処理装置において、前記画像処理手段は、前記第2モードの設定時に、前記動体を検出して追跡する処理を実行する。
 この構成によれば、動体を追跡して、動体をターゲットとした処理ないしは制御を行なうことができる。例えば、動体の追跡結果を受けて、電子機器の一部又は全部を常に動体に向くように制御できる。
 上記画像処理装置において、前記画像処理手段は、前記第1モードの設定時に、前記被写体の形態としての形状を認識する処理を実行する。
 この構成によれば、被写体の形状を入力とした情報処理を実行することができる。
 上記画像処理装置において、前記画像処理手段は、前記第1モードの設定時に、前記被写体の動きとしての回転動作を検出する処理を実行する。
 この構成によれば、被写体の回転を入力とした情報処理を実行することができる。
 上記画像処理装置において、前記切替手段は、光を発光する発光手段の発光時の前記撮影手段による前記映像と前記発光手段の消灯時の前記撮影手段による前記映像との差分画像に写り込んだ前記被写体の面積を算出する面積算出手段と、前記被写体の前記面積に基づいて、前記被写体と前記撮影手段との間の距離を判断し、前記画像処理のモードを設定する設定手段と、を含む。
 この構成によれば、画像上の面積は、撮影手段と被写体との間の距離に相関するので、面積により、撮影手段と被写体との間の距離を容易に判断できる。
 また、被写体が遠くにあれば、発光手段の光が届かない、あるいは、届いても反射光が弱く撮影手段に検出されないので、発光手段の発光時及び消灯時に関係なく、撮影画像には、遠くの物体は写り込まない。一方、発光手段の発光時のみ、近くの物体は、その光を反射し、撮影画像に写り込む。よって、差分により背景成分が除去されるので、発光手段が照射した光を反射した物体だけが、差分画像に現われる。このように、差分といった簡単な処理で、近くの物体の像のみを抽出できる。
 上記画像処理装置において、前記画像処理手段は、前記画像処理のモードとしての第1モードでは、光を発光する発光手段の発光時の前記撮影手段による前記映像と前記発光手段の消灯時の前記撮影手段による前記映像との第1差分画像に前記画像処理を施し、前記画像処理のモードとしての第2モードでは、前記発光手段の消灯時の前記撮影手段による前記映像に対して前記画像処理を施し、前記切替手段は、前記第1モードでは、前記第1差分画像に写り込んだ前記被写体の面積を算出する第1面積算出手段と、前記第1モードでは、前記第1差分画像上の前記被写体の前記面積に基づいて、前記被写体と前記撮影手段との間の距離を判断し、その距離に応じて、前記第1モードを設定し、前記被写体と前記撮影手段との間の距離が、前記第1モードの設定時より長い場合に、前記第2モードを設定する第1設定手段と、前記第2モードでは、前記発光手段の発光時の前記撮影手段による前記映像と前記発光手段の消灯時の前記撮影手段による前記映像との第2差分画像に写り込んだ前記被写体の面積を算出する第2面積算出手段と、前記第2モードでは、前記第2差分画像上の前記被写体の前記面積に基づいて、前記被写体と前記撮影手段との間の距離を判断し、その距離に応じて、前記第2モードを設定し、前記被写体と前記撮影手段との間の距離が、前記第2モードの設定時より短い場合に、前記第1モードを設定する第2設定手段と、を含む。
 この構成によれば、画像上の面積は、撮影手段と被写体との間の距離に相関するので、面積により、撮影手段と被写体との間の距離を容易に判断できる。
 また、被写体が遠くにあれば、発光手段の光が届かない、あるいは、届いても反射光が弱く撮影手段に検出されないので、発光手段の発光時及び消灯時に関係なく、撮影画像には、遠くの物体は写り込まない。一方、発光手段の発光時のみ、近くの物体は、その光を反射し、撮影画像に写り込む。よって、差分により背景成分が除去されるので、発光手段が照射した光を反射した物体だけが、差分画像に現われる。このように、差分といった簡単な処理で、近くの物体の像のみを抽出できる。
 さらに、第2モードの画像処理では、発光手段の発光は不要なところ、第1モードの画像処理で要求される発光手段を、画像処理モードの切り替えのために、第2モードで共用している。その結果、コストを削減できる。
 この画像処理装置において、前記第2モードで前記第2差分画像を得るための前記撮影手段の撮影周期は、前記第1モードで前記第1差分画像を得るための前記撮影手段の撮影周期より長く設定される。
 この構成によれば、第2モードでの画像処理のモードを切り替えるための撮影周期を短くしているので、消費電力を抑制することができる。画像処理のモードを切り替えるための判断は、画像処理と同等の周期で行なう必要はなく、実質的に性能に影響はない。
 本発明の第2の観点によれば、画像処理装置は、被写体を撮影する撮影手段が出力した画像を処理する画像処理装置であって、前記撮影手段が出力した現在の画像と過去の画像との差分を算出する差分手段と、前記差分に基づいて、画素値の変化を検出する検出手段と、第1閾値及び前記第1閾値より小さい第2閾値を設定し、前記画素値の変化の頻度が前記第1閾値を超える場合又は前記第2閾値を下回る場合、その変化をノイズと判断し、前記頻度が前記第1閾値と前記第2閾値との間にある場合、その変化を実質的な変化と判断し、前記動体が存在すると判断する判断手段と、を備える。
 この構成によれば、第1閾値を設けているので、画素値の変化の頻度が高い動き、例えば、テレビジョンのちらつき等、周期的な比較的周波数の高い動きをノイズとして除去できる。また、第2閾値を設けているので、画素値の変化の頻度が低い動き、例えば、撮影環境(撮影空間や撮影手段の状態)の変化から発生した画像上のノイズを除去できる。
 本発明の第3の観点によれば、画像処理装置は、被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理装置であって、前記撮影手段が出力した画像から前記手の輪郭線を抽出し、その輪郭線の変曲点の画素と前記変曲点の次の変曲点の画素との間の画素に基づいて、指を特定する指特定手段と、所定の基準線に対する、前記指特定手段が特定した各指の傾き角を算出する傾角算出手段と、前記指特定手段が特定した、隣り合う指と指とがなす角度を、前記各指の前記傾き角に基づき算出する指角算出手段と、前記隣り合う指と指とがなす前記角度に基づいて、手の形状を判定する判定手段と、を備える。
 この構成によれば、指先と水かきとの間の画素に基づいて指を特定することになり、輪郭画像の重心により指を特定しないので、重心により指を特定する場合と比較して、精度良く指を特定でき、ひいてはより精度よく手の形状を判定できる。一般に、輪郭画像の重心と、被写体の重心と、は一致しない場合も多く、この場合に、重心により指を特定すると、認識の精度が低くなる。
 この画像処理装置において、前記指特定手段は、前記被写体の輪郭線上にある画素から、指先に相当する画素を特定する手段を含み、前記画像処理手段は、前記被写体の輪郭画像の重心から前記指先に相当する前記画素までの距離を算出する手段をさらに含み、前記判定手段は、前記隣り合う指と指とがなす前記角度、及び、前記指先に相当する前記画素までの前記距離に基づいて、手の形状を判定する。
 この構成によれば、指先と水かきとの間の画素に基づいて得られた、隣り合う指と指とがなす角度だけでなく、重心から指先に相当する画素までの距離に基づいて、手の形状を判断するので、より多様な手の形状を判定できる。例えば、手の形状が「チョキ」であることを判定するアルゴリズムに適用できる。
 本発明の第4の観点によれば、画像処理装置は、被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理装置であって、前記手の輪郭画像の重心から輪郭線上の各画素までの距離を算出する距離算出手段と、前記各画素までの前記距離に基づいて、手の形状を判定する判定手段と、を備える。
 この構成によれば、重心から輪郭線上の画素までの距離を求めるといった簡単な計算で、手の形状を判定できる。例えば、重心から輪郭線上の画素までの距離が、一定範囲内の場合に、手の形状が「グー」であることを判定できる。
 本発明の第5の観点によれば、画像処理装置は、被写体を撮影する撮影手段が出力した画像を処理する画像処理装置であって、前記被写体の輪郭画像の重心と輪郭線上の画素とを結ぶ線分の長さを算出する長さ算出手段と、前記線分が、所定の基準線に対してなす角度を算出する角度算出手段と、前記長さを前記角度の関数として表したときの位相差を、前記被写体の回転角度とする回転検出手段と、を備える。
 この構成によれば、簡易、かつ、精度よく、手の回転角度を検出できる。
 本発明の第6の観点によれば、画像処理方法は、被写体を撮影する撮影手段が出力した映像を処理する画像処理方法であって、コンピュータが、前記撮影手段が出力した映像に対して画像処理を施すステップと、前記コンピュータが、前記被写体と前記撮影手段との間の距離に応じて、前記画像処理のモードを切り替えるステップと、を含む。
 この構成によれば、上記第1の観点による画像処理装置と同様の効果を奏する。
 本発明の第7の観点によれば、画像処理方法は、被写体を撮影する撮影手段が出力した画像を処理する画像処理方法であって、前記撮影手段が出力した現在の画像と過去の画像との差分を算出するステップと、前記差分に基づいて、画素値の変化を検出するステップと、第1閾値及び前記第1閾値より小さい第2閾値を設定し、前記画素値の変化の頻度が前記第1閾値を超える場合又は前記第2閾値を下回る場合、その変化をノイズと判断し、前記頻度が前記第1閾値と前記第2閾値との間にある場合、その変化を実質的な変化と判断し、前記動体が存在すると判断するステップと、を含む。
 この構成によれば、上記第2の観点による画像処理装置と同様の効果を奏する。
 本発明の第8の観点によれば、画像処理方法は、被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理方法であって、前記撮影手段が出力した画像から前記手の輪郭線を抽出し、その輪郭線の変曲点の画素と前記変曲点の次の変曲点の画素との間の画素に基づいて、指を特定するステップと、所定の基準線に対する、前記指を特定する前記ステップが特定した各指の傾き角を算出するステップと、前記指を特定する前記ステップが特定した、隣り合う指と指とがなす角度を、前記各指の前記傾き角に基づき算出するステップと、前記隣り合う指と指とがなす前記角度に基づいて、手の形状を判定するステップと、を含む。
 この構成によれば、上記第3の観点による画像処理装置と同様の効果を奏する。
 本発明の第9の観点によれば、画像処理方法は、被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理方法であって、前記手の輪郭画像の重心から輪郭線上の各画素までの距離を算出するステップと、前記各画素までの前記距離に基づいて、手の形状を判定するステップと、を含む。
 この構成によれば、上記第4の観点による画像処理装置と同様の効果を奏する。
 本発明の第10の観点によれば、画像処理方法は、被写体を撮影する撮影手段が出力した画像を処理する画像処理方法であって、前記被写体の輪郭画像の重心と輪郭線上の画素とを結ぶ線分の長さを算出するステップと、前記線分が、所定の基準線に対してなす角度を算出するステップと、前記長さを前記角度の関数として表したときの位相差を、前記被写体の回転角度とするステップと、を含む。
 この構成によれば、上記第5の観点による画像処理装置と同様の効果を奏する。
 本発明の第11の観点によれば、コンピュータプログラムは、上記第6から第10の観点による画像処理方法のうちのいずれか一をコンピュータに実行させる。
 本発明の第12の観点によれば、記録媒体は、上記第11の観点によるコンピュータプログラムを記録したコンピュータ読み取り可能な記録媒体である。
 なお、本明細書及び請求の範囲において、記録媒体は、例えば、フレキシブルディスク、ハードディスク、磁気テープ、光磁気ディスク、CD(CD-ROM、Video-CDを含む)、DVD(DVD-Video、DVD-ROM、DVD-RAMを含む)、ROMカートリッジ、バッテリバックアップ付きのRAMメモリカートリッジ、フラッシュメモリカートリッジ、不揮発性RAMカートリッジ等を含む。
 本発明の第13の観点によれば、画像処理モジュールは、外部のコンピュータと接続される画像処理モジュールであって、MCU(Micro Controller Unit)と、前記MCUの内部及び/又は外部に配置され、前記MCUによって実行されるプログラム及びデータが格納されるメモリと、被写体を撮影するイメージセンサと、赤外光を発光する赤外発光ダイオードを含む発光部と、電源端子及び信号端子を含み、かつ、前記外部のコンピュータと接続するためのコネクタと、外部から前記電源端子に与えられる電源電圧を、前記MCU、前記メモリ、前記イメージセンサ、及び、前記発光部に供給するための電源線と、前記コネクタの前記信号端子と、前記MCUと、を接続する信号線と、前記MCUと、前記イメージセンサと、を接続するバスと、を備える。
 前記MCU又は前記イメージセンサは、前記発光部がスイッチングトランジスタを含む場合は、そのスイッチングトランジスタを制御して、前記赤外発光ダイオードを間欠的に駆動し、前記発光部がスイッチングトランジスタを含まない場合は、前記赤外発光ダイオードを直接制御して、前記赤外発光ダイオードを間欠的に駆動する。
 前記イメージセンサは、前記赤外発光ダイオードが赤外光を発光している時、及び、前記赤外発光ダイオードが赤外光を発光していない時、のそれぞれにおいて、撮影処理を実行し、赤外光の発光時の撮影画像と赤外光の非発光時の撮影画像との差分画像を生成して、その差分画像を、前記バスを介して、前記MCUに送信するものであり、あるいは、赤外光の発光時の第1撮影画像と赤外光の非発光時の第2撮影画像とを生成して、それら第1撮影画像及び第2撮影画像を、前記バスを介して、前記MCUに送信するものである。
 前記イメージセンサが前記差分画像を生成するものである場合において、前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記差分画像を生成し、前記MCUに送信し、前記差分画像は、複数の画素からなり、前記イメージセンサは、前記差分画像を前記MCUに送信する際に、1画素ずつ、シリアルに送信し、前記MCUは、前記イメージセンサから1画素を受信するたびに、所定の閾値と比較して、2値化を行い、前記メモリに格納し、前記メモリに格納された2値化された差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信するものであり、あるいは、前記MCUは、前記イメージセンサから前記差分画像を受け取って、前記メモリに格納し、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信するものである。
 前記イメージセンサが前記第1撮影画像及び第2撮影画像を生成するものである場合において、前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記第1撮影画像及び第2撮影画像を生成し、前記MCUに送信し、前記MCUは、前記第1撮影画像と前記第2撮影画像との差分画像を生成し、前記メモリに格納して、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信するものである。
 前記MCUによる前記解析対象差分画像の解析は、新たに前記解析対象差分画像を前記メモリに格納するたびに実行され、その解析結果が、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信される。
 前記MCUによる前記解析対象差分画像の解析は、前記解析対象差分画像に写り込んだ前記被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、前記解析対象差分画像に写り込んだ前記被写体としての動体の検出、及び、前記被写体の存在の検出のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信される。
 前記MCUは、前記解析対象差分画像の解析結果が所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能である。
 前記MCU、前記メモリ、前記イメージセンサ、前記発光部、前記コネクタ、前記電源線、前記信号線、及び、前記バスは、所定の基板上にマウントされる。
 前記画像処理モジュールは、前記所定の基板上に固定されるレンズユニットをさらに備える。
 前記レンズユニットは、レンズと、前記レンズを保持するレンズホルダと、を含み、前記イメージセンサは、前記所定の基板上において、前記レンズの下部であって、前記レンズの光軸上であり、かつ、前記レンズホルダの内部に配置される。
 前記画像処理モジュールは、赤外光のみを透過する赤外光フィルタをさらに備え、前記赤外光フィルタは、前記レンズユニットの内部の、前記イメージセンサと前記レンズとの間に配置され、又は、前記レンズユニットの外部において、前記レンズを覆うように配置される。
 前記外部のコンピュータは、エアコンディショナ・テレビジョン・オーディオ機器・フォトフレーム・照明機器等といった家庭電化製品、電子玩具・ビデオゲーム機等といったエンターテインメント機器、セキュリティ機器、カーナビゲーション等の車載電子機器、若しくは、LCD等のディスプレイ装置のコンピュータ、又は、パーソナルコンピュータであることができる。
 この構成によれば、撮影された被写体の画像を処理して(解析対象差分画像に写り込んだ被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、解析対象差分画像に写り込んだ被写体としての動体の検出、及び、被写体の存在の検出)、その処理結果を、外部のコンピュータに出力する。このため、当該外部のコンピュータは、この画像処理モジュールから入力された処理結果をそのまま利用できる。その結果、当該外部のコンピュータによる画像処理を不要とし、そのコンピュータのプログラマの負担を軽減することができる。また、この画像処理モジュールは、撮影及び画像処理だけを行なうモジュールとして提供されるので、その処理結果を利用するコンピュータあるいはそのコンピュータを搭載する外部機器は特定のものに限定されず、この画像処理モジュールは、高い汎用性を持つ。
 また、被写体が遠くにあれば、発光部の光が届かない、あるいは、届いても反射光が弱くイメージセンサに検出されないので、発光部の発光時及び消灯時に関係なく、撮影画像には、遠くの物体は写り込まない。一方、発光部の発光時のみ、近くの物体は、その光を反射し、撮影画像に写り込む。よって、差分により背景成分が除去されるので、発光部が照射した光を反射した物体だけが、差分画像に現われる。このように、差分といった簡単な処理で、近くの物体の像のみを抽出できる。
 さらに、限定はされないが、この発明は、特に、被写体がイメージセンサに対して比較的近距離に位置している場合に有効である。なぜなら、赤外光を被写体に照射し、それをイメージセンサにより撮影するからである。もちろん、これは、被写体がイメージセンサに対して比較的遠距離に位置している場合に、この画像処理モジュールを使用することを排除するものではない。この場合、例えば、赤外発光ダイオードの発光強度を強くし、及び/又は、その数を増やす。
 本発明の第14の観点によれば、画像処理モジュールは、外部のコンピュータと接続される画像処理モジュールであって、MCU(Micro Controller Unit)と、前記MCUの内部及び/又は外部に配置され、前記MCUによって実行されるプログラム及びデータが格納されるメモリと、被写体を撮影するイメージセンサと、電源端子及び信号端子を含み、かつ、前記外部のコンピュータと接続するためのコネクタと、外部から前記電源端子に与えられる電源電圧を、前記MCU、前記メモリ、及び、前記イメージセンサに供給するための電源線と、前記コネクタの前記信号端子と、前記MCUと、を接続する信号線と、前記MCUと、前記イメージセンサと、を接続するバスと、を備える。
 前記イメージセンサは、一定時間間隔で、撮影処理を実行し、撮影画像を、前記バスを介して、前記MCUに送信する。
 前記MCUは、前記イメージセンサから前記撮影画像を受け取って、前記メモリに格納し、前記メモリに格納された前記撮影画像(以下、「解析対象画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する。
 前記MCUによる前記解析対象画像の解析は、新たに前記解析対象画像を前記メモリに格納するたびに実行され、その解析結果が、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信される。
 前記MCUによる前記解析対象画像の解析は、前記解析対象画像に写り込んだ前記被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、前記解析対象画像に写り込んだ前記被写体としての動体の検出、前記解析対象画像に写り込んだ撮影空間の輝度の算出、前記解析対象画像に写り込んだ前記被写体の像の輝度の算出、及び、前記被写体の存在の検出のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信される。
 前記MCUは、前記解析対象画像の解析結果が所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能である。
 前記MCU、前記メモリ、前記イメージセンサ、前記コネクタ、前記電源線、前記信号線、及び、前記バスは、所定の基板上にマウントされる。
 前記画像処理モジュールは、前記所定の基板上に固定されるレンズユニットをさらに備える。
 前記レンズユニットは、レンズと、前記レンズを保持するレンズホルダと、を含み、前記イメージセンサは、前記所定の基板上において、前記レンズの下部であって、前記レンズの光軸上であり、かつ、前記レンズホルダの内部に配置される。
 前記外部のコンピュータは、エアコンディショナ・テレビジョン・オーディオ機器・フォトフレーム・照明機器等といった家庭電化製品、電子玩具・ビデオゲーム機等といったエンターテインメント機器、セキュリティ機器、カーナビゲーション等の車載電子機器、若しくは、LCD等のディスプレイ装置のコンピュータ、又は、パーソナルコンピュータであることができる。
 この構成によれば、撮影された被写体の画像を処理して(解析対象画像に写り込んだ被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、解析対象画像に写り込んだ被写体としての動体の検出、解析対象画像に写り込んだ撮影空間の輝度の算出、解析対象画像に写り込んだ被写体の像の輝度の算出、及び、被写体の存在の検出)、その処理結果を、外部のコンピュータに出力する。このため、当該外部のコンピュータは、この画像処理モジュールから入力された処理結果をそのまま利用できる。その結果、当該外部のコンピュータによる画像処理を不要とし、そのコンピュータのプログラマの負担を軽減することができる。また、この画像処理モジュールは、撮影及び画像処理だけを行なうモジュールとして提供されるので、その処理結果を利用するコンピュータあるいはそのコンピュータを搭載する外部機器は特定のものに限定されず、この画像処理モジュールは、高い汎用性を持つ。
 また、限定はされないが、この発明は、特に、被写体がイメージセンサに対して比較的遠距離に位置している場合に有効である。なぜなら、赤外発光ダイオードを設けずに、室内光及び/又は外光を反射する被写体を撮影するからである。もちろん、これは、被写体がイメージセンサに対して比較的近距離に位置している場合に、この画像処理モジュールを使用することを排除するものではない。
 本発明の第15の観点によれば、画像処理モジュールは、外部のコンピュータと接続される画像処理モジュールであって、MCU(Micro Controller Unit)と、前記MCUの内部及び/又は外部に配置され、前記MCUによって実行されるプログラム及びデータが格納されるメモリと、被写体を撮影するイメージセンサと、赤外光を発光する赤外発光ダイオードを含む発光部と、電源端子及び信号端子を含み、かつ、前記外部のコンピュータと接続するためのコネクタと、外部から前記電源端子に与えられる電源電圧を、前記MCU、前記メモリ、前記イメージセンサ、及び、前記発光部に供給するための電源線と、前記コネクタの前記信号端子と、前記MCUと、を接続する信号線と、前記MCUと、前記イメージセンサと、を接続するバスと、を備える。
 前記イメージセンサは、第1撮影モード及び第2撮影モードを有する。
 前記第1撮影モードにおいて、前記MCU又は前記イメージセンサは、前記発光部がスイッチングトランジスタを含む場合は、そのスイッチングトランジスタを制御して、前記赤外発光ダイオードを間欠的に駆動し、前記発光部がスイッチングトランジスタを含まない場合は、前記赤外発光ダイオードを直接制御して、前記赤外発光ダイオードを間欠的に駆動する。
 前記第1撮影モードにおいて、前記イメージセンサは、前記赤外発光ダイオードが赤外光を発光している時、及び、前記赤外発光ダイオードが赤外光を発光していない時、のそれぞれにおいて、撮影処理を実行し、赤外光の発光時の撮影画像と赤外光の非発光時の撮影画像との差分画像を生成して、その差分画像を、前記バスを介して、前記MCUに送信するものであり、あるいは、赤外光の発光時の第1撮影画像と赤外光の非発光時の第2撮影画像とを生成して、それら第1撮影画像及び第2撮影画像を、前記バスを介して、前記MCUに送信するものである。
 前記第1撮影モードにおいて、前記イメージセンサが前記差分画像を生成するものである場合(以下、「第1の場合」と呼ぶ。)において、前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記差分画像を生成し、前記MCUに送信する。
 前記第1の場合において、前記差分画像は、複数の画素からなり、前記イメージセンサは、前記差分画像を前記MCUに送信する際に、1画素ずつ、シリアルに送信し、前記MCUは、前記イメージセンサから1画素を受信するたびに、所定の第1の閾値と比較して、2値化を行い、前記メモリに格納し、前記メモリに格納された2値化された差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析するものであり、あるいは、前記第1の場合において、前記MCUは、前記イメージセンサから前記差分画像を受け取って、前記メモリに格納し、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析するものである。
 前記第1撮影モードにおいて、前記イメージセンサが前記第1撮影画像及び第2撮影画像を生成するものである場合(以下、「第2の場合」と呼ぶ。)において、前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記第1撮影画像及び第2撮影画像を生成し、前記MCUに送信する。
 前記第2の場合において、前記MCUは、前記第1撮影画像と前記第2撮影画像との差分画像を生成し、前記メモリに格納して、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析するものである。
 前記第1撮影モードにおいて、前記MCUによる前記解析対象差分画像の解析は、新たに前記解析対象差分画像を前記メモリに格納するたびに実行される。
 前記第2撮影モードにおいて、前記イメージセンサは、一定時間間隔で、撮影処理を実行し、撮影画像を、前記バスを介して、前記MCUに送信する。
 前記第2撮影モードにおいて、前記MCUは、前記イメージセンサから前記撮影画像を受け取って、前記メモリに格納し、前記メモリに格納された前記撮影画像(以下、「解析対象画像」と呼ぶ。)を解析する。
 前記第2撮影モードにおいて、前記MCUによる前記解析対象画像の解析は、新たに前記解析対象画像を前記メモリに格納するたびに実行される。
 前記MCUは、第1画像処理モードと第2画像処理モードとを有する。
 前記第1画像処理モードにおいて、前記MCUによる前記解析対象差分画像の解析は、前記解析対象差分画像に写り込んだ前記被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、前記解析対象差分画像に写り込んだ前記被写体としての動体の検出、及び、前記被写体の存在の検出のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信される。
 前記第1画像処理モードにおいて、前記MCUは、前記解析対象差分画像の解析結果が第1の所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能である。
 前記第2画像処理モードにおいて、前記MCUによる前記解析対象画像の解析は、前記解析対象画像から前記被写体としての動体を検出する処理、前記解析対象画像に写り込んだ撮影空間の輝度を求める処理、前記解析対象画像に写り込んだ被写体の像の輝度を求める処理、及び、前記解析対象画像から前記被写体の存在を検出する処理のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信される。
 前記第2画像処理モードにおいて、前記MCUは、前記解析対象画像の解析結果が第2の所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能である。
 前記第1画像処理モードでは、前記イメージセンサは、前記第1撮影モードで動作し、前記MCUは、前記第1撮影モードで得られた前記解析対象差分画像の解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信し、前記解析対象差分画像に基づいて、前記第1画像処理モードと前記第2画像処理モードとの間の切り替えを行う。
 前記第2画像処理モードでは、前記イメージセンサは、前記第1撮影モード及び前記第2撮影モードで動作し、前記MCUは、前記第2撮影モードで得られた前記解析対象画像の解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信し、前記第1撮影モードで得られた前記解析対象差分画像に基づいて、前記第1画像処理モードと前記第2画像処理モードとの間の切り替えを行う。
 前記第1画像処理モードにおいて、前記MCUは、前記解析対象差分画像に写り込んだ像の面積を算出して、その面積と所定の第2の閾値を比較し、その面積が前記所定の第2の閾値を超えている場合、前記第1画像処理モードを維持し、その面積が前記所定の第2の閾値以下の場合、前記第1画像処理モードから前記第2画像処理モードへ移行する。
 前記第2画像処理モードにおいて、前記MCUは、前記解析対象差分画像に写り込んだ像の面積を算出して、その面積と前記所定の第2の閾値を比較し、その面積が前記所定の第2の閾値以下の場合、前記第2画像処理モードを維持し、その面積が前記所定の第2の閾値を超えている場合、前記第2画像処理モードから前記第1画像処理モードへ移行する。
 前記第2画像処理モードにおいて、前記第1撮影モードにおける前記赤外発光ダイオードを間欠的に駆動する際の周期は、前記第1画像処理モードでの周期より長い、又は、同じである。
 前記MCU、前記メモリ、前記イメージセンサ、前記発光部、前記コネクタ、前記電源線、前記信号線、及び、前記バスは、所定の基板上にマウントされる。
 前記画像処理モジュールは、前記所定の基板上に固定されるレンズユニットをさらに備える。
 前記レンズユニットは、レンズと、前記レンズを保持するレンズホルダと、を含み、前記イメージセンサは、前記所定の基板上において、前記レンズの下部であって、前記レンズの光軸上であり、かつ、前記レンズホルダの内部に配置される。
 前記画像処理モジュールは、赤外光のみを透過する赤外光フィルタをさらに備え、前記赤外光フィルタは、前記レンズユニットの内部の、前記イメージセンサと前記レンズとの間に配置され、又は、前記レンズユニットの外部において、前記レンズを覆うように配置される。
 前記外部のコンピュータは、エアコンディショナ・テレビジョン・オーディオ機器・フォトフレーム・照明機器等といった家庭電化製品、電子玩具・ビデオゲーム機等といったエンターテインメント機器、セキュリティ機器、カーナビゲーション等の車載電子機器、若しくは、LCD等のディスプレイ装置のコンピュータ、又は、パーソナルコンピュータであることができる。
 この構成によれば、撮影された被写体の画像を処理して(第1画像処理モードでは、解析対象差分画像に写り込んだ被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、解析対象差分画像に写り込んだ被写体としての動体の検出、及び、被写体の存在の検出、第2画像処理モードでは、解析対象画像から被写体としての動体を検出する処理、解析対象画像に写り込んだ撮影空間の輝度を求める処理、解析対象画像に写り込んだ被写体の像の輝度の算出、及び、解析対象画像から被写体の存在を検出する処理)、その処理結果を、外部のコンピュータに出力する。このため、当該外部のコンピュータは、この画像処理モジュールから入力された処理結果をそのまま利用できる。その結果、当該外部のコンピュータによる画像処理を不要とし、そのコンピュータのプログラマの負担を軽減することができる。また、この画像処理モジュールは、撮影及び画像処理だけを行なうモジュールとして提供されるので、その処理結果を利用するコンピュータあるいはそのコンピュータを搭載する外部機器は特定のものに限定されず、この画像処理モジュールは、高い汎用性を持つ。
 また、解析対象差分画像に写り込んだ像の面積に基づいて、被写体とイメージセンサとの間の遠近を判断して、第1画像処理モードと第2画像処理モードとを切り替える。つまり、画像上の被写体の面積は、イメージセンサと被写体との間の距離に相関するので、面積により、イメージセンサと被写体との間の遠近を判断できる。
 このように、被写体とイメージセンサとの間の距離に応じて、画像処理のモードが切り替えられるので、遠近に応じて、自動的に画像処理を異ならせることができる。このため、被写体がイメージセンサから近くに存在する場合の画像処理を、被写体がイメージセンサから比較的遠くに存在する場合の画像処理と異ならせることを要求する電子機器に、容易に対応可能となる。
 さらに、イメージセンサとして、比較的低解像度のものを採用でき、コストを削減できる。近くの被写体に対しては、低解像度であっても、画像処理により、その被写体の詳細な解析が可能であり、十分実用的な結果を得ることができる。一方、比較的遠くの被写体に対しては、低解像度の場合、被写体が近くに存在する場合と同じ画像処理により、被写体が近くに存在する場合と同等の精度の結果を得ることは困難である。従って、低解像度で、遠近に関係なく画像処理が同じであれば、比較的遠くにある被写体に対しては適用不可能であり、遠近双方に対応するためには、高解像度のイメージセンサを採用せざるをえない。しかし、比較的遠くの被写体に対して、被写体が近くに存在する場合と異なる画像処理により、低解像度であっても十分実用的な結果を得ることもできる。このように、遠近に応じて、画像処理を異ならせることにより、低解像度のイメージセンサによって、遠近双方の被写体に対応可能となる。
 例えば、近距離のための画像処理である第1画像処理モードでは、被写体の形状を認識する処理が実行される。比較的低解像度の画像からでも、形状の認識は十分可能である。仮に、遠距離のための画像処理である第2画像処理モードにおいて、第1画像処理モードと同じ画像処理を行なっても、低解像度の画像からは、被写体の形状を精度良く認識することは困難である。しかし、第2画像処理モードでは、動体を検出する処理を実行する。動体の検出は、比較的低解像度の画像からも十分可能である。以上の結果、遠近双方において、比較的低解像度のイメージセンサを採用できるので、コストを削減できる。
 さらに、近距離用のセンサと遠距離用のセンサとを別個に設ける必要がなく、コストを削減できる。
 ここで、近距離で被写体の形態(形状、模様、若しくは色彩、又は、それらの任意の組合せ)を認識するためのセンサ(形態センサ)と遠距離で動体を検出するためのセンサ(動体センサ)とを設けることを想定する。
 このような場合、通常、形態センサとしては比較的高解像度のイメージセンサが採用され、低解像度のイメージセンサと比べて高価である。また、それに応じて、高解像度のイメージセンサの制御装置(CPUなど)も高価になる。さらに、高解像度の画像では、処理量が多くなり、高速に出力結果を要求される場合は対応困難になる。
 また、このような場合、通常、動体センサとしては、焦電センサが採用される。焦電センサは、比較的低解像度のイメージセンサより安価な場合もあるが、室温の変化を検出するものであるので、変化の発生は検知できるが、物体の座標を検出することができない。また、焦電センサでは、物体を検知して、その後、その物体が動かない場合は、その物体の存在を検知できない。
 以上のように、近距離のための形態センサと遠距離のための動体センサとを設ける場合には、本発明にはない不利益を伴うが、そのような不利益がない点で本発明は有利である。
 さらに、第2画像処理モードでは、発光部の発光は不要なところ、第1画像処理モードで要求される発光部を、画像処理モードの切り替えのために、第2画像処理モードで共用している。その結果、コストを削減できる。
 さらに、第2画像処理モードにおいて、第1撮影モードにおける赤外発光ダイオードを間欠的に駆動する際の周期を、第1画像処理モードの場合より長くすることによって、消費電力を抑制することができる。画像処理のモードを切り替えるための判断は、画像処理と同等の周期で行なう必要はなく、実質的に性能に影響はない。
 本発明の第16の観点によれば、電子機器は、被写体を撮影する撮影手段が出力した画像を処理する画像処理手段と、前記画像処理手段の処理結果に基づいて所定の機器を制御する制御手段と、を備え、前記画像処理手段は、前記画像を複数のブロックに分割し、前記ブロックごとに、画素の変化を検出し、前記制御手段は、前記ブロックごとの画素の変化に応じて、前記所定の機器を制御する。
 この構成によれば、画像のブロックごとに、写り込んだ像の変化、つまり、被写体の動きを検出することができる。このため、制御手段は、所定の機器又は所定の機器の一部を、像の変化(つまり被写体の動き)が検出されたブロックに対応する領域(実空間の)に向ける制御又は向けない制御を行なうことができる。また、制御手段は、各ブロックに対応する各領域(実空間の)に向けた所定の機器の出力を、像の変化(つまり被写体の動き)が検出されたブロックに対応する領域に対して行う又は行なわない制御を行なうことができる。
 例えば、前記制御手段は、前記ブロックごとの画素の変化に応じて、前記所定の機器の出力、前記所定の機器の向き、又は、前記所定の機器の一部の向きを制御する。
 上記電子機器において、前記撮影手段は、前記被写体を俯瞰撮影できる位置に設置され、前記所定の機器は、天井に設置される。
 この構成によれば、俯瞰撮影が行われるので、水平方向からの撮影と比較して、複数の被写体が重なって写り込む頻度が少なく、複数の被写体の重なりの判断を省くこともできるので、簡易な処理により機器を制御できる。その結果、天井に設置された機器の制御に好適である。
 もちろん、複数の被写体の重なりの判断を行ってもよい。なお、水平方向から撮影すると、複数の被写体が1つの像として画像に存在することになる場合であっても(例えば、撮影手段の光軸上に、複数の被写体が存在する場合)、俯瞰撮影する場合は、それらが、分離した像として画像に存在することも多い。
 この電子機器において、前記所定の機器は、天井に設置される空気調和装置であり、この空気調和装置は、風向きを調整するための風向調整機構を有し、前記制御手段は、前記ブロックごとの画素の変化に応じて、前記風向調整機構を制御する。
 このように、本発明は、天井に設置される空気調和装置の制御に好適である。
 本発明の新規な特徴は、特許請求の範囲に記載されている。しかしながら、発明そのもの及びその他の特徴と効果は、添付図面を参照して具体的な実施例の詳細な説明を読むことにより容易に理解される。
本発明の実施の形態による画像処理モジュール1の電気的構成を示す図である。 図1のMCU3による全体処理の流れの一例を示すフローチャートである。 図2のステップS707のイメージセンサ5の制御の流れの一例を示すフローチャートである。 図3のステップS27の差分画像データ取得処理の流れの一例を示すフローチャートである。 図3のステップS719の画像処理モードの切替処理の流れの一例を示すフローチャートである。 図3のステップS713の動体検出モードでの処理の流れの一例を示すフローチャートである。 図3のステップS711の輪郭検出モードでの処理の流れの一例を示すフローチャートである。 図7のステップS195の変曲点の検出処理の流れの一例を示すフローチャートである。 図7のステップS197の輪郭画像の形状を判定する処理の流れの一例を示すフローチャートである。 図9のステップS261の輪郭情報を算出する処理の流れの一例を示すフローチャートである。 図9のステップS263の指先を検出する処理の流れの一例を示すフローチャートである。 図9のステップS265の「パー」を判定する処理の流れの一例を示すフローチャートである。 図9のステップS267の「チョキ」を判定する処理の流れの一例を示すフローチャートである。 図9のステップS269の「グー」を判定する処理の流れの一例を示すフローチャートである。 図7のステップS199の輪郭画像の回転を検出する処理の流れの一例を示すフローチャートである。 図7のステップS193で検出される偏角θjの説明図である。 図7のステップS195で検出される変曲点及び図9のステップS263で検出される指先の説明図である。 図10のステップS309で作成される回転テーブルの例示図である。 輪郭画像の回転を検出する処理の説明図である。 (a)図1のイメージセンサ5が出力するビジー信号のタイミング図である。(b)図1のMCU3が出力するリード信号のタイミング図である。(c)図1のMCU3が読み込む画素データDのタイミング図である。 本発明の実施の形態の変形例におけるMCU3の全体処理の流れの一例を示すフローチャートである。 (a)図1のコンピュータ13が出力するスレイブセレクト信号のタイミング図である。(b)図1のMCU3とコンピュータ13とを接続するデータ入力線上の信号のタイミング図である。(c)図1のMCU3とコンピュータ13とを接続するデータ出力線上の信号のタイミング図である。 図1の画像処理モジュール1の詳細な電気的構成を示す図である。 (a)図1の画像処理モジュール1の平面図である。(b)図1の画像処理モジュール1の側面図である。(c)図1の画像処理モジュール1の外観平面図である。 図24(a)のレンズユニット62のA-A線による断面図である。
 以下、本発明の実施の形態について、図面を参照しながら説明する。なお、図中、同一または相当部分については同一の参照符号を付してその説明を援用する。また、本明細書において、数字の後尾に付した「h」は、16進数であることを示す。
 図1は、本発明の実施の形態による画像処理モジュール1の電気的構成を示す図である。図1を参照して、この画像処理モジュール1は、MCU(Micro Controler Unit)3、イメージセンサ5、及び赤外発光ダイオード7を含む。MCU3は、メモリ9を含む。イメージセンサ5は、カラー及びグレースケールのいずれでも使用でき、また、その画素数も任意にものを使用できるが、本実施の形態では、グレースケールで、64×64画素の比較的低解像度のものを使用する。赤外発光ダイオード7は、赤外光を発光する。赤外発光ダイオード7の数は、1つに限定されず、画像処理モジュール1の仕様に応じて、複数設けることができる。また、イメージセンサ5としては、CMOSイメージセンサやCCDイメージセンサ等を採用できる。
 MCU3のメモリ9は、RAM、ROM、及びフラッシュメモリ等の半導体メモリであり、プログラム格納領域、データ格納領域、作業領域、及び一時格納領域等として利用される。MCU3は、メモリ9に格納されたプログラムに従って、後述のフローチャートで示される各種処理を実行する。なお、仕様に応じて、記録媒体として、メモリ9の他、CD(CD-ROM、Video-CDを含む)やDVD(DVD-Video、DVD-ROM、DVD-RAMを含む)等の光ディスク、半導体メモリを搭載したメモリカード・メモリカートリッジ・USBメモリ、ハードディスク、光磁気ディスク、磁気テープ、及び、フレキシブルディスク等を、MCU3に接続することもできる。そして、これらにプログラムやデータなどを格納することもできる。
 画像処理モジュール1は、電子機器11と接続されて使用される。電子機器11は、コンピュータ13を含む。電子機器11は、例えば、エアコンディショナ・テレビジョン・オーディオ機器・フォトフレーム・照明機器等といった家庭電化製品、電子玩具・ビデオゲーム機等といったエンターテインメント機器、セキュリティ機器、カーナビゲーション等の車載電子機器、LCD等のディスプレイ装置、及び、パーソナルコンピュータ等であるが、特に限定されるものではない。
 MCU3は、メモリ9に格納されたプログラムに従って、独自に又は電子機器11のコンピュータ13の命令を受けて、イメージセンサ5を制御する。イメージセンサ5は、MCU3の制御により、被写体を撮影し、また、赤外発光ダイオード7を制御する。
 なお、画像処理モジュール1及び電子機器11からなるシステムを、電子機器と呼び、電子機器11を機器11と呼ぶこともある。また、画像処理モジュール1を画像処理装置1と呼ぶ事もある。
 さて、次に、本実施の形態の概要を説明する。画像処理モジュール1は、2つの画像処理モードを搭載する。その1つは、輪郭検出モード(第1画像処理モード)、他の一つは、動体検出モード(第2画像処理モード)である。画像処理モジュール1は、被写体の遠近に応じて、輪郭検出モード又は動体検出モードのいずれかに自動的に入る。つまり、画像処理モジュール1は、被写体が近くに存在すると判断したときは、輪郭検出モードに入り、被写体が遠くに存在すると判断したときは、動体検出モードに入る。
 輪郭検出モードについて説明する。イメージセンサ5は、赤外発光ダイオード7の点灯時及び消灯時に撮影処理を実行し、点灯時画像と消灯時画像との差分画像を生成して、MCU3に与える。赤外発光ダイオード7は、間欠的に赤外光を発光する。赤外光の点灯時間及び消灯時間を1周期と考えると、イメージセンサ5は、この1周期ごとに、差分画像の生成処理を実行する。よって、MCU3は、1周期ごとに、以下に示す差分画像の解析処理を行なう。
 MCU3は、差分画像に基づいて、手の輪郭を検出し、グー、チョキ、パー、及び不定のいずれかを判定する。また、MCU3は、手の回転角度を検出する。さらに、MCU3は、輪郭画像の座標及び面積を算出する。MCU3は、これらの情報を電子機器11のコンピュータ13に送信する。コンピュータ13は、電子機器11の仕様に応じて、これらの情報を処理する。
 例えば、コンピュータ13は、輪郭画像の座標に従って、電子機器11としての表示装置のカーソルを制御したり、グー、チョキ、及びパーをコマンドと認識して、それらに割り当てられた処理を実行したり、手の回転角度に応じた処理を実行したり(例えば、手の回転角度に応じて仮想又は現実のダイヤルを回転)、輪郭画像の面積に応じた処理を実行したり、輪郭画像の座標の軌道に応じた処理を実行する。その結果、ユーザは、従来のタッチパネルのように、パネル等に触れることなく、電子機器11を操作することができる。
 また、例えば、コンピュータ13は、輪郭画像の座標の動きに応じて、電子機器11としての表示装置の画面を制御する。この場合、例えば、コンピュータ13は、輪郭画像の座標が水平右方向に移動した場合、ユーザが手を水平右方向に振ったと判断して、ページを左から右にめくったように、画面を切り替えたり、あるいは、左から右へ表示画像をスライドさせ、画面を切り替える。同様にして、コンピュータ13は、座標の水平左方向移動、垂直上方向移動、及び垂直下方向移動などに応じて、画面を切り替える。
 動体検出モードについて説明する。イメージセンサ5は、赤外光の消灯時に撮影処理を実行し、消灯時画像(以下、「動体検出用画像」と呼ぶ事もある。)をMCU3に与える。イメージセンサ5は、動体検出用画像を得るための撮影処理(以下、「動体検出撮影処理」と呼ぶ事もある。)を一定時間間隔で実行する。
 MCU3は、動体検出用画像に基づいて、動体を検出し、追跡する。また、MCU3は、動体の座標を算出する。さらに、MCU3は、撮影された空間の輝度を算出する。さらに、MCU3は、動体としての被写体が検出されたが、その後、検出されなくなった場合に、被写体が撮影空間に存在しなくなったのか、あるいは、その被写体が撮影空間に存在するが静止したのか、を判定する。例えば、現在の画像と過去の画像とを比較することにより、このような判定が可能である。MCU3は、これらの情報を電子機器11のコンピュータ13に送信する。
 コンピュータ13は、電子機器11の仕様に応じて、これらの情報を処理する。例えば、コンピュータ13は、動体をターゲットとした処理ないしは制御を実行する。この場合、例えば、コンピュータ13は、電子機器11としての表示装置の画面を動体の方に向けたり、電子機器11としてのエアコンディショナの送風口を動体の方に向ける。
 また、例えば、コンピュータ13は、動体が存在しない状態から動体が存在する状態への変化をトリガとして、電子機器11を起動又は停止する。例えば、コンピュータ13は、動体が存在する状態から動体が存在しない状態への変化をトリガとして、電子機器11を起動又は停止する。
 画像処理モードの切り替えについて説明する。輪郭検出モードでは、MCU3は、輪郭画像の面積が、所定の閾値THBを超えている場合は、被写体が近くに存在すると判断し、輪郭検出モードを維持し、輪郭画像の面積が、所定の閾値THB以下の場合は、被写体が遠くに存在すると判断し、動体検出モードに移行する。
 一方、動体検出モードでは、イメージセンサ5は、動体検出用画像を出力した後、次の動体検出撮影処理の開始前に、輪郭検出モードの撮影処理と同じ処理を実行して、差分画像を生成する。MCU3は、差分画像中の輪郭画像の面積が、所定の閾値THBを超えている場合は、被写体が近くに存在すると判断し、輪郭検出モードに移行し、輪郭画像の面積が、所定の閾値THB以下の場合は、被写体が遠くに存在すると判断し、動体検出モードを維持する。
 さて、次に、図1の画像処理モジュール1を構成するハードウェアの詳細を説明する。
 図23は、図1の画像処理モジュール1の詳細な電気的構成を示す図である。図23を参照して、画像処理モジュール1は、基板58を備える。基板58には、MCU3、イメージセンサ5、赤外発光ダイオード7、コネクタ30、コンデンサ31,32,34,36,40、抵抗素子38,48、及び、NPN型トランジスタ44がマウントされる。
 MCU3とイメージセンサ5とはバス56によって接続される。このバス56を通じて、MCU3とイメージセンサ5との間で、信号やデータの送受信が行なわれる。バス56は、ビジー信号のための信号線(後述の図20(a)参照)、リード信号のための信号線(後述の図20(b)参照)、及び、画素データDのためのデータ線(後述の図20(c)参照)等を含む。
 MCU3には、電源線52から電源電圧Vccが与えられる。電源線52とグラウンドとの間には、3つのバイパスコンデンサ34が並列に接続され、ノイズを除去する。また、MCU3の内部に設けられたレギュレータ(図示せず)の発振を防止するため、並列に接続されたコンデンサ36が設けられる。ただし、これらのコンデンサ36は、MCU3の仕様に応じて、不要な場合もある。
 さらに、電源線52とグラウンドとの間に、抵抗素子38及びコンデンサ40が直列に接続され、遅延回路を構成する。抵抗素子38及びコンデンサ40の接続点は、MCU3のリセット端子に接続される。MCU3は、リセット端子の電位がローレベルになった時に、リセット処理を実行する。遅延回路は、電源投入時に直ちにリセット端子がハイレベルになることを防止するものであり、MCU3の仕様に応じて不要な場合もある。
 イメージセンサ5には、電源線52から電源電圧Vccが与えられる。電源線52とグラウンドとの間には、2つのバイパスコンデンサ31が並列に接続され、ノイズを除去する。また、電源線50とグラウンドとの間に、赤外発光ダイオード7及び抵抗素子48が直列に接続される。そして、トランジスタ44のベースは、イメージセンサ5の制御端子に接続される。イメージセンサ5の制御端子がハイレベルのときにトランジスタ44はオンし、これにより、赤外発光ダイオード7がオンして、赤外光を発光する。一方、イメージセンサ5の制御端子がローレベルのときにトランジスタ44はオフし、これにより、赤外発光ダイオード7がオフして、赤外光の発光を停止する。このように、トランジスタ44は、スイッチングトランジスタとして機能すると共に、それがオンのときに、赤外発光ダイオード7に流れる電流を増幅する。ただし、トランジスタ44は、必須のものではなく、イメージセンサ5の制御端子に、赤外発光ダイオード7のアノードを直接接続することもできる。
 コネクタ30の電源端子T1(後述の図24(a)参照)は、電源線50に接続される。外部の電子機器11から電源端子T1に電源電圧Vcc(例えば3.3V)が与えられ、電源線50に供給される。また、コネクタ30の電源端子T2(後述の図24(a)参照)は、電源線52に接続される。外部の電子機器11から電源端子T2に電源電圧Vcc(例えば3.3V)が与えられ、電源線52に供給される。電源線52とグラウンドとの間には、バイパスコンデンサ32が設けられ、ノイズを除去する。また、コネクタ30のグラウンド端子T7(後述の図24(a)参照)は、グラウンドに接続される。
 また、コネクタ30の端子T3~T6は、信号線54に接続され、信号線54は、MCU3に接続される。本実施の形態では、信号線54は、4本の信号線を含む。信号線54の一本は、コネクタ30の端子T3(後述の図24(a)参照)に接続される。コンピュータ13は、端子T3にクロック信号を与え、MCU3との同期をとる。信号線54の他の一本は、コネクタ30の端子T4(後述の図24(a)参照)に接続される。コンピュータ13は、端子T4にスレイブセレクト信号を与える(後述の図22(a)参照)。信号線54のさらに他の一本(すなわち、後述の図22(b)のデータ入力線)は、コネクタ30の端子T5(後述の図24(a)参照)に接続される。信号線54のさらに他の一本(すなわち、後述の図22(c)のデータ出力線)は、コネクタ30の端子T6(後述の図24(a)参照)に接続される。
 図24(a)は、図1の画像処理モジュール1の平面図である。図24(b)は、図1の画像処理モジュール1の側面図である。図24(c)は、図1の画像処理モジュール1の外観平面図である。図24(a)及び図24(b)を参照して、端子T1~T7を有するコネクタ30、赤外発光ダイオード7、MCU3、及び、レンズユニット62は、この順番で基板58上に直線上に配置される。もちろん、これらの配置及び順番は、これに限定されるものではなく、任意に配置されてよい。
 また、図24(c)も参照して、コネクタ30、赤外発光ダイオード7、MCU3、及び、レンズユニット62がマウントされた基板58は、ハウジング60内に配置される。ハウジング60において、赤外発光ダイオード7の上部には、断面ラッパ状の開口が形成され、ここから赤外発光ダイオード7の発光部が外部に露出する。さらに、ハウジング60において、レンズユニット62の上部には、開口66を覆うように、つまり、筒状部材70(後述の図25参照)のヘッド(レンズ72)を覆うように、赤外光のみを透過する赤外光フィルタ64が設けられる。これにより、レンズユニット62の内部に配置されたイメージセンサ5には、赤外光のみが入射する。
 なお、ハウジング60は、必須のものではない。ハウジング60を設けない場合には、赤外光フィルタ64は、例えば、赤外光フィルタ64を保持する専用の基台を作成し、これを基板58に固定する。また、例えば、後述の図25の基台68を設計変更して赤外光フィルタ64の基台として用いてもよい。これらの固定方法は、ハウジング60を設ける場合であっても利用可能である。
 図25は、図24(a)のレンズユニット62のA-A線による断面図である。図25を参照して、レンズユニット62は、凸レンズ72及びそれを保持するレンズホルダ73を含む。レンズホルダ73は、基台68及び筒状部材70を含む。基台68及び筒状部材70の内部は空洞である。筒状部材70のヘッド部の上端には、開口66(図24(a)参照)が形成される。この開口66の直下において、筒状部材70は、レンズ72を保持する。
 また、筒状部材70の胴部の外周には、ねじ山(雄ねじ)が形成される。一方、基台68の内周は、筒状部材70の胴部のねじ山と螺合可能なように、ねじ山(雌ねじ)が形成される。これにより、基板58に対して、筒状部材70を上下動させることができる。また、基台68は、基板58上に固定される。
 イメージセンサ5は、レンズ72の光軸74がイメージセンサ5の中心を通るように、基台68の内部で基板58に固定される。そして、レンズ72のベストフォーカス領域が、イメージセンサ5の撮影面にくるように、筒状部材70が基台68に固定される。このような調整は、筒状部材70を上下動させることにより行い、筒状部材70が接着剤により最適な位置で基台68に固定される。このような調整は、製造する際のレンズ72の形状のばらつき、レンズ72を筒状部材70へ固定する際のばらつき、及び、製造する際のイメージセンサ5のばらつき等を吸収するために行なわれる。
 さて、次に、フローチャートを用いて画像処理モジュール1のMCU3の処理の詳細を説明する。
 図2は、図1のMCU3による全体処理の流れの一例を示すフローチャートである。図2を参照して、ステップS701にて、MCU3は、レジスタや変数等を初期化する。なお、後述する変数Nは0に初期化される。ステップS703にて、MCU3は、コンピュータ13が出力するスレイブセレクト信号の立下りエッジを検出したか否かを判断し、検出していない場合ステップS703に戻り、検出した場合ステップS705に進む。ステップS705にて、MCU3は、コンピュータ13から開始コマンドを受信したか否かを判断し、受信していない場合ステップS705に戻り、受信した場合ステップS707に進む。なお、開始コマンドは、MCU3とコンピュータ13とを接続するデータ入力線を介して与えられる。また、コンピュータ13は、開始コマンドをMCU3に送信した後、スレイブセレクト信号をハイレベルにする。
 ステップS707にて、MCU3は、イメージセンサ5の制御を実行する。ステップS709にて、MCU3は、画像処理モードが、輪郭検出モードの場合ステップS711に進み、動体検出モードの場合ステップS713に進む。ステップS711では、MCU3は、輪郭検出処理を実行する。一方、ステップS713では、MCU3は、動体検出処理を実行する。
 ステップS714では、MCU3は、スレイブセレクト信号の立下りエッジを検出したか否かを判断し、検出した場合ステップS715に進み、それ以外はステップS714に戻る。ステップS715にて、MCU3は、コンピュータ13からリードコマンドを受信したか否かを判断し、受信していない場合ステップS715に戻り、受信した場合ステップS717に進む。なお、リードコマンドは、MCU3とコンピュータ13とを接続するデータ入力線を介して与えられる。ステップS717では、MCU3は、ステップS711又はS713の結果を、コンピュータ13に送信する。なお、コンピュータ13は、MCU3からデータを受け取った後、スレイブセレクト信号をハイレベルにする。ステップS719にて、MCU3は、画像処理モードの切替処理を実行して、ステップS707に進む。
 図3は、図2のステップS707のイメージセンサ5の制御の流れの一例を示すフローチャートである。図3を参照して、ステップS3にて、MCU3は、現在の画像処理モードが輪郭検出モードである場合ステップS5に進み、動体検出モードである場合ステップS29に進む。コンピュータ13は、一定時間間隔で(例えば、1/30秒)、該指示をMCU3に与える。
 ステップS5にて、MCU3は、イメージセンサ5の撮影モードを差分モード(第1撮影モード)に設定する。ステップS7にて、MCU3は、イメージセンサ5の露光時間ETを一定値に設定する。ステップS9にて、MCU3は、イメージセンサ5に対して、赤外発光ダイオード7の点灯を指示する。すると、イメージセンサ5は、赤外発光ダイオード7をオンし、これにより、赤外発光ダイオード7は、赤外光を発光する。
 ステップS11にて、MCU3は、イメージセンサ5の露光(撮影)開始を指示する。ステップS13にて、MCU3は、露光時間ETが終了した場合ステップS15に進み、終了していない場合ステップS13に戻る。ステップS15にて、MCU3は、イメージセンサ5の露光(撮影)終了を指示する。
 ステップS17にて、MCU3は、赤外発光ダイオード7の点灯時間が終了した場合ステップS19に進み、終了していない場合ステップS17に戻る。ステップS19にて、MCU3は、イメージセンサ5に対して、赤外発光ダイオード7の消灯を指示する。すると、イメージセンサ5は、赤外発光ダイオード7をオフし、これにより、赤外発光ダイオード7は、発光を停止する。
 ステップS21にて、MCU3は、イメージセンサ5の露光(撮影)開始を指示する。ステップS23にて、MCU3は、露光時間ETが終了した場合ステップS25に進み、終了していない場合ステップS23に戻る。ステップS25にて、MCU3は、イメージセンサ5の露光(撮影)終了を指示する。
 ステップS27にて、MCU3は、イメージセンサ5から、赤外発光ダイオード7の点灯時画像と消灯時画像との差分画像データ(64×64の画素データ)を取得し、順次2値化して、配列PD[X][Y](画素データPD[X][Y]と呼ぶこともある。X=0~63、Y=0~63)に格納して、リターンする。
 図4は、図3のステップS27の差分画像データ取得処理の流れの一例を示すフローチャートである。図20(a)~図20(c)は、差分画像データ取得処理の際の信号送受信の説明図である。
 図4を参照して、ステップS61にて、MCU3は、変数X(=0~63),Y(=0~63),及びPD[X][Y]に、0を代入する。なお、矩形の差分画像の左上角を原点Oとし、原点Oから右方向に延びる水平軸をX軸とし、原点Oから下方向に延びる垂直軸をY軸とする。
 ステップS63にて、MCU3は、イメージセンサ5からのビジー信号(図20(a)参照)がローレベルか否かを判断し、ローレベルの場合ステップS65に進み、ハイレベルの場合ステップS63に戻る。ステップS65にて、MCU3は、イメージセンサ5に与えているリード信号(図20(b)参照)をローレベルに設定する。ステップS67にて、MCU3は、イメージセンサ5から差分画像の画素データD(1画素に対応)を読み込む(図20(c)参照)。
 ステップS69にて、MCU3は、一定時間t0が経過したか否かを判断し、経過した場合ステップS71に進み、経過していない場合ステップS69に戻る。ステップS71にて、MCU3は、リード信号(図20(b)参照)をハイレベルに設定する。ステップS73にて、MCU3は、画素データDと所定の閾値THAとを比較する。ステップS75にて、MCU3は、画素データDが閾値THAより大きい場合ステップS77に進み、それ以下の場合ステップS79に進む。ステップS77では、MCU3は、配列PD[X][Y]に「1」(被写体の像の画素)を代入する。一方、ステップS79では、MCU3は、配列PD[X][Y]に「0」(背景の画素)を代入する。このようにして、イメージセンサ5からの差分画像の各画素は順次2値化される。
 ステップS81にて、MCU3は、変数Xを1つインクリメントする。ステップS83にて、MCU3は、変数Xの値が64になったか否かを判断し、64の場合ステップS85に進み、それ以外はステップS89に進む。ステップS85では、MCU3は、変数Yを1つインクリメントする。ステップS87にて、MCU3は、変数Yの値が64になったか否かを判断し、64の場合全ての画素を読み込んだのでリターンし、それ以外はステップS89に進む。ステップS89では、MCU3は、ビジー信号(図20(a)参照)の立ち上がりエッジを検出した場合ステップS61に進み、それ以外はステップS89に戻る。
 以上のように、MCU3は、画素を読み込むたびに順次2値化して、2値化された差分画像データを得る。
 図3に戻って、ステップS29では、MCU3は、イメージセンサ5の撮影モードを標準モード(第2撮影モード)に設定する。ステップS31にて、MCU3は、イメージセンサ5に対して、赤外発光ダイオード7の消灯を指示する。すると、イメージセンサ5は、赤外発光ダイオード7をオフし、これにより、赤外発光ダイオード7は、発光を停止する。
 ステップS33にて、MCU3は、イメージセンサ5の露光(撮影)開始を指示する。ステップS35にて、MCU3は、露光時間ETが終了した場合ステップS37に進み、終了していない場合ステップS35に戻る。ステップS37にて、MCU3は、イメージセンサ5の露光(撮影)終了を指示する。
 ステップS39にて、MCU3は、イメージセンサ5から、赤外発光ダイオード7の消灯時の画像データ(64×64の画素データ)を取得して、配列PS[X][Y](画素データPS[X][Y]と呼ぶこともある。X=0~63、Y=0~63)に格納する。ステップS39の画像データ取得処理は、図4の差分画像データ取得処理と同様である。ただし、図4のステップS73~S79の処理に代えて、イメージセンサ5からの画素データDは、2値化せずにそのまま、配列PS[X][Y]に格納される。また、図4の説明において、差分画像を画像と読み替え、配列PD[X][Y]を配列PS[X][Y]と読み替える。この場合、矩形の画像の左上角を原点Oとし、原点Oから右方向に延びる水平軸をX軸とし、原点Oから下方向に延びる垂直軸をY軸とする。
 ステップS41にて、MCU3は、画素データPS[X][Y]の平均値を算出する。ステップS43にて、MCU3は、イメージセンサ5の露光時間ETを、ステップS41で求めた平均値に応じた値に設定する。画素データPS[X][Y]は輝度値であるので、その平均値は、撮影空間(撮影される空間)の明るさを表す指標になる。従って、イメージセンサ5は、該平均値が大きく撮影空間が明るいほど露光時間ETを短く設定し、該平均値が小さく撮影空間が暗いほど露光時間ETを長く設定する。このように、動体検出モードでは、ステップS35の露光時間ETは、撮影空間の明るさに応じて動的に設定される。
 ステップS44にて、MCU3は、変数Nを1つインクリメントする。ステップS45にて、MCU3は、変数Nの値が3になったか否かを判断し、値が3の場合、画像処理モードの切り替えのための撮影処理を行なうため、ステップS5に進み、それ以外はリターンする。つまり、動体検出モードでは、画像処理モードの切り替えのための撮影処理の周期は、輪郭検出モードでの輪郭検出及び動体検出モードでの動体検出のための撮影処理の周期の3倍であり、より長く設定される。よって、消費電力を抑制できる。なお、コンピュータ13が、動体検出モードでの画像処理モードの切り替えのための撮影処理の指示を出すこともできる。
 動体検出モードでは、ステップS45での肯定評価(YES)の後のステップS5~S25の結果であるステップS27の差分画像データは、画像処理モードの切替判定のためだけに使用される(後述の図5参照)。
 図5は、図1のMCU3による画像処理モードの切り替え処理の流れの一例を示すフローチャートである。図5を参照して、ステップS99にて、MCU3は、現在の画像処理モードが、輪郭検出モードの場合ステップS101に進み、動体検出モードの場合ステップS100に進む。ステップS100では、MCU3は、変数Nの値が3か否かを判断し、値が3の場合ステップS101に進み、それ以外はリターンする。
 ステップS101にて、MCU3は、変数X,Y及びAに0を代入する。ステップS103にて、MCU3は、差分画像の画素データPD[X][Y]が「1」か否かを判断し、「1」の場合ステップS105に進み、「0」の場合ステップS107に進む。ステップS105では、MCU3は、変数Aを1つインクリメントする。
 ステップS107にて、MCU3は、変数Xを1つインクリメントする。ステップS109にて、MCU3は、変数Xの値が64になったか否かを判断し、64場合ステップS111に進み、それ以外はステップS103に戻る。ステップS111では、MCU3は、変数Yを1つインクリメントする。ステップS113にて、MCU3は、変数Yの値が64になったか否かを判断し、64の場合ステップS115に進み、それ以外はステップS103に戻る。
 ステップS115にて、MCU3は、差分画像に写り込んだ被写体の像の面積を表す変数Aの値が所定の閾値THBより大きいか否かを判断し、大きい場合ステップS117に進み、それ以下の場合ステップS119に進む。ステップS117では、MCU3は、被写体が近距離に存在すると判断して、画像処理モードを輪郭検出モードに設定する。ステップS118にて、MCU3は、図3の変数Nに0を代入して、ステップS101に進む。一方、ステップS119では、MCU3は、被写体が遠距離に存在すると判断して、画像処理モードを動体検出モードに設定してステップS101に進む。
 図6は、図1のMCU3による動体検出モードでの処理の流れの一例を示すフローチャートである。図6を参照して、ステップS141にて、MCU3は、変数k,X,Y,AX,AY,TX,TY,及びS[X][Y]に0を代入する。ステップS143にて、MCU3は、動体フラグをオフにする。動体フラグは、動体が検出されたときにオンにされるフラグである。
 ステップS145にて、MCU3は、現在の画像の画素値PS[X][Y]と前回取得した画像の画素値PS[X][Y]との差分値DIFを算出する。ステップS147にて、MCU3は、差分値DIFが所定の閾値THCより大きいか否かを判断し、大きい場合ステップS149に進み、それ以下の場合ステップS151に進む。ステップS149では、MCU3は、変数S[X][Y]の現在の値に一定値IC(>0)を加算して、変数S[X][Y]に代入する。一方、ステップS151では、MCU3は、変数S[X][Y]の現在の値から一定値DC(>0)を減算して、変数S[X][Y]に代入する。この場合、DC<IC、である。
 ステップS153にて、MCU3は、変数S[X][Y]の値が閾値THHより小さく、かつ、閾値THLより大きいか否かを判断し、肯定的判断の場合、画素値PS[X][Y]の変化が有効と判断し、ステップS155に進み、否定的判断の場合、画素値PS[X][Y]の変化が無効(ノイズ)と判断し、ステップS161に進む。変数S[X][Y]の値は、対応する画素値PS[X][Y]が変化した頻度を示す指標であり、この値が大きいほど変化の頻度が高く、この値が小さいほど変化の頻度が低い。従って、画素値PS[X][Y]が変化した頻度が高すぎる場合、又は、画素値PS[X][Y]が変化した頻度が低すぎる場合は、その変化をノイズと判断して、ステップS155に進むことなく、ステップS161に進む。
 ステップS155では、MCU3は、動体フラグをオンにする。ステップS157では、MCU3は、変数kを1つインクリメントする。変数kは、画素値PS[X][Y]の変化が有効と判断された画素の数を示す。ステップS159にて、MCU3は、変数AXの現在の値に変数Xの値を加算して、変数AXに代入する。また、MCU3は、変数AYの現在の値に変数Yの値を加算して、変数AYに代入する。
 ステップS161にて、MCU3は、変数Xを1つインクリメントする。ステップS163にて、MCU3は、変数Xの値が64になったか否かを判断し、64の場合ステップS165に進み、それ以外はステップS145に進む。ステップS165では、MCU3は、変数Yを1つインクリメントする。ステップS167にて、MCU3は、変数Yの値が64になったか否かを判断し、64の場合ステップS169に進み、それ以外はステップS145に進む。
 ステップS169では、MCU3は、変数AXの値を変数kの値で除したものを変数TXに格納し、変数AYの値を変数kの値で除したものを変数TYに格納する。座標(TX,TY)は、イメージセンサ5からの画像に含まれる動体の像の座標である。ステップS171にて、MCU3は、画素値PS[X][Y]の合計値を求め、これをイメージセンサ5の露光時間ET(図3のステップS43)で除することにより、撮影空間の輝度を求める。そして、MCU3は、リターンする。
 ここで、動体検出モードでは、図2のステップS717では、MCU3は、動体フラグ、動体の座標(TX,TY)、及び撮影空間の輝度を電子機器11のコンピュータ13に送信する。
 図7は、図1のMCU3による輪郭検出モードでの処理の流れの一例を示すフローチャートである。図7を参照して、ステップS191にて、MCU3は、差分画像データ(PD[X][Y])から被写体の像の輪郭線を抽出する。この処理では、輪郭線上の各画素Pj(j=0~J-1)の座標(XO[j],YO[j])を求める。
 ここで、本実施の形態では、値Jは、輪郭線上の画素Pjの総数を示す。また、反時計回りに輪郭線の抽出処理が実行されるものとする。
 輪郭線を抽出するためのアルゴリズムは、周知のものを使用できる。例えば、3×3の小画素領域からなるマスクを用いる方法で、このマスクの中心を輪郭線上にたえずおきならが、順次、マスクを移動して、輪郭線を抽出する。
 ステップS193にて、MCU3は、抽出した輪郭線上の各画素PjのベクトルVjの偏角θjを算出する。
 図16は、図7のステップS193で検出される偏角θjの説明図である。図16を参照して、今、被写体の輪郭線上の3つの画素Pj-1,Pj,及びPj+1に注目する。また、輪郭線を反時計回りにスキャンするものとする。画素PjのベクトルVjは、画素Pjから次の画素Pj+1に向かうベクトルとして定義される。画素PjのベクトルVjの偏角θjは、画素Pjの1つ前の画素Pj-1のベクトルVj-1に対してベクトルVjがなす角度として定義される。反時計回りの偏角θjの符号は正であり、時計回りの偏角θjの符号は負である。
 図7に戻って、ステップS195にて、MCU3は、抽出した輪郭線の変曲点を検出する。変曲点は、輪郭線の向きが変化する点であり、凸点と凹点とが定義される。
 図17は、図7のステップS195で検出される変曲点の説明図である。図17を参照して、抽出した輪郭線21の向きが変化する点として、変曲点I0~I8が挙げられる。変曲点I0,I2,I4,I6及びI8は凸点である。変曲点I1,I3,I5及びI7は凹点である。
 図7に戻って、ステップS197にて、MCU3は、抽出した輪郭線(輪郭画像)の形状(グー、チョキ、パー、不定)を判定する。ステップS199にて、MCU3は、抽出した輪郭線(輪郭画像)の回転を検出して、リターンする。
 ここで、輪郭検出モードでは、図2のステップS717では、MCU3は、ステップS191~S199の結果(輪郭画像の重心座標、面積、形状、回転角度、及び、回転方向)を電子機器11のコンピュータ13に送信する。
 図8は、図7のステップS195の変曲点の検出処理の流れの一例を示すフローチャートである。図8を参照して、ステップS221にて、MCU3は、変数DA,ADA,j,及びCF[j]に0を代入する。ステップS223にて、MCU3は、図7のステップS193で検出された輪郭線上の画素Pjの偏角θjをメモリ9から取得する。ステップS225にて、MCU3は、変数DAの現在の値に偏角θjを加算して、変数DAに代入する。ステップS227にて、MCU3は、変数DAの絶対値を求めて、変数ADAに代入する。
 ステップS229にて、MCU3は、変数ADAの値が135度になったか否かを判断し、135度の場合輪郭線の向きが変わったと判断して、画素Pjを変曲点とみなしてステップS231に進み、それ以外はステップS237に進む。ステップS231では、MCU3は、変数DAの符号が正か否かを判断し、正の場合ステップS233に進み、負の場合ステップS235に進む。ステップS233では、MCU3は、凸凹フラグCF[j]に、変曲点が凸点であることを示す01を代入する。一方、ステップS235では、MCU3は、変曲点が凹点であることを示す10を代入する。
 ステップS236にて、MCU3は、変数DAに0を代入する。ステップS237にて、MCU3は、変数jを1つインクリメントする。ステップS239にて、MCU3は、変数jの値が、値Jと等しくなったか否かを判断し、j=Jの場合リターンし、それ以外はステップS223に進む。
 図9は、図7のステップS197の輪郭画像の形状を判定する処理の流れの一例を示すフローチャートである。図9を参照して、ステップS261にて、MCU3は、輪郭線に関する情報を算出する。ステップS263にて、MCU3は、輪郭画像から手の指先に相当する画素を検出する。
 再び、図17を参照して、凸点I0,I2,I4,I6及びI8を総称して、凸点As(s=0,1,…,S)と表記し、凹点I1,I3,I5及びI7を総称して、凹点Bt(t=0,1,…,T)と表記する。MCU3は、凸点Asから一定画素数Npだけ離れて位置する2つの画素を結ぶ線分23を求め、凸点Asから線分23に下ろした垂線25の長さLvを算出する。MCU3は、長さLvが、所定値CLを超えている場合に、その凸点Asを指先の候補とする。
 そして、MCU3は、指先の候補とした凸点Asの両側又は一方側に凹点Btが存在するか否かを判断し、存在する場合、その凸点Asを指先とみなす。
 また、MCU3は、「パー」及び「グー」を判定するのに必要な傾角θvを算出する。傾角θvは、指先とみなされた凸点Asから線分23に下ろした垂線25が、差分画像のX軸と平行な線27となす角である。
 図9に戻って、ステップS265にて、MCU3は、輪郭画像の形状が「パー」をした手の形状であるか否かを判定する。ステップS267にて、MCU3は、輪郭画像の形状が「チョキ」をした手の形状であるか否かを判定する。ステップS269にて、MCU3は、輪郭画像の形状が「グー」をした手の形状であるか否かを判定してリターンする。
 図10は、図9のステップS261の輪郭情報を算出する処理の流れの一例を示すフローチャートである。図10を参照して、ステップS291にて、MCU3は、変数XG,YG及びjに0を代入する。ステップS293にて、MCU3は、変数XGの現在の値に輪郭線上の画素PjのX座標XO[j]を加算したものを、変数XGに代入する。また、MCU3は、変数YGの現在の値に輪郭線上の画素PjのY座標YO[j]を加算したものを、変数XGに代入する。ステップS295にて、MCU3は、変数jを1つインクリメントする。ステップS297にて、MCU3は、変数jの値が値Jになったか否かを判断し、値Jになった場合ステップS299に進み、それ以外はステップS293に進む。
 ステップS299にて、MCU3は、変数XGの値を値Jで除したものを、変数Xgに代入する。また、MCU3は、変数YGの値を値Jで除したものを、変数Ygに代入する。座標(Xg,Yg)は、輪郭画像の重心座標を示す。
 ステップS301にて、MCU3は、変数j,LS及びL[j]に0を代入する。ステップS303にて、MCU3は、次式により、重心座標(Xg,Yg)と輪郭線上の各画素Pjの座標(XO[j],YO[j])との間の距離L[j]を算出する。
 L[j]←√((Xg-XO[j])+(Yg-YO[j])
 ステップS305にて、MCU3は、変数LSの現在の値に変数L[j]の値を加算したものを、変数LSに代入する。ステップS307にて、MCU3は、次式により、重心座標(Xg,Yg)と輪郭線上の各画素Pj座標(XO[j],YO[j])とを結ぶ線分がX軸と平行な線となす角、つまり、傾角θc[j]を算出する。この場合、小数点以下の角度は切り捨てる。
 θc[j]←tan-1((YO[j]-Yg)/(XO[j]-Xg))
 ステップS309にて、MCU3は、傾角θc[j]及び距離L[j]に基づいて、回転テーブルを作成する。
 図18は、図10のステップS309で作成される回転テーブルの例示図である。図18を参照して、MCU3は、輪郭線上の画素Pjの傾角θc[j]と距離L[j]とを関連付けて、回転テーブルを作成する。
 図10に戻って、ステップS311にて、MCU3は、変数jを1つインクリメントする。ステップS313にて、MCU3は、変数jの値が値Jになったか否かを判断し、値Jになった場合ステップS315に進み、それ以外はステップS303に進む。ステップS315にて、MCU3は、変数LSの値を値Jで除することにより、距離L[j]の平均値AVLを算出する。ステップS317にて、MCU3は、輪郭線及び輪郭線内の画素を計数して、輪郭画像の面積を算出する。ステップS319にて、MCU3は、線形補間により、図18の回転テーブルを完成する。つまり、回転テーブルには、ステップS307で算出された傾角θc[j]及びステップS303で算出された距離L[j]が代入されるが、必ずしも、回転テーブルの全ての傾角及び距離の欄が埋まるわけではない。そこで、回転テーブルにおいて、空欄がある場合、その前後の距離を用いて、線形補間により、その空欄を埋めていく。なお、線形補間は例示であり、他の補間を行なうこともできる。
 図11は、図9のステップS263の指先を検出する処理の流れの一例を示すフローチャートである。図11を参照して、ステップS341にて、MCU3は、変数j及びFP[j]に0を代入する。ステップS343にて、MCU3は、フラグCF[j]が凸点を示す01にセットされているか否かを判断し、肯定的判断の場合ステップS345に進み、否定的判断の場合ステップS349に進む。
 ステップS345にて、MCU3は、凸点である画素Pjの両側又は一方側に、フラグCF[j]に凹点を示す10がセットされている画素が存在するか否かを判断し、存在する場合画素Pjを指先候補とみなしてステップS347に進み、存在しない場合ステップS349に進む。ステップS347にて、MCU3は、フラグFP[j]に画素Pjが指先候補であることを示す1をセットする。
 ステップS349にて、MCU3は、変数jを1つインクリメントする。ステップS351にて、MCU3は、変数jの値が値Jになったか否かを判断し、値Jになった場合ステップS353に進み、それ以外はステップS343に進む。
 ステップS353にて、MCU3は、変数j,q,TF[j],θv[q],XT,YT,Q及びθvに0を代入する。ステップS355にて、MCU3は、フラグFP[j]に指先候補を示す1がセットされているか否かを判断し、肯定的判断の場合ステップS357に進み、それ以外はステップS371に進む。
 ステップS357にて、MCU3は、画素Pj+Npと画素Pj-Npとを結ぶ線分23に画素Pjから下ろした垂線25の長さLvを算出する(図17参照)。ステップS359にて、MCU3は、長さLvが所定値CLを超えているか否かを判断し、超えている場合画素Pjを指先とみなしてステップS361に進み、それ以外はステップS371に進む。
 ステップS361にて、MCU3は、指先フラグTF[j]に画素Pjが指先であることを示す1をセットする。ステップS363にて、MCU3は、変数XT[q]に画素PjのX座標を代入する。また、MCU3は、変数YT[q]に画素PjのY座標を代入する。座標(XT[q],YT[q])は、指先の座標である。ステップS365にて、MCU3は、垂線25の傾角θvを算出する(図17参照)。ステップS367にて、MCU3は、変数θv[q]に傾角θvを代入する。傾角θv[q]は、座標(XT[q],YT[q])で示される指先に対応する指の傾角である。ステップS369にて、MCU3は、変数qを1つインクリメントする。
 ステップS371にて、MCU3は、変数jを1つインクリメントする。ステップS373にて、MCU3は、変数jの値が値Jになったか否かを判断し、値Jになった場合ステップS375に進み、それ以外はステップS355に進む。ステップS375にて、MCU3は、変数Qに変数qの値を代入してリターンする。変数Qの値は、検出された指先の数を表す。
 図12は、図9のステップS265の「パー」を判定する処理の流れの一例を示すフローチャートである。図12を参照して、ステップS401にて、MCU3は、変数Qの値(指先の数)が3以上か否かを判断し、3以上の場合ステップS403に進み、それ以外はリターンする。ステップS403にて、MCU3は、変数q及びmに0を代入する。ステップS405にて、MCU3は、配列θv[q]と配列θv[q+1]との差の絶対値を算出し、変数θdに代入する。変数θdは、隣り合う指と指とがなす角度を表す。
 ステップS407にて、MCU3は、変数θdの値が100度未満か否かを判断し、肯定的判断の場合ステップS409に進み、否定的判断の場合ステップS411に進む。ステップS409にて、MCU3は、変数mを1つインクリメントする。ステップS411にて、MCU3は、変数qを1つインクリメントする。
 ステップS413にて、MCU3は、変数qの値が値Qになったか否かを判断し、値Qになった場合ステップS415に進み、それ以外はステップS405に進む。
 ステップS415では、MCU3は、変数mの値が、6以下3以上であるか否かを判断し、肯定的判断の場合手の形状が「パー」であると判断してステップS417に進み、否定的判断の場合リターンする。変数mの値は、隣り合う指と指とがなす角度θdが100度未満のケースの発生回数である。ステップS417では、MCU3は、フラグSHを「パー」を示す01にセットして、図7のステップS199に進む。
 図13は、図9のステップS267の「チョキ」を判定する処理の流れの一例を示すフローチャートである。図13を参照して、ステップS441にて、MCU3は、変数Qの値(指先の数)が2又は3の場合ステップS443に進み、それ以外はリターンする。
 ステップS443にて、MCU3は、変数q,p及びSHに0を代入する。ステップS445にて、MCU3は、輪郭画像の重心座標(Xg,Yg)と指先の座標(XT[q],YT[q])との間の距離Lgt0を算出する。ステップS447にて、MCU3は、距離Lgt0が平均値AVL(図10のステップS315参照)に1.1を乗じたもの以上か否かを判断し、つまり、距離Lgt0が平均値AVLの110%以上か否かを判断し、肯定的判断の場合ステップS449に進み、否定的判断の場合ステップS459に進む。
 ステップS449にて、MCU3は、輪郭画像の重心座標(Xg,Yg)と指先の座標(XT[q+1],YT[q+1])との間の距離Lgt10を算出する。座標(XT[q+1],YT[q+1])の指先は、座標(XT[q],YT[q])の指先の隣の指先である。ステップS451にて、MCU3は、距離Lgt1が値AVLに1.1を乗じたもの以上か否かを判断し、つまり、距離Lgt1が平均値AVLの110%以上か否かを判断し、肯定的判断の場合ステップS453に進み、否定的判断の場合ステップS459に進む。
 ステップS453では、MCU3は、配列θv[q]と配列θv[q+1]との差の絶対値(つまり、隣あう指と指とがなす角度)を算出し、変数θdに代入する。ステップS455にて、MCU3は、変数θdの値が90度未満か否かを判断し、肯定的判断の場合ステップS457に進み、否定的判断の場合ステップS459に進む。ステップS457にて、MCU3は、変数pを1つインクリメントする。
 ステップS459にて、MCU3は、変数qを1つインクリメントする。ステップS461にて、MCU3は、変数qの値が値Qになったか否かを判断し、値Qになった場合ステップS463に進み、それ以外はステップS445に進む。ステップS463にて、MCU3は、変数pの値が1又は2の場合手の形状が「チョキ」と判断してステップS465に進み、それ以外はリターンする。ステップS465では、MCU3は、フラグSHを「チョキ」を示す10にセットして、図7のステップS199に進む。
 図14は、図9のステップS269の「グー」を判定する処理の流れの一例を示すフローチャートである。図14を参照して、ステップS491にて、MCU3は、変数Qの値(指先の数)が2以上か否かを判断して、肯定的判断の場合ステップS493に進み、否定的判断の場合ステップS503に進む。
 ステップS493にて、MCU3は、変数jに0を代入する。ステップS495にて、MCU3は、距離L[j](図10のステップS303参照)が、平均値AVL(図10のステップS315参照)に0.6を乗じたもの以上であり、かつ、値AVLに1.4を乗じたもの以下であるか否かを判断し、つまり、距離L[j]が、平均値AVLの60%以上であり、かつ、平均値AVLの140%以下であるか否かを判断し、肯定的判断の場合ステップS497に進み、否定的判断の場合ステップS503に進む。
 ステップS499にて、MCU3は、変数jの値が値Jになったか否かを判断し、値Jになった場合手の形状が「グー」と判断しステップS501に進み、それ以外はステップS495に進む。ステップS501にて、MCU3は、フラグSHを「グー」を示す11にセットしてリターンする。一方、ステップS503では、MCU3は、フラグSHを「不定」を示す00にセットしてリターンする。
 図15は、図7のステップS199の輪郭画像の回転を検出する処理の流れの一例を示すフローチャートである。図15を参照して、ステップS521にて、MCU3は、変数Mに0を代入し、変数RAにFFFFhを代入する。
 ステップS523にて、MCU3は、現在の回転テーブル(図18参照)からM度の傾角に対応する距離を取得する。ステップS525にて、前回の回転テーブル(図18参照)から0度の傾角に対応する距離を取得する。ステップS527にて、MCU3は、ステップS523で取得した距離とステップS525で取得した距離との差の絶対値が一定範囲内の場合、両者が一致しているとみなして、ステップS529に進み、それ以外はステップS531に進む(図19参照)。ステップS529にて、MCU3は、変数RAに変数Mの値を代入する。
 ステップS531にて、MCU3は、現在の回転テーブル(図18参照)から(360-M)度の傾角に対応する距離を取得する。ステップS533にて、前回の回転テーブル(図18参照)から0度の傾角に対応する距離を取得する。ステップS535にて、MCU3は、ステップS531で取得した距離とステップS533で取得した距離との差の絶対値が一定範囲内の場合、両者が一致しているとみなして、ステップS537に進み、それ以外はステップS539に進む。ステップS537では、MCU3は、変数RAに、変数Mの値に(-1)を乗じた値を代入する。
 ステップS539にて、MCU3は、変数Mを1つインクリメントする。ステップS561にて、MCU3は、変数RA値がFFFFhであるか否かを判断し、肯定的判断の場合ステップS563に進み、否定的判断の場合リターンする。ステップS563にて、MCU3は、変数Mの値が360(回転テーブルに格納されている傾角の数)になったか否かを判断し、360になった場合リターンし、それ以外はステップS523に進む。
 ここで、図19を参照して、変数RAの値は、被写体の輪郭画像の重心座標と輪郭線上の画素Pjとを結ぶ線分の長さL[j]を、その線分が所定の基準線(X軸に平行な線)に対してなす角度θc[j]の関数100,102として表したときの、現在と前回との位相差である。この位相差の絶対値は輪郭画像の回転角度を表し、この位相差の符号は回転方向を表す。
 また、上記ステップS523及びS525の処理は、回転テーブルを上欄から下欄に向かって処理(スキャン)していることを意味する。一方、上記ステップS531及びS533の処理は、回転テーブルを下欄から上欄に向かって処理(スキャン)していることを意味する。そして、双方向へのスキャンにおいて、現在の距離が前回の距離と早く一致したときの位相差を輪郭画像の回転角としている。
 さて、以上のように、本実施の形態によれば、被写体とイメージセンサ5との間の距離に応じて、画像処理のモードが切り替えられるので、遠近に応じて、自動的に画像処理を異ならせることができる。
 このため、被写体がイメージセンサ5から近くに存在する場合の画像処理を、被写体がイメージセンサ5から比較的遠くに存在する場合の画像処理と異ならせることを要求する電子機器11に、容易に対応可能となる。
 また、イメージセンサ5として、比較的低解像度のものを採用でき、コストを削減できる。近くの被写体に対しては、低解像度であっても、画像処理により、その被写体の詳細な解析が可能であり、十分実用的な結果を得ることができる。一方、比較的遠くの被写体に対しては、低解像度の場合、被写体が近くに存在する場合と同じ画像処理により、被写体が近くに存在する場合と同等の精度の結果を得ることは困難である。従って、低解像度で、遠近に関係なく画像処理が同じであれば、比較的遠くにある被写体に対しては適用不可能であり、遠近双方に対応するためには、高解像度の撮影装置を採用せざるをえない。しかし、比較的遠くの被写体に対して、被写体が近くに存在する場合と異なる画像処理により、低解像度であっても十分実用的な結果を得ることもできる。このように、遠近に応じて、画像処理を異ならせることにより、低解像度のイメージセンサ5によって、遠近双方の被写体に対応可能となる。
 具体的には、近距離のための画像処理である輪郭検出モードでは、被写体の形態を認識する処理等が実行される。比較的低解像度の画像からでも、形態の認識は十分可能である。仮に、遠距離のための画像処理のモードにおいて、輪郭検出モードと同じ画像処理を行なっても、低解像度の画像からは、被写体の形態を精度良く認識することは困難である。しかし、遠距離のための動体検出モードでは、輪郭検出処理とは異なる手法により動体を検出する(図6)。この手法による動体の検出は、比較的低解像度の画像からも十分可能である。その結果、遠近双方において、比較的低解像度のイメージセンサ5を採用できるので、コストを削減できる。
 さらに、近距離用のセンサと遠距離用のセンサとを別個に設ける必要がなく、コストを削減できる。つまり、1つの画像処理モジュール1だけで、遠近双方の画像処理を行なうことができる。
 ここで、近距離で被写体の形態を認識するためのセンサ(形態センサ)と遠距離で動体を検出するためのセンサ(動体センサ)とを設けることを想定する。
 このような場合、通常、形態センサとしては比較的高解像度の撮影装置が採用され、低解像度の撮影装置と比べて高価である。また、それに応じて、高解像度の撮影装置の制御装置(CPUなど)も高価になる。さらに、高解像度の画像では、処理量が多くなり、高速に出力結果を要求される場合は対応困難になる。
 また、このような場合、通常、動体センサとしては、焦電センサが採用される。焦電センサは、比較的低解像度の撮影装置より安価な場合もあるが、室温の変化を検出するものであるので、変化の発生は検知できるが、物体の座標を検出することができない。また、焦電センサでは、物体を検知して、その後、その物体が動かない場合は、その物体の存在を検知できない。
 以上のように、近距離のための形態センサと遠距離のための動体センサとを設ける場合には、本発明にはない不利益を伴うが、そのような不利益がない点で本発明は有利である。
 さらに、本実施の形態では、動体を追跡して、動体をターゲットとした処理ないしは制御を行なうことができる。例えば、動体検出モードにおいて、動体の追跡結果を受けて、電子機器の一部又は全部を常に動体に向くように制御できる。もちろん、このような処理は輪郭検出モードでも可能である。
 さらに、本実施の形態では、第1閾値THH(図6のステップS153参照)を設けているので、画素値の変化の頻度が高い動き、例えば、テレビジョンのちらつき等、周期的な比較的周波数の高い動きをノイズとして除去できる。また、第2閾値THL(図6のステップS153参照)を設けているので、画素値の変化の頻度が低い動き、例えば、撮影環境(撮影空間やイメージセンサ5の状態)の変化から発生した画像上のノイズを除去できる。
 さらに、本実施の形態によれば、電子機器11は、輪郭検出モードにより、被写体の形状(グー、チョキ、パー)を入力とした情報処理を実行することができる。
 さらに、本実施の形態によれば、指先と水かきとの間の画素に基づいて指を特定し(図11のステップS357及びS359、図17参照)、輪郭画像の重心により指を特定しないので、重心により指を特定する場合と比較して、精度良く指を特定でき(図11)、ひいてはより精度良く手の形状を判定できる(図12、図13)。一般に、輪郭画像の重心と、被写体の重心と、は一致しない場合も多く、この場合に、重心により指を特定すると、認識の精度が低くなる。
 また、指先と水かきとの間の画素に基づいて得られた、隣り合う指と指とがなす角度だけでなく、重心から指先に相当する画素までの距離に基づいて、手の形状を判断するので(図13のステップS445~S451)、より多様な手の形状を判定できる(図13)。例えば、手の形状が「チョキ」であることを判定できる。
 また、重心から輪郭線上の画素までの距離を求めるといった簡単な計算で(図10のステップS303)、手の形状を判定できる(図14)。例えば、重心から輪郭線上の画素までの距離が、一定範囲内の場合に、手の形状が「グー」であることを判定できる。
 さらに、本実施の形態によれば、電子機器11は、輪郭検出モードにより、被写体の回転(図15参照)を入力とした情報処理を実行することができる。
 この場合、上記のように、被写体の輪郭画像の重心座標と輪郭線上の画素Pjとを結ぶ線分の長さL[j]を、その線分が所定の基準線(X軸に平行な線)に対してなす角度θc[j]の関数として表したときの、現在と前回との位相差を求めることにより、簡易、かつ、精度よく、手の回転角度を検出できる。
 また、差分画像上の被写体の面積は、イメージセンサ5と被写体との間の距離に相関するので、面積により、イメージセンサ5と被写体との間の距離を容易に判断できる。
 また、被写体が遠くにあれば、赤外発光ダイオード7の光が届かない、あるいは、届いても反射光が弱くイメージセンサ5に検出されないので、赤外発光ダイオード7の発光時及び消灯時に関係なく、撮影画像には、遠くの物体は写り込まない。一方、赤外発光ダイオード7の発光時のみ、近くの物体は、その光を反射し、撮影画像に写り込む。よって、差分により背景成分が除去されるので、赤外発光ダイオード7が照射した光を反射した物体だけが、差分画像に現われる。このように、差分といった簡単な処理で、近くの物体の像のみを抽出できる。
 さらに、動体検出モードの画像処理(動体検出処理)では、赤外発光ダイオード7の発光は不要なところ、輪郭検出モードの画像処理(輪郭検出処理)で要求される赤外発光ダイオード7を、画像処理モードの切り替えのために、動体検出モードで共用している。その結果、コストを削減できる。
 また、動体検出モードでの画像処理のモードを切り替えるための撮影周期を、輪郭検出モードでの輪郭検出及び動体検出モードでの動体検出のための撮影処理の周期より短くしているので、消費電力を抑制することができる。画像処理のモードを切り替えるための判断は、画像処理(輪郭検出及び動体検出)と同等の周期で行なう必要はなく、実質的に性能に影響はない。
 さらに、本実施の形態では、撮影された被写体の画像を処理して(輪郭検出モードでは、輪郭画像の重心座標、面積、形状、回転角度、及び回転方向の算出、動体検出モードでは、動体の検出(動体フラグ)、動体の座標(TX,TY)の算出、及び撮影空間の輝度の算出)、その処理結果を、電子機器11のコンピュータ13に出力する。このため、外部のコンピュータ13は、この画像処理モジュール1から入力された処理結果をそのまま利用できる。その結果、外部のコンピュータ13による画像処理を不要とし、そのコンピュータ13のプログラマの負担を軽減することができる。また、この画像処理モジュール1は、撮影及び画像処理だけを行なうモジュールとして提供されるので、その処理結果を利用するコンピュータ13あるいはそのコンピュータ13を搭載する外部機器11は特定のものに限定されず、この画像処理モジュール1は、高い汎用性を持つ。
 (変形例)
 実施の形態の変形例では、MCU3の設定を輪郭検出モードに固定する。輪郭画像がMCU3に設定された割込条件を満足すると、MCU3は、割込信号をコンピュータ13に出力する。上記実施の形態では、MCU3は、コンピュータ13の指示なしに、コンピュータ13にデータを送信することができない。これに対して、変形例では、コンピュータ13の指示がない場合であっても、輪郭画像が割込条件を満足した場合は、MCU3が、割込信号をコンピュータ13に送信する。このため、スタンバイ状態あるいはスリープ状態のコンピュータ13を、MCU3からの割込信号により、オペレーション状態にしたり、復帰させたりすることができる。
 図21は、本発明の実施の形態の変形例におけるMCU3の全体処理の流れの一例を示すフローチャートである。図22(a)~図22(c)は、変形例におけるMCU3とコンピュータ13との間の信号送受信の説明図である。
 図21を参照して、ステップS751にて、MCU3は、レジスタや変数等の初期化を実行する。ステップS753にて、MCU3は、データ出力線の電位をハイレベルに設定する(図22(c)参照)。このデータ出力線は、MCU3とコンピュータ13とを接続する。ステップS755にて、MCU3は、一定時間間隔でタイマ割込みを発生させるため、タイマをセットする。
 ステップS757にて、MCU3は、コンピュータ13が出力するスレイブセレクト信号の立下りエッジを検出したか否かを判断し、検出した場合ステップS761に進み、それ以外はステップS759に進む。ステップS759にて、MCU3は、タイマ割込みが発生したか否かを判断し、発生した場合ステップS765に進み、それ以外はステップS757に戻る。
 ステップS761では、MCU3は、タイマを解除する。ステップS763にて、MCU3は、コンピュータ13から開始コマンドを受信したか否かを判断し、受信した場合ステップS765に進み、それ以外はステップS763に戻る。なお、コンピュータ13は、MCU3へ開始コマンドを送信した後、スレイブセレクト信号をハイレベルにする。
 ステップS765では、MCU3は、イメージセンサ5を制御する。この場合の処理は、図3のステップS7~S27の処理と同じである。ステップS767にて、MCU3は、輪郭検出処理を実行する。この処理は、図2のステップS711の輪郭検出処理と同じである。
 ステップS771にて、MCU3は、ステップS767で検出した輪郭画像が、設定された割込条件を満足しているか否かを判断し、満足している場合ステップS773に進み、満足していない場合ステップS775に進む。ステップS773では、MCU3は、コンピュータ13に割込信号を出力する。ただし、この場合に、MCU3は、コンピュータ13にコマンドを出力することもできる。
 この割込条件は、MCU3のレジスタ(図示せず)に予め設定される。もちろん、コンピュータ13によって、割込条件を変更することができる。本実施の形態では、輪郭画像が「グー」のときのみ割込信号を生成する割込条件、輪郭画像が「チョキ」のときのみ割込信号を生成する割込条件、輪郭画像が「パー」のときのみ割込信号を生成する割込条件、輪郭画像が「グー」又は「チョキ」のときに割込信号を生成する割込条件、輪郭画像が「グー」又は「パー」のときに割込信号を生成する割込条件、輪郭画像が「チョキ」又は「パー」のときに割込信号を生成する割込条件、輪郭画像が「グー」、「チョキ」又は「パー」のときに割込信号を生成する割込条件、並びに、輪郭画像が「グー」、「チョキ」及び「パー」のいずれにおいても割込信号を生成しない割込条件を設定可能である。
 ステップS775にて、MCU3は、データ出力線の電位をローレベルに設定する(図22(c)参照)。ステップS777にて、MCU3は、コンピュータ13が出力するスレイブセレクト信号(図22(a)参照)の立下りエッジを検出したか否かを判断し、検出した場合ステップS781に進み、検出していない場合ステップS779に進む。ステップS779では、MCU3は、タイマ割込みがあった場合ステップS791に進み、それ以外はステップS777に進む。
 ステップS781では、MCU3は、タイマを解除する。ステップS783にて、MCU3は、コンピュータ13から開始コマンドを受信したか否かを判断し、受信した場合ステップS789に進み、それ以外はステップS785に進む。なお、コンピュータ13は、MCU3へ開始コマンドを送信した後、スレイブセレクト信号をハイレベルにする。ステップS785にて、MCU3は、コンピュータ13からのリードコマンド(図22(b)参照)を受信したか否かを判断し、受信した場合ステップS787に進み、受信していない場合ステップS783に戻る。なお、リードコマンドは、MCU3とコンピュータ13とを接続するデータ入力線を介して与えられる。ステップS787では、MCU3は、ステップS767の結果データ(輪郭画像の重心座標、面積、形状、及び回転角度)を、データ出力線を介してコンピュータ13に送信する(図22(c)参照)。なお、コンピュータ13は、MCU3からデータを受け取った後、スレイブセレクト信号をハイレベルにする。
 ステップS789にて、MCU3は、タイマをセットする。ステップS791にて、MCU3は、データ出力線の電位をハイレベルに設定して(図22(c)参照)、ステップS765に戻る。
 以上のように、コンピュータ13がオペレーション状態のときは、MCU3は、コンピュータ13の制御(スレイブセレクト信号、開始コマンド、及び、リードコマンド)を受けて動作する。ただし、コンピュータ13がスタンバイないしはスリープ状態の場合は、MCU3は、タイマ割込みにより、イメージセンサ5の制御(ステップS765)、輪郭検出処理(ステップS767)、及び、割込信号生成処理(ステップS771及びS773)を実行する。
 さて、以上のように、変形例では、電子機器11のコンピュータ13がスタンバイ状態あるいはスリープ状態の場合であっても、輪郭画像、つまり、撮影対象物(変形例では「手」)が割込条件を満足することによって、コンピュータ13をオペレーション状態にしたり、復帰させたりすることができる。すなわち、撮影対象物を制御すること(上記例では、ユーザが手の形状を割込条件に合致させること)によって、スタンバイ状態やスリープ状態のコンピュータ13をオペレーション状態にしたり、復帰させたりすることができる。
 ここで、変形例は、例えば、カーナビゲーションシステムの操作に有用である。一般に、カーナビゲーションシステムは、ドライバーがディスプレイのタッチパネルを操作することによりコントロールされる。この場合、腕や手だけを動かして操作するのは困難な場合も多く、上半身を動かす必要もあり、必ずしも安全性が高いとは言えない場合もある。また、カーナビゲーションシステムが、テレビジョン装置やオーディオ装置と一体になっているものも多い。このように、近年のカーナビゲーションは高機能のものも多く、その全ての操作をタッチパネルで行なうと、益々安全性が低下する。
 しかしながら、本発明の変形例を適用することにより、ディスプレイに表示されたアイコンや地図画像等を非接触で操作できるので、ドライバーは、腕や手だけを動かして操作することができ、上半身を動かす必要もないため、安全性の向上に寄与できる。この場合、カーナビゲーションシステムは電子機器11に対応し、カーナビゲーションシステムのコンピュータはコンピュータ13に対応する。以下、変形例をカーナビゲーションシステムに適用する場合の応用例を挙げる。
 例えば、カーナビゲーションシステム11のコンピュータ13は、手の座標の移動方向により、ディスプレイに表示されたアイコンを選択する。この場合、コンピュータ13は、選択されたアイコンの色彩を変更する。この場合、コンピュータは、一定時間以上、同一アイコンの選択状態が継続している場合に、選択が確定したと判断する。
 また、例えば、コンピュータ13は、手の座標に連動するカーソルをディスプレイに表示する。そして、コンピュータ13は、このカーソルが、アイコンに重なったときに、そのアイコンが選択されたと判断する。この場合も、もちろん、選択されたアイコンの色彩を変更してもよい。この場合、コンピュータは、一定時間以上、カーソルが同一アイコンに継続して重なっている場合に、選択が確定したと判断する。
 ここで、コンピュータ13は、所定の手の形状を、選択確定のコマンドとして認識することもできる。例えば、一本の指を立てた手が撮影された場合に、それを選択確定のコマンドとすることができる。上記では、輪郭画像が、一本の指を立てた手であるか否かを判断する機能(コンピュータプログラム)を搭載していないが、もちろん搭載することもできる。
 さらに、例えば、コンピュータ13は、手の座標の移動方向に応じた方向に、ディスプレイに表示された地図をスクロールすることができる。この場合、コンピュータ13は、一定の初速度で、地図をスクロールし、一定距離の移動後に停止させる。また、コンピュータ13は、手の座標の移動速度に応じた初速度で、手の座標の移動方向に応じた方向に、地図をスクロールさせることもできる。この場合、コンピュータ13は、一定の摩擦係数を想定して、スクロールを停止する。ただし、コンピュータ13は、スクロール途中であっても、所定の手の形状を、スクロール停止のコマンドとして認識することもできる。例えば、「パー」をした手が撮影された場合に、それをスクロール停止のコマンドとすることができる。
 さらに、例えば、コンピュータ13は、所定の手の形状及び面積をコマンドとして、地図の拡縮を行なうことができる。この場合、コンピュータ13は、「グー」の形状の面積が大きくなると、地図を拡大し、「グー」の形状の面積が小さくなると、地図を縮小する。これとは逆に、コンピュータ13は、「グー」の形状の面積が小さくなると、地図を拡大し、「グー」の形状の面積が大きくなると、地図を縮小することもできる。そして、コンピュータ13は、「パー」の手の形状が撮影された場合に、拡縮操作を停止する。
 また、例えば、コンピュータ13は、画像処理モジュール1の結果データに基づいて、カーナビゲーションシステム11に搭載されたオーディオ装置の制御を行なうこともできる。以下、この場合の応用例を挙げる。もちろん、カーオーディオ装置単体に、変形例を適用することもできる。
 例えば、コンピュータ13は、ディスプレイに表示された楽曲リスト(垂直方向に楽曲が並んでいるものを想定する。)を、手の座標の移動方向に応じた方向に(垂直方向に限る。)、スクロールすることができる。この場合、コンピュータ13は、一定の初速度で、楽曲リストをスクロールし、一定距離の移動後に停止させる。また、コンピュータ13は、手の座標の移動速度に応じた初速度で、手の座標の移動方向に応じた方向に(垂直方向に限る。)、楽曲リストをスクロールさせることもできる。この場合、コンピュータ13は、一定の摩擦係数を想定して、スクロールを停止する。ただし、スクロール途中であっても、所定の手の形状を、スクロール停止のコマンドとして認識することもできる。例えば、「パー」をした手が撮影された場合に、それをスクロール停止のコマンドとすることができる。
 また、例えば、コンピュータ13は、楽曲リストのスクロールを停止する際に、ディスプレイの所定位置に、1楽曲名が停止するよう制御する。そして、コンピュータ13は、その所定位置に停止した楽曲が選択状態にあると認識する。そして、例えば、コンピュータ13は、所定の手の形状(例えば、「グー」)が撮影された場合に、その所定位置に停止した楽曲を再生する。
 さらに、例えば、コンピュータ13は、楽曲の再生中に、手の座標の移動方向に応じて(水平方向に限る。)、次の楽曲に進んだり、前の楽曲に戻ったりすることもできる。また、例えば、コンピュータ13は、楽曲の再生中に、手の回転角度に応じて、音量を制御することもできる。この場合、コンピュータ13は、ディスプレイに、手の回転角度に応じて回転するダイヤル画像を表示することもできる。
 また、例えば、コンピュータ13は、画像処理モジュール1の結果データに基づいて、カーナビゲーションシステム11に搭載されたテレビジョン装置の制御を行なうこともできる。この場合の操作例は、オーディオ装置の操作例と同様である。もちろん、車載テレビジョン受像機単体に、変形例を適用することもできる。
 さらに、例えば、コンピュータ13は、所定の形状の手(例えば、「チョキ」)が撮影された場合に、実行中の処理(例えば、ナビゲーション、音楽再生、テレビジョン映像表示)を中止して、メニュー画面に戻ることができる。
 また、コンピュータ13は、変形例による非接触の操作だけを受け付けるのではなく、タッチパネルによる操作も受け付けて、両者を併用することもできる。
 なお、本発明は、上記の実施の形態に限られるものではなく、その要旨を逸脱しない範囲で種々の態様において実施することが可能であり、例えば、以下のような変形も可能である。
 (1)実施の形態では、距離に応じて、画像処理モードを2つ搭載した。ただし、距離に応じて、3以上の画像処理モードを搭載することもできる。
 (2)MCU3は、輪郭検出モードでは、差分画像(解析対象差分画像)に基づいて、輪郭画像の重心座標、面積、形状、回転角度、及び回転方向を算出した。ただし、目的物はこれらに限定されるものではなく、例えば、MCU3は、差分画像に写り込んだ被写体の像の色彩の認識、その像の模様の認識、その像の回転量の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、差分画像に写り込んだ被写体としての動体の検出、及び/又は、被写体の存在の検出を行なうこともできる。
 また、MCU3は、動体検出モードでは、画像(解析対象画像)に基づいて、動体の検出(動体フラグ)、動体の座標(TX,TY)の算出、及び撮影空間の輝度の算出を行なった。ただし、目的物はこれらに限定されるものではなく、例えば、MCU3は、画像に写り込んだ被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、及び/又は、画像に写り込んだ被写体の像の輝度の算出を行なうことができる。なお、この場合、低解像度のイメージセンサによる解析が不可能な場合は、それに代えて、高解像度のイメージセンサを使用する。
 (3)実施の形態では、距離に応じて画像処理モードを自動的に切り替えた。ただし、上記変形例のように、電子機器11の仕様に応じて、MCU3の設定を輪郭検出モードに固定することもできるし、また、輪郭検出モードのみを搭載することもできる。
 この場合、撮影された被写体の画像を処理して(差分画像に写り込んだ被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、差分画像に写り込んだ被写体としての動体の検出、及び、被写体の存在の検出)、その処理結果を、外部のコンピュータ13に出力する。このため、当該外部のコンピュータ13は、この画像処理モジュールから入力された処理結果をそのまま利用できる。その結果、当該外部のコンピュータ13による画像処理を不要とし、そのコンピュータ13のプログラマの負担を軽減することができる。また、この画像処理モジュールは、撮影及び画像処理だけを行なうモジュールとして提供されるので、その処理結果を利用するコンピュータ13あるいはそのコンピュータ13を搭載する外部機器11は特定のものに限定されず、この画像処理モジュールは、高い汎用性を持つ。
 また、限定はされないが、画像処理モジュールに輪郭検出モードのみを搭載する場合、特に、被写体がイメージセンサ5に対して比較的近距離に位置している場合に有効である。なぜなら、赤外光を被写体に照射し、それをイメージセンサ5により撮影するからである。もちろん、これは、被写体がイメージセンサ5に対して比較的遠距離に位置している場合に、この画像処理モジュールを使用することを排除するものではない。この場合、例えば、赤外発光ダイオード7の発光強度を強くし、及び/又は、その数を増やす。
 さらに、この場合、上記の輪郭検出モードと同様の効果を奏する。もちろん、この場合、上記変形例の機能をそのまま搭載することもできる。
 また、電子機器11の仕様に応じて、MCU3の設定を動体検出モードに固定することもできるし、また、動体検出モードのみを搭載することもできる。
 この場合、撮影された被写体の画像を処理して(画像に写り込んだ被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、画像に写り込んだ被写体としての動体の検出、画像に写り込んだ撮影空間の輝度の算出、画像に写り込んだ被写体の像の輝度の算出、及び、被写体の存在の検出)、その処理結果を、外部のコンピュータ13に出力する。このため、当該外部のコンピュータ13は、この画像処理モジュールから入力された処理結果をそのまま利用できる。その結果、当該外部のコンピュータ13による画像処理を不要とし、そのコンピュータ13のプログラマの負担を軽減することができる。また、この画像処理モジュールは、撮影及び画像処理だけを行なうモジュールとして提供されるので、その処理結果を利用するコンピュータ13あるいはそのコンピュータ13を搭載する外部機器11は特定のものに限定されず、この画像処理モジュールは、高い汎用性を持つ。
 また、限定はされないが、画像処理モジュールに動体検出モードのみを搭載する場合、特に、被写体がイメージセンサ5に対して比較的遠距離に位置している場合に有効である。なぜなら、赤外発光ダイオード7を設けずに、室内光及び/又は外光を反射する被写体を撮影するからである。もちろん、これは、被写体がイメージセンサ5に対して比較的近距離に位置している場合に、この画像処理モジュールを使用することを排除するものではない。
 さらに、この場合、上記の動体検出モードと同様の効果を奏する。もちろん、この場合、上記変形例と同様に、MCU3は、画像の解析結果が所定の条件を満足した時に、割込信号又はコマンドを、信号線54及びコネクタ30を介して、外部のコンピュータ13に送信する機能を搭載することもできる。
 (4)図25に示すように、赤外光フィルタ64は、レンズユニット62の外部において、開口66を覆うように配置された。ただし、赤外光フィルタは、レンズユニット62の内部において、レンズ72とイメージセンサ5との間に配置することもできる。
 (5)上記では、メモリ9は、MCU3に内蔵された。ただし、メモリ9は、MCU3の外部に配置されてもよく、MCU3の内部及び外部の双方にメモリを設けることもできる。
 (6)上記では、イメージセンサ5は、差分画像を生成し出力した。ただし、イメージセンサ5は、赤外光の点灯時の画像(グレースケールでもよいし、カラーでもよい)及び消灯時の画像(グレースケールでもよいし、カラーでもよい)をMCU3に出力することもできる。この場合、MCU3が、点灯時画像と消灯時画像との差分画像を生成する。そして、MCU3は、その差分画像に基づいて、解析処理を行なうこともできるし、また、その差分画像を2値化して、解析処理を行なうこともできる。なお、赤外光の点灯時間及び消灯時間を1周期と考えると、MCU3は、この1周期ごとに、点灯時画像と消灯時画像との差分画像の生成処理及び解析処理を実行する。
 (7)上記では、MCU3は、イメージセンサ5から1画素ずつシリアルに入力される画素データDを順次2値化した。ただし、MCU3は、全ての画素データDをメモリ9に格納した後に2値化してもよい。もちろん、MCU3は、2値化せずに、解析処理を実行することもできる。
 (8)電子機器11のコンピュータ13が、画像処理モジュール1のMCU3から与えられた情報に基づいて行なう制御は、機械的・機構的な制御に限られず、ソフトウェア、画像、あるいは音声の制御であってもよい。
 (9)上記では、「グー」、「チョキ」、及び「パー」の形状を認識したが、これに限定されない。例えば、画像処理モジュール1は、一本の指を立てた手の形状を認識することもできる。
 (10)上記変形例では、いくつかの割込条件を挙げた。ただし、割込条件は、それらに限定されない。例えば、輪郭画像の座標の軌跡が所定条件を満足することを割込条件とすることができる。例えば、所定時間内に、輪郭画像の予め定められた異なる形状が検出されること(順番は問わない。)を割込み条件とすることができる(例えば、所定時間内に、輪郭画像の第1の形状(例えば「パー」)と第2の形状(例えば「チョキ」)とが検出されたことを割込条件とすることができる。)。例えば、所定時間内に、所定の順番で、輪郭画像の予め定められた異なる形状が検出されることを割込み条件とすることができる(例えば、輪郭画像の第1の形状(例えば「パー」)が検出された後、所定時間内に、輪郭画像の第2の形状(例えば「チョキ」)が検出されたことを割込条件とすることができる。)。また、これらの例を組み合わせて、割込条件とすることもできる。
 (11)上記変形例では、カーナビゲーションシステムへの適用例を挙げたが、これに限定されないことは言うまでもない。例えば、カーナビゲーションシステムのオーディオ装置と同様に、家庭用のオーディオ装置にも変形例を適用できる。また、例えば、カーナビゲーションシステムのテレビジョン装置と同様に、家庭用のテレビジョン受像機にも変形例を適用できる。
 (12)上記変形例では、画像処理モジュール1は、コンピュータ13からの指示があるときは、コンピュータ13の指示に同期して処理を行ない、コンピュータ13からの指示がないときは、タイマ割込みに同期して処理を行なった。ただし、画像処理モジュール1は、タイマ割込みにのみ同期して処理を行なうこともできる。
 (13)上記では、赤外発光ダイオード7のオン/オフをイメージセンサ5が制御した。ただし、トランジスタ44のベースをMCU3の制御端子に接続することにより、MCU3が、赤外発光ダイオード7のオン/オフを制御することもできる。もちろん、この場合でも、トランジスタ44を設けることなしに、赤外発光ダイオード7のアノードをMCU3の制御端子に接続して制御することもできる。
 (14)図6では、ステップS153で1回でも肯定的判断がされれば、動体フラグがオンにされた。ただし、変数k(ステップS157)の値が所定値(2以上の整数)を超えた場合に、動体フラグをオンにすることもできる。なお、所定値は実験的経験的に定められる。
 (15)図6では、イメージセンサ5からの画像(64×64画素)の全画素のうち、有効な変化が検出された画素の数kを計数した(ステップS157)。この応用例を次に示す。
 イメージセンサ5からの画像を所定数N(Nは2以上の整数)のブロックBL1~BLNに分割する(例えば、N=9)。ここで、ブロックBL1~BLNを総称して、ブロックBLnと表記する。そして、MCU3は、ブロックBLnごとに、有効な変化が検出された画素の数knを計数し、ブロックBLnごとの画素数knをコンピュータ13に送信する。そして、コンピュータ13は、画素数knが所定値CVを超えたブロックBLnにおいて、被写体の動きが検出されたと判断する。なお、所定値CVは実験的経験的に定められる。
 このように、ブロックBLnごとに、写り込んだ像の変化、つまり、被写体の動きを検出することができる。このため、コンピュータ13は、電子機器11又は電子機器11の一部を、像の変化(つまり被写体の動き)が検出されたブロックに対応する領域(実空間の)に向ける制御又は向けない制御を行なうことができる。また、コンピュータ13は、各ブロックに対応する各領域(実空間の)に向けた電子機器11の出力を、像の変化(つまり被写体の動き)が検出されたブロックに対応する領域に対して行う又は行なわない制御を行なうことができる。
 この応用例は、例えば、電子機器11が、天井へ埋め込んで使用する空気調和装置(エア・コンディショナ)である場合に適用できる。イメージセンサ5は、被写体を俯瞰撮影できる位置に設置される。例えば、イメージセンサ5は、空気調和装置とともに天井に取り付けられ(例えば、空気調和装置の化粧パネル等)、あるいは、空気調和装置の近傍に取り付けられる。空気調和装置のコンピュータ13は、空気調和装置の垂直フラップ及び/又は水平フラップを制御して、被写体の動きが検出されたブロックに対応する領域に風向きを調整する。また、空気調和装置のコンピュータ13は、被写体の動きが検出されたブロックに対応する領域への風の出力を行い、一方、被写体の動きが検出されなかったブロックに対応する領域への風の出力を停止する。
 なお、垂直フラップは、垂直軸の回りに回転するフラップであり、水平方向の風向きを調整する。水平フラップは、水平軸の回りに回転するフラップであり、垂直方向の風向きを調整する。なお、これらのフラップを風向調整機構あるいは風向調整板と呼ぶ事もある。
 また、天井に設置される電子機器11は、空気調和装置に限定されるものではない。例えば、照明機器である。もちろん、電子機器11及びイメージセンサ5の設置場所は天井に限定されず、その性質、用途に応じて、任意の場所に設置できる。
 なお、イメージセンサ5により俯瞰撮影を行なう場合、水平方向からの撮影と比較して、複数の被写体が重なって写り込む頻度が少なく、複数の被写体の重なりの判断を省くこともできるので、簡易な処理により電子機器11を制御できる。その結果、天井に設置された電子機器11の制御に好適である。
 もちろん、複数の被写体の重なりの判断を行ってもよい。なお、水平方向から撮影すると、複数の被写体が1つの像として画像に存在することになる場合であっても(例えば、撮影手段の光軸上に、複数の被写体が存在する場合)、俯瞰撮影する場合は、それらが、分離した像として画像に存在することも多い。
 (16)画像処理モジュール1は、赤外発光ダイオード7を搭載した。ただし、赤外発光ダイオード7を搭載しないこともできる。この場合は、MCU3は、差分画像ではなく、通常の画像を処理する。
 (17)MCU3が行なう処理の全部又は一部をコンピュータ13が行なうこともできる。要するに、どちらがどの処理を行なうかは、仕様に応じて、任意に決定できる。
 (18)MCU3に各種の処理を行わせるためのプログラムを記述する処理ステップは、必ずしもフローチャートとして記載された順序に沿って時系列に処理する必要はなく、また、並列的あるいは個別に実行される処理も含むものである。
 (19)本明細書及び請求の範囲において、手段とは必ずしも物理的手段を意味するものではなく、各手段の機能がソフトウェアによって実現される場合も含む。さらに、1つの手段の機能が2つ以上の物理的手段により実現されても、もしくは2つ以上の手段の機能が1つの物理的手段により実現されてもよい。
 本発明は、家庭電化製品、エンターテインメント機器、セキュリティ機器、車載電子機器、ディスプレイ装置、及びパーソナルコンピュータ等の分野に利用可能である。
1…画像処理モジュール、3…MCU、5…イメージセンサ、7…赤外発光ダイオード、9…メモリ、11…電子機器、13…コンピュータ、30…コネクタ、44…トランジスタ、50,52…電源線、54…信号線、56…バス、58…基板、60…ハウジング、62…レンズユニット、64…赤外光フィルタ、66…開口、68…基台、70…筒状部材、72…凸レンズ、73…レンズホルダ、74…光軸、T1~T7…端子。
 以上、本発明を実施例により詳細に説明したが、当業者にとっては、本発明が本願中に説明した実施例に限定されるものではないということは明らかである。本発明は、特許請求の範囲の記載により定まる本発明の趣旨及び範囲を逸脱することなく修正及び変更態様として実施することができる。

Claims (31)

  1.  被写体を撮影する撮影手段による映像に対して画像処理を施す画像処理手段と、
     前記被写体と前記撮影手段との間の距離に応じて、前記画像処理のモードを切り替える切替手段と、を備える画像処理装置。
  2.  前記切替手段は、前記被写体と前記撮影手段との間の距離に応じて、前記画像処理のモードとして第1モードを設定し、前記被写体と前記撮影手段との間の距離が、前記第1モードの設定時より長い場合に、前記画像処理のモードとして第2モードを設定し、
     前記画像処理手段は、前記第1モードの設定時に、前記映像に写った前記被写体の形態を認識する処理、動きを検出する処理、座標を求める処理、及び面積を求める処理の全部又は一部を実行し、前記第2モードの設定時に、前記映像から、前記被写体としての動体を検出する処理、撮影空間の輝度を求める処理、及び前記被写体の存在を検出する処理の全部又は一部を実行する、請求項1記載の画像処理装置。
  3.  前記画像処理手段は、前記第2モードの設定時に、前記動体を検出して追跡する処理を実行する、請求項2記載の画像処理装置。
  4.  前記画像処理手段は、
     前記撮影手段による現在の画像と過去の画像との差分を算出する差分手段と、
     前記差分に基づいて、画素値の変化を検出する検出手段と、
     第1閾値及び前記第1閾値より小さい第2閾値を設定し、前記画素値の変化の頻度が前記第1閾値を超える場合又は前記第2閾値を下回る場合、その変化をノイズと判断し、前記頻度が前記第1閾値と前記第2閾値との間にある場合、その変化を実質的な変化と判断し、前記動体が存在すると判断する判断手段と、を含む請求項2又は3記載の画像処理装置。
  5.  前記画像処理手段は、前記第1モードの設定時に、前記被写体の形態としての形状を認識する処理を実行する、請求項2から4のいずれかに記載の画像処理装置。
  6.  前記画像処理手段は、前記被写体としての手の形状を認識し、
     前記画像処理手段は、
     前記撮影手段による画像から前記被写体の輪郭線を抽出し、その輪郭線の変曲点の画素と前記変曲点の次の変曲点の画素との間の画素に基づいて、指を特定する指特定手段と、
     所定の基準線に対する、前記指特定手段が特定した各指の傾き角を算出する傾角算出手段と、
     前記指特定手段が特定した、隣り合う指と指とがなす角度を、前記各指の前記傾き角に基づき算出する指角算出手段と、
     前記隣り合う指と指とがなす前記角度に基づいて、手の形状を判定する判定手段と、を含む請求項5記載の画像処理装置。
  7.  前記指特定手段は、
     前記被写体の輪郭線上にある画素から、指先に相当する画素を特定する手段を含み、
     前記画像処理手段は、
     前記被写体の輪郭画像の重心から前記指先に相当する前記画素までの距離を算出する手段をさらに含み、
     前記判定手段は、前記隣り合う指と指とがなす前記角度、及び、前記指先に相当する前記画素までの前記距離に基づいて、手の形状を判定する、請求項6記載の画像処理装置。
  8.  前記画像処理手段は、前記被写体としての手の形状を認識し、
     前記画像処理手段は、
     前記被写体の輪郭画像の重心から輪郭線上の各画素までの距離を算出する距離算出手段と、
     前記各画素までの前記距離に基づいて、手の形状を判定する判定手段と、を含む請求項5から7のいずれかに記載の画像処理装置。
  9.  前記画像処理手段は、前記第1モードの設定時に、前記被写体の動きとしての回転動作を検出する処理を実行する、請求項2から8のいずれかに記載の画像処理装置。
  10.  前記画像処理手段は、
     前記被写体の輪郭画像の重心と輪郭線上の画素とを結ぶ線分の長さを算出する長さ算出手段と、
     前記線分が、所定の基準線に対してなす角度を算出する角度算出手段と、
     前記長さを前記角度の関数として表したときの位相差を、前記被写体の回転角度とする回転検出手段と、を含む請求項9記載の画像処理装置。
  11.  前記切替手段は、
     光を発光する発光手段の発光時の前記撮影手段による前記映像と前記発光手段の消灯時の前記撮影手段による前記映像との差分画像に写り込んだ前記被写体の面積を算出する面積算出手段と、
     前記被写体の前記面積に基づいて、前記被写体と前記撮影手段との間の距離を判断し、前記画像処理のモードを設定する設定手段と、を含む請求項1から10のいずれかに記載の画像処理装置。
  12.  前記画像処理手段は、前記画像処理のモードとしての第1モードでは、光を発光する発光手段の発光時の前記撮影手段による前記映像と前記発光手段の消灯時の前記撮影手段による前記映像との第1差分画像に前記画像処理を施し、前記画像処理のモードとしての第2モードでは、前記発光手段の消灯時の前記撮影手段による前記映像に対して前記画像処理を施し、
     前記切替手段は、
     前記第1モードでは、前記第1差分画像に写り込んだ前記被写体の面積を算出する第1面積算出手段と、
     前記第1モードでは、前記第1差分画像上の前記被写体の前記面積に基づいて、前記被写体と前記撮影手段との間の距離を判断し、その距離に応じて、前記第1モードを設定し、前記被写体と前記撮影手段との間の距離が、前記第1モードの設定時より長い場合に、前記第2モードを設定する第1設定手段と、
     前記第2モードでは、前記発光手段の発光時の前記撮影手段による前記映像と前記発光手段の消灯時の前記撮影手段による前記映像との第2差分画像に写り込んだ前記被写体の面積を算出する第2面積算出手段と、
     前記第2モードでは、前記第2差分画像上の前記被写体の前記面積に基づいて、前記被写体と前記撮影手段との間の距離を判断し、その距離に応じて、前記第2モードを設定し、前記被写体と前記撮影手段との間の距離が、前記第2モードの設定時より短い場合に、前記第1モードを設定する第2設定手段と、を含む請求項1記載の画像処理装置。
  13.  前記第2モードで前記第2差分画像を得るための前記撮影手段の撮影周期は、前記第1モードで前記第1差分画像を得るための前記撮影手段の撮影周期より長く設定される、請求項12記載の画像処理装置。
  14.  被写体を撮影する撮影手段が出力した画像を処理する画像処理装置であって、
     前記撮影手段が出力した現在の画像と過去の画像との差分を算出する差分手段と、
     前記差分に基づいて、画素値の変化を検出する検出手段と、
     第1閾値及び前記第1閾値より小さい第2閾値を設定し、前記画素値の変化の頻度が前記第1閾値を超える場合又は前記第2閾値を下回る場合、その変化をノイズと判断し、前記頻度が前記第1閾値と前記第2閾値との間にある場合、その変化を実質的な変化と判断し、前記動体が存在すると判断する判断手段と、を備える画像処理装置。
  15.  被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理装置であって、
     前記撮影手段が出力した画像から前記手の輪郭線を抽出し、その輪郭線の変曲点の画素と前記変曲点の次の変曲点の画素との間の画素に基づいて、指を特定する指特定手段と、
     所定の基準線に対する、前記指特定手段が特定した各指の傾き角を算出する傾角算出手段と、
     前記指特定手段が特定した、隣り合う指と指とがなす角度を、前記各指の前記傾き角に基づき算出する指角算出手段と、
     前記隣り合う指と指とがなす前記角度に基づいて、手の形状を判定する判定手段と、を備える画像処理装置。
  16.  被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理装置であって、
     前記手の輪郭画像の重心から輪郭線上の各画素までの距離を算出する距離算出手段と、
     前記各画素までの前記距離に基づいて、手の形状を判定する判定手段と、を備える画像処理装置。
  17.  被写体を撮影する撮影手段が出力した画像を処理する画像処理装置であって、
     前記被写体の輪郭画像の重心と輪郭線上の画素とを結ぶ線分の長さを算出する長さ算出手段と、
     前記線分が、所定の基準線に対してなす角度を算出する角度算出手段と、
     前記長さを前記角度の関数として表したときの位相差を、前記被写体の回転角度とする回転検出手段と、を備える画像処理装置。
  18.  被写体を撮影する撮影手段が出力した映像を処理する画像処理方法であって、
     コンピュータが、前記撮影手段が出力した映像に対して画像処理を施すステップと、
     前記コンピュータが、前記被写体と前記撮影手段との間の距離に応じて、前記画像処理のモードを切り替えるステップと、を含む画像処理方法。
  19.  被写体を撮影する撮影手段が出力した画像を処理する画像処理方法であって、
     前記撮影手段が出力した現在の画像と過去の画像との差分を算出するステップと、
     前記差分に基づいて、画素値の変化を検出するステップと、
     第1閾値及び前記第1閾値より小さい第2閾値を設定し、前記画素値の変化の頻度が前記第1閾値を超える場合又は前記第2閾値を下回る場合、その変化をノイズと判断し、前記頻度が前記第1閾値と前記第2閾値との間にある場合、その変化を実質的な変化と判断し、前記動体が存在すると判断するステップと、を含む画像処理方法。
  20.  被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理方法であって、
     前記撮影手段が出力した画像から前記手の輪郭線を抽出し、その輪郭線の変曲点の画素と前記変曲点の次の変曲点の画素との間の画素に基づいて、指を特定するステップと、
     所定の基準線に対する、前記指を特定する前記ステップが特定した各指の傾き角を算出するステップと、
     前記指を特定する前記ステップが特定した、隣り合う指と指とがなす角度を、前記各指の前記傾き角に基づき算出するステップと、
     前記隣り合う指と指とがなす前記角度に基づいて、手の形状を判定するステップと、を含む画像処理方法。
  21.  被写体としての手を撮影する撮影手段が出力した画像を処理する画像処理方法であって、
     前記手の輪郭画像の重心から輪郭線上の各画素までの距離を算出するステップと、
     前記各画素までの前記距離に基づいて、手の形状を判定するステップと、を含む画像処理方法。
  22.  被写体を撮影する撮影手段が出力した画像を処理する画像処理方法であって、
     前記被写体の輪郭画像の重心と輪郭線上の画素とを結ぶ線分の長さを算出するステップと、
     前記線分が、所定の基準線に対してなす角度を算出するステップと、
     前記長さを前記角度の関数として表したときの位相差を、前記被写体の回転角度とするステップと、を含む画像処理方法。
  23.  請求項18から22のいずれか一に記載の画像処理方法をコンピュータに実行させるためのコンピュータプログラム。
  24.  請求項23記載のコンピュータプログラムを記録したコンピュータ読み取り可能な記録媒体。
  25.  外部のコンピュータと接続される画像処理モジュールであって、
     MCU(Micro Controller Unit)と、
     前記MCUの内部及び/又は外部に配置され、前記MCUによって実行されるプログラム及びデータが格納されるメモリと、
     被写体を撮影するイメージセンサと、
     赤外光を発光する赤外発光ダイオードを含む発光部と、
     電源端子及び信号端子を含み、かつ、前記外部のコンピュータと接続するためのコネクタと、
     外部から前記電源端子に与えられる電源電圧を、前記MCU、前記メモリ、前記イメージセンサ、及び、前記発光部に供給するための電源線と、
     前記コネクタの前記信号端子と、前記MCUと、を接続する信号線と、
     前記MCUと、前記イメージセンサと、を接続するバスと、を備え、
     前記MCU又は前記イメージセンサは、前記発光部がスイッチングトランジスタを含む場合は、そのスイッチングトランジスタを制御して、前記赤外発光ダイオードを間欠的に駆動し、前記発光部がスイッチングトランジスタを含まない場合は、前記赤外発光ダイオードを直接制御して、前記赤外発光ダイオードを間欠的に駆動し、
     前記イメージセンサは、前記赤外発光ダイオードが赤外光を発光している時、及び、前記赤外発光ダイオードが赤外光を発光していない時、のそれぞれにおいて、撮影処理を実行し、赤外光の発光時の撮影画像と赤外光の非発光時の撮影画像との差分画像を生成して、その差分画像を、前記バスを介して、前記MCUに送信するものであり、あるいは、赤外光の発光時の第1撮影画像と赤外光の非発光時の第2撮影画像とを生成して、それら第1撮影画像及び第2撮影画像を、前記バスを介して、前記MCUに送信するものであり、
     前記イメージセンサが前記差分画像を生成するものである場合において、
     前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記差分画像を生成し、前記MCUに送信し、
     前記差分画像は、複数の画素からなり、前記イメージセンサは、前記差分画像を前記MCUに送信する際に、1画素ずつ、シリアルに送信し、前記MCUは、前記イメージセンサから1画素を受信するたびに、所定の閾値と比較して、2値化を行い、前記メモリに格納し、前記メモリに格納された2値化された差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信するものであり、あるいは、
     前記MCUは、前記イメージセンサから前記差分画像を受け取って、前記メモリに格納し、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信するものであり、
     前記イメージセンサが前記第1撮影画像及び第2撮影画像を生成するものである場合において、
     前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記第1撮影画像及び第2撮影画像を生成し、前記MCUに送信し、
     前記MCUは、前記第1撮影画像と前記第2撮影画像との差分画像を生成し、前記メモリに格納して、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信するものであり、
     前記MCUによる前記解析対象差分画像の解析は、新たに前記解析対象差分画像を前記メモリに格納するたびに実行され、その解析結果が、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信され、
     前記MCUによる前記解析対象差分画像の解析は、前記解析対象差分画像に写り込んだ前記被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、前記解析対象差分画像に写り込んだ前記被写体としての動体の検出、及び、前記被写体の存在の検出のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信され、
     前記MCUは、前記解析対象差分画像の解析結果が所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能であり、
     前記MCU、前記メモリ、前記イメージセンサ、前記発光部、前記コネクタ、前記電源線、前記信号線、及び、前記バスは、所定の基板上にマウントされ、
     前記画像処理モジュールは、
     前記所定の基板上に固定されるレンズユニットをさらに備え、
     前記レンズユニットは、
     レンズと、
     前記レンズを保持するレンズホルダと、を含み、
     前記イメージセンサは、前記所定の基板上において、前記レンズの下部であって、前記レンズの光軸上であり、かつ、前記レンズホルダの内部に配置され、
     前記画像処理モジュールは、
     赤外光のみを透過する赤外光フィルタをさらに備え、
     前記赤外光フィルタは、前記レンズユニットの内部の、前記イメージセンサと前記レンズとの間に配置され、又は、前記レンズユニットの外部において、前記レンズを覆うように配置され、
     前記外部のコンピュータは、エアコンディショナ・テレビジョン・オーディオ機器・フォトフレーム・照明機器等といった家庭電化製品、電子玩具・ビデオゲーム機等といったエンターテインメント機器、セキュリティ機器、カーナビゲーション等の車載電子機器、若しくは、LCD等のディスプレイ装置のコンピュータ、又は、パーソナルコンピュータであることができる、画像処理モジュール。
  26.  外部のコンピュータと接続される画像処理モジュールであって、
     MCU(Micro Controller Unit)と、
     前記MCUの内部及び/又は外部に配置され、前記MCUによって実行されるプログラム及びデータが格納されるメモリと、
     被写体を撮影するイメージセンサと、
     電源端子及び信号端子を含み、かつ、前記外部のコンピュータと接続するためのコネクタと、
     外部から前記電源端子に与えられる電源電圧を、前記MCU、前記メモリ、及び、前記イメージセンサに供給するための電源線と、
     前記コネクタの前記信号端子と、前記MCUと、を接続する信号線と、
     前記MCUと、前記イメージセンサと、を接続するバスと、を備え、
     前記イメージセンサは、一定時間間隔で、撮影処理を実行し、撮影画像を、前記バスを介して、前記MCUに送信し、
     前記MCUは、前記イメージセンサから前記撮影画像を受け取って、前記メモリに格納し、前記メモリに格納された前記撮影画像(以下、「解析対象画像」と呼ぶ。)を解析し、その解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信し、
     前記MCUによる前記解析対象画像の解析は、新たに前記解析対象画像を前記メモリに格納するたびに実行され、その解析結果が、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信され、
     前記MCUによる前記解析対象画像の解析は、前記解析対象画像に写り込んだ前記被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、前記解析対象画像に写り込んだ前記被写体としての動体の検出、前記解析対象画像に写り込んだ撮影空間の輝度の算出、前記解析対象画像に写り込んだ前記被写体の像の輝度の算出、及び、前記被写体の存在の検出のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信され、
     前記MCUは、前記解析対象画像の解析結果が所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能であり、
     前記MCU、前記メモリ、前記イメージセンサ、前記コネクタ、前記電源線、前記信号線、及び、前記バスは、所定の基板上にマウントされ、
     前記画像処理モジュールは、
     前記所定の基板上に固定されるレンズユニットをさらに備え、
     前記レンズユニットは、
     レンズと、
     前記レンズを保持するレンズホルダと、を含み、
     前記イメージセンサは、前記所定の基板上において、前記レンズの下部であって、前記レンズの光軸上であり、かつ、前記レンズホルダの内部に配置され、
     前記外部のコンピュータは、エアコンディショナ・テレビジョン・オーディオ機器・フォトフレーム・照明機器等といった家庭電化製品、電子玩具・ビデオゲーム機等といったエンターテインメント機器、セキュリティ機器、カーナビゲーション等の車載電子機器、若しくは、LCD等のディスプレイ装置のコンピュータ、又は、パーソナルコンピュータであることができる、画像処理モジュール。
  27.  外部のコンピュータと接続される画像処理モジュールであって、
     MCU(Micro Controller Unit)と、
     前記MCUの内部及び/又は外部に配置され、前記MCUによって実行されるプログラム及びデータが格納されるメモリと、
     被写体を撮影するイメージセンサと、
     赤外光を発光する赤外発光ダイオードを含む発光部と、
     電源端子及び信号端子を含み、かつ、前記外部のコンピュータと接続するためのコネクタと、
     外部から前記電源端子に与えられる電源電圧を、前記MCU、前記メモリ、前記イメージセンサ、及び、前記発光部に供給するための電源線と、
     前記コネクタの前記信号端子と、前記MCUと、を接続する信号線と、
     前記MCUと、前記イメージセンサと、を接続するバスと、を備え、
     前記イメージセンサは、第1撮影モード及び第2撮影モードを有し、
     前記第1撮影モードにおいて、前記MCU又は前記イメージセンサは、前記発光部がスイッチングトランジスタを含む場合は、そのスイッチングトランジスタを制御して、前記赤外発光ダイオードを間欠的に駆動し、前記発光部がスイッチングトランジスタを含まない場合は、前記赤外発光ダイオードを直接制御して、前記赤外発光ダイオードを間欠的に駆動し、
     前記第1撮影モードにおいて、前記イメージセンサは、前記赤外発光ダイオードが赤外光を発光している時、及び、前記赤外発光ダイオードが赤外光を発光していない時、のそれぞれにおいて、撮影処理を実行し、赤外光の発光時の撮影画像と赤外光の非発光時の撮影画像との差分画像を生成して、その差分画像を、前記バスを介して、前記MCUに送信するものであり、あるいは、赤外光の発光時の第1撮影画像と赤外光の非発光時の第2撮影画像とを生成して、それら第1撮影画像及び第2撮影画像を、前記バスを介して、前記MCUに送信するものであり、
     前記第1撮影モードにおいて、前記イメージセンサが前記差分画像を生成するものである場合(以下、「第1の場合」と呼ぶ。)において、前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記差分画像を生成し、前記MCUに送信し、
     前記第1の場合において、前記差分画像は、複数の画素からなり、前記イメージセンサは、前記差分画像を前記MCUに送信する際に、1画素ずつ、シリアルに送信し、前記MCUは、前記イメージセンサから1画素を受信するたびに、所定の第1の閾値と比較して、2値化を行い、前記メモリに格納し、前記メモリに格納された2値化された差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析するものであり、あるいは、
     前記第1の場合において、前記MCUは、前記イメージセンサから前記差分画像を受け取って、前記メモリに格納し、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析するものであり、
     前記第1撮影モードにおいて、前記イメージセンサが前記第1撮影画像及び第2撮影画像を生成するものである場合(以下、「第2の場合」と呼ぶ。)において、前記イメージセンサは、前記赤外発光ダイオードの間欠的な駆動に対応した一定周期で、前記第1撮影画像及び第2撮影画像を生成し、前記MCUに送信し、
     前記第2の場合において、前記MCUは、前記第1撮影画像と前記第2撮影画像との差分画像を生成し、前記メモリに格納して、前記メモリに格納された前記差分画像(以下、「解析対象差分画像」と呼ぶ。)を解析するものであり、
     前記第1撮影モードにおいて、前記MCUによる前記解析対象差分画像の解析は、新たに前記解析対象差分画像を前記メモリに格納するたびに実行され、
     前記第2撮影モードにおいて、前記イメージセンサは、一定時間間隔で、撮影処理を実行し、撮影画像を、前記バスを介して、前記MCUに送信し、
     前記第2撮影モードにおいて、前記MCUは、前記イメージセンサから前記撮影画像を受け取って、前記メモリに格納し、前記メモリに格納された前記撮影画像(以下、「解析対象画像」と呼ぶ。)を解析し、
     前記第2撮影モードにおいて、前記MCUによる前記解析対象画像の解析は、新たに前記解析対象画像を前記メモリに格納するたびに実行され、
     前記MCUは、第1画像処理モードと第2画像処理モードとを有し、
     前記第1画像処理モードにおいて、前記MCUによる前記解析対象差分画像の解析は、前記解析対象差分画像に写り込んだ前記被写体の像の形状の認識、その像の色彩の認識、その像の模様の認識、その像の座標の算出、その像の面積の算出、その像の回転量若しくは回転角度の算出、その像の回転方向の算出、その像の速度の算出、その像の加速度の算出、その像の移動軌跡の算出、前記解析対象差分画像に写り込んだ前記被写体としての動体の検出、及び、前記被写体の存在の検出のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信され、
     前記第1画像処理モードにおいて、前記MCUは、前記解析対象差分画像の解析結果が第1の所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能であり、
     前記第2画像処理モードにおいて、前記MCUによる前記解析対象画像の解析は、前記解析対象画像から前記被写体としての動体を検出する処理、前記解析対象画像に写り込んだ撮影空間の輝度を求める処理、前記解析対象画像に写り込んだ被写体の像の輝度を求める処理、及び、前記解析対象画像から前記被写体の存在を検出する処理のうちの全部又は一部を含み、解析結果として、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信され、
     前記第2画像処理モードにおいて、前記MCUは、前記解析対象画像の解析結果が第2の所定の条件を満足した時に、割込信号又はコマンドを、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信する機能を搭載することが可能であり、
     前記第1画像処理モードでは、前記イメージセンサは、前記第1撮影モードで動作し、前記MCUは、前記第1撮影モードで得られた前記解析対象差分画像の解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信し、前記解析対象差分画像に基づいて、前記第1画像処理モードと前記第2画像処理モードとの間の切り替えを行い、
     前記第2画像処理モードでは、前記イメージセンサは、前記第1撮影モード及び前記第2撮影モードで動作し、前記MCUは、前記第2撮影モードで得られた前記解析対象画像の解析結果を、前記信号線及び前記コネクタの前記信号端子を介して、前記外部のコンピュータに送信し、前記第1撮影モードで得られた前記解析対象差分画像に基づいて、前記第1画像処理モードと前記第2画像処理モードとの間の切り替えを行い、
     前記第1画像処理モードにおいて、前記MCUは、前記解析対象差分画像に写り込んだ像の面積を算出して、その面積と所定の第2の閾値を比較し、その面積が前記所定の第2の閾値を超えている場合、前記第1画像処理モードを維持し、その面積が前記所定の第2の閾値以下の場合、前記第1画像処理モードから前記第2画像処理モードへ移行し、
     前記第2画像処理モードにおいて、前記MCUは、前記解析対象差分画像に写り込んだ像の面積を算出して、その面積と前記所定の第2の閾値を比較し、その面積が前記所定の第2の閾値以下の場合、前記第2画像処理モードを維持し、その面積が前記所定の第2の閾値を超えている場合、前記第2画像処理モードから前記第1画像処理モードへ移行し、
     前記第2画像処理モードにおいて、前記第1撮影モードにおける前記赤外発光ダイオードを間欠的に駆動する際の周期は、前記第1画像処理モードでの周期より長い、又は、同じであり、
     前記MCU、前記メモリ、前記イメージセンサ、前記発光部、前記コネクタ、前記電源線、前記信号線、及び、前記バスは、所定の基板上にマウントされ、
     前記画像処理モジュールは、
     前記所定の基板上に固定されるレンズユニットをさらに備え、
     前記レンズユニットは、
     レンズと、
     前記レンズを保持するレンズホルダと、を含み、
     前記イメージセンサは、前記所定の基板上において、前記レンズの下部であって、前記レンズの光軸上であり、かつ、前記レンズホルダの内部に配置され、
     前記画像処理モジュールは、
     赤外光のみを透過する赤外光フィルタをさらに備え、
     前記赤外光フィルタは、前記レンズユニットの内部の、前記イメージセンサと前記レンズとの間に配置され、又は、前記レンズユニットの外部において、前記レンズを覆うように配置され、
     前記外部のコンピュータは、エアコンディショナ・テレビジョン・オーディオ機器・フォトフレーム・照明機器等といった家庭電化製品、電子玩具・ビデオゲーム機等といったエンターテインメント機器、セキュリティ機器、カーナビゲーション等の車載電子機器、若しくは、LCD等のディスプレイ装置のコンピュータ、又は、パーソナルコンピュータであることができる、画像処理モジュール。
  28.  被写体を撮影する撮影手段が出力した画像を処理する画像処理手段と、
     前記画像処理手段の処理結果に基づいて所定の機器を制御する制御手段と、を備え、
     前記画像処理手段は、前記画像を複数のブロックに分割し、前記ブロックごとに、画素の変化を検出し、
     前記制御手段は、前記ブロックごとの画素の変化に応じて、前記所定の機器を制御する、電子機器。
  29.  前記制御手段は、前記ブロックごとの画素の変化に応じて、前記所定の機器の出力、前記所定の機器の向き、又は、前記所定の機器の一部の向きを制御する、請求項28記載の電子機器。
  30.  前記撮影手段は、前記被写体を俯瞰撮影できる位置に設置され、
     前記所定の機器は、天井に設置される、請求項28又は29記載の電子機器。
  31.  前記所定の機器は、天井に設置される空気調和装置であり、この空気調和装置は、風向きを調整するための風向調整機構を有し、
     前記制御手段は、前記ブロックごとの画素の変化に応じて、前記風向調整機構を制御する、請求項30記載の電子機器。
PCT/JP2011/051455 2010-01-29 2011-01-26 画像処理装置、画像処理方法、コンピュータプログラム、記録媒体、画像処理モジュール、及び、電子機器 WO2011093317A1 (ja)

Applications Claiming Priority (6)

Application Number Priority Date Filing Date Title
JP2010-019794 2010-01-29
JP2010019794 2010-01-29
JP2010-044695 2010-03-01
JP2010044695 2010-03-01
JP2010001921U JP3159906U (ja) 2010-03-24 2010-03-24 画像処理モジュール
JP2010-001921U 2010-03-24

Publications (1)

Publication Number Publication Date
WO2011093317A1 true WO2011093317A1 (ja) 2011-08-04

Family

ID=44319303

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2011/051455 WO2011093317A1 (ja) 2010-01-29 2011-01-26 画像処理装置、画像処理方法、コンピュータプログラム、記録媒体、画像処理モジュール、及び、電子機器

Country Status (1)

Country Link
WO (1) WO2011093317A1 (ja)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2014137616A (ja) * 2013-01-15 2014-07-28 Fujitsu Ltd 表示制御装置、表示制御システム及び表示制御方法
JP2015056674A (ja) * 2013-09-10 2015-03-23 和浩 山本 カメラ
JP2018085734A (ja) * 2017-12-11 2018-05-31 和浩 山本 カメラ
CN117146729A (zh) * 2023-10-31 2023-12-01 能科科技股份有限公司 一种伺服压机控制***

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH09185456A (ja) * 1995-04-28 1997-07-15 Matsushita Electric Ind Co Ltd インターフェイス装置
JPH09231357A (ja) * 1996-02-22 1997-09-05 Sumitomo Metal Ind Ltd 画像処理装置
JPH1063318A (ja) * 1996-08-22 1998-03-06 Toyoda Mach Works Ltd 物体認識方法及びその装置
JP2000222583A (ja) * 1999-01-29 2000-08-11 Victor Co Of Japan Ltd 画像処理装置
JP2001246161A (ja) * 1999-12-31 2001-09-11 Square Co Ltd ジェスチャー認識技術を用いたゲーム装置およびその方法ならびにその方法を実現するプログラムを記憶した記録媒体
JP2005128815A (ja) * 2003-10-24 2005-05-19 Matsushita Electric Ind Co Ltd 人物検出装置及び人物検出方法
JP2007052609A (ja) * 2005-08-17 2007-03-01 Sony Corp 手領域検出装置及び手領域検出方法、並びにプログラム
JP2008236642A (ja) * 2007-03-23 2008-10-02 Hitachi Ltd 物体追跡装置
WO2008120321A1 (ja) * 2007-03-28 2008-10-09 Fujitsu Limited 画像処理装置、画像処理方法、画像処理プログラム
JP2009042796A (ja) * 2005-11-25 2009-02-26 Panasonic Corp ジェスチャー入力装置および方法

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH09185456A (ja) * 1995-04-28 1997-07-15 Matsushita Electric Ind Co Ltd インターフェイス装置
JPH09231357A (ja) * 1996-02-22 1997-09-05 Sumitomo Metal Ind Ltd 画像処理装置
JPH1063318A (ja) * 1996-08-22 1998-03-06 Toyoda Mach Works Ltd 物体認識方法及びその装置
JP2000222583A (ja) * 1999-01-29 2000-08-11 Victor Co Of Japan Ltd 画像処理装置
JP2001246161A (ja) * 1999-12-31 2001-09-11 Square Co Ltd ジェスチャー認識技術を用いたゲーム装置およびその方法ならびにその方法を実現するプログラムを記憶した記録媒体
JP2005128815A (ja) * 2003-10-24 2005-05-19 Matsushita Electric Ind Co Ltd 人物検出装置及び人物検出方法
JP2007052609A (ja) * 2005-08-17 2007-03-01 Sony Corp 手領域検出装置及び手領域検出方法、並びにプログラム
JP2009042796A (ja) * 2005-11-25 2009-02-26 Panasonic Corp ジェスチャー入力装置および方法
JP2008236642A (ja) * 2007-03-23 2008-10-02 Hitachi Ltd 物体追跡装置
WO2008120321A1 (ja) * 2007-03-28 2008-10-09 Fujitsu Limited 画像処理装置、画像処理方法、画像処理プログラム

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2014137616A (ja) * 2013-01-15 2014-07-28 Fujitsu Ltd 表示制御装置、表示制御システム及び表示制御方法
JP2015056674A (ja) * 2013-09-10 2015-03-23 和浩 山本 カメラ
JP2018085734A (ja) * 2017-12-11 2018-05-31 和浩 山本 カメラ
CN117146729A (zh) * 2023-10-31 2023-12-01 能科科技股份有限公司 一种伺服压机控制***
CN117146729B (zh) * 2023-10-31 2024-02-20 能科科技股份有限公司 一种伺服压机控制***

Similar Documents

Publication Publication Date Title
US9498716B2 (en) Video game device and storage medium storing video game program
US5704836A (en) Motion-based command generation technology
US8537231B2 (en) User interface system based on pointing device
US9317134B2 (en) Proximity object tracker
JP5049228B2 (ja) 対話画像システム、対話装置及びその運転制御方法
US20160162039A1 (en) Method and system for touchless activation of a device
TWI701606B (zh) 亮屏方法、移動終端及儲存媒體
JP6252409B2 (ja) 情報処理装置、情報処理方法およびプログラム
KR101331952B1 (ko) 로봇 청소기 및 이의 제어 방법
WO2011093317A1 (ja) 画像処理装置、画像処理方法、コンピュータプログラム、記録媒体、画像処理モジュール、及び、電子機器
CN105824411A (zh) 基于虚拟现实的交互控制方法及装置
US10739823B2 (en) Motion control assembly with battery pack
US8836483B2 (en) Optical remote control system and light source control method therefor
JP3159906U (ja) 画像処理モジュール
JP2010142404A (ja) ゲームプログラムおよびゲーム装置
JP2011205619A (ja) 画像処理装置、画像処理方法、コンピュータプログラム、及び、電子機器
JP2008307409A (ja) 情報処理装置および情報処理プログラム
KR20140031105A (ko) 인식 대상으로부터 3차원 거리 정보 추출하는 방법 및 이를 위한 장치
CN111745644B (zh) 基于手势的遥控小车控制方法、***和存储介质
JP2018055708A (ja) 情報処理装置、情報処理方法およびプログラム
KR20140046619A (ko) 거울 반사 효과를 이용한 공간 베젤 인터페이스 방법 및 그 장치
TWM478193U (zh) 外接式體感控制微型裝置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11737030

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11737030

Country of ref document: EP

Kind code of ref document: A1