1. A method for optical character recognition (OCR) detection of documents in a self-service machine comprising the steps of: A) acquiring an image of a document by means of a digital video or matrix camera; B) performing fine rotation on the acquired image by: a) reducing the acquired image; b) applying a median filter to remove details of the acquired image the details including at least one of alphanumeric characters and graphic information; c) determining a position of a document region corresponding to the document; d) using an edge filter to determine edge pixels in the acquired image and outputting a binary edge image of the determined edge pixels; e) detecting straight edge lines of the document region with the aid of the binary edge image of the determined edge pixels by using a Hough transformation; f) determining a rotation angle by which the document region in the image must be rotated for parallel alignment with edges of a field of view of the digital video or matrix camera; and g) rotating the document region by the determined rotation angle and cutting off areas outside the detected straight edge lines to establish an intermediate document image; and C) forming a homogenized background image by: h) establishing a background image by applying the median filter to each pixel in the intermediate document image, wherein applying the median filter includes replacing a pixel value of each pixel with a median pixel value from a number of pixels neighboring the respective pixel, thereby removing smaller details in the intermediate document image to establish the background image; i) creating a brightness map from the established background image; j) subtracting the brightness map from the intermediate document image to form a negative image; and k) inverting the negative image to form a final document image; D) binarizing the final document image to segment alphanumeric character information; and E) OCR detecting the alphanumeric character information; wherein the steps of forming a homogenized background image include further reducing the intermediate document image before applying the median filter to remove the smaller details and thereby obtaining the brightness map with a coarser resolution.