This thesis is primarily concerned with the introduction of a new approach to the general problem of automatic image orientation detection. Inspired by the local binary pattern (LBP), a luminance, rotation and scale invariant and content-independent algorithm is proposed, namely: Histogram of Optimized Local Binary Pattern (HOOPLBP).Whilst the proposed approach is essentially generic, the core application considered in this study is human face orientation detection. To detect the face orientation, a general face model is trained using the HOOPLBP feature. The experiment show a very impressive result. Integrating this result with other face related techniques will facilitate some applications. To this end, this thesis propose a hybrid face detection system. Specifically, the new system aims to detect both upright and tilted human face in digital images. In the scheme, several face related algorithms are integrated to achieve difference tasks in different stages. In addition, two modified systems are used in this thesis to detect faces in both grayscale images and color images. The HOOPLBP is a new and robust method in automatic image orientation detection. It can be improved by other techniques and also can be used in many other fields. The future work is also included in the thesis.