A hit-or-miss transform architecture and a canonical Boolean logic format and threshold decomposition algorithm are proposed to process binary and gray-tone images with morphological combined operations. The transformation of morphological combined image processing functions to hit-or-miss transforms is explicit: Binary functions are formulated by a summation of hit-or-miss transforms and gray-tone functions formulated by a double summation. A simple optical hit-or-miss transform processor is suggested on the basis of incoherent two-channel correlation with dual-rail spatial coding. The hit-or-miss transforms can be realized optically in one parallel processing step. Thus, binary and gray-tone image processing functions can be implemented by the repeated use of the optical processor with different structuring elements.