## 2 Video Camera Imaging Based Method
### Motion Based Methods
The second technique was to measure respiratory rates by using motion detection exploiting frame subtraction, local contrast enhancement, binarization, morphological and masked filtering, white area detection and logical matrix calculation where the mean distance between ones in the logical matrix was used to calculate RR. Although the system was an effective solution for the unclear ROI problem, it still has some limitations. They have only considered a single vital sign, i.e., RR and a single infant, which limits the real applicability of the system. In [63], a contactless real time monitoring system was introduced for measuring respiratory rates and detecting apnoea by exploiting a Microsoft Kinect v2 sensor, as presented in Figure 3c, from the movement of thorax and abdomen in different sleeping positions and various conditions of light including dark environments. They used an improved motion magnification scheme based on the Lanczos resampling method, wavelet pyramid decomposition, temporal band pass filtering and image denoising to magnify the input signal. Frame subtraction was used to calculate respiratory rate. Nevertheless, the system suffered from motion artefacts, short range, and a limited number of viable ROI. Furthermore, they only considered respiratory activity and apnoea, and did not consider other vital signs. To mitigate this limitation, an improved contactless system was presented to measure the HR and RR and to sense irregular cardiopulmonary functions such as bradycardia, tachycardia, bradypnea, tachyonnoea, and central apnoea by using the signal from the thoracic-abdominal region based on image sequences taken by the Microsoft Kinect v2 sensor with processing that considered unclear ROI, various illumination conditions and different sleeping postures [64]. The basic block diagram of the proposed system is presented in Figure 5. An efficient motion magnification technique (EMMS) [65] was used to magnify the input data to make the movement apparent. Then, to calculate HR, an intensity-based technique was used, including signal decomposition, blind source separation, spectral analysis, filtering and peak detection. To calculate RR, they used a frame subtraction technique, binarisation, filtering, white area detection and binary matrix calculation. If any irregularity was detected, an alarm would be sent to a carer to notify them of the irregularity. However, the detection range was limited to 4.5 m and the number of ROI was also limited. Furthermore, system failure may occur in the case of a fully covered subject or if the subject should lie on their stomach. Figure 4: System diagram of the remote respiratory monitoring system [62]. The motion-based method was beneficial in this case, since the method is robust to illumination variance, skin tone and unclear ROI. However, the main limitation of this method is the dependency on motion features to extract the physiological signals. As a result, the technique may be highly vulnerable to voluntary motion variations such as different facial expressions, walking and talking by the subject. Consequently, determining vital signs during voluntary motion may reduce the consistency and reliability of the method, and remains a research problem to be overcome.