1 Introduction
In recent years, data hiding has been widely used in different fields. According to the different application of data hiding in today’s life, this science has been divided into different subcategories based on its application. Two main subcategories of data hiding include steganography and watermarking ref001 . The important similarity among these subcategories is hidden messages, watermarks, or information. This similarity results in same sense in various application of both subcategories.
In watermarking, some bite in robust, fragile, or semifragile form, is embedded as a watermark in an image to protect the image against claiming intellectual property, forging, tampering, etc. ref002 ; ref003 ; ref004 ; ref005 . Robust watermarking is the ability to retrieve the watermark after intentional attacks, such as image editing and manipulation, and unintentional attacks, such as compression and image quality enhancement processes. Besides, fragile and semifragile watermarking is used to determine the manipulation of the image and retrieve manipulation parts. However, the main aim of steganography is to hide information in a form of a message in an image, but the message and its secure and imperceptible transmission are of central importance. In fact, in steganography, in the most cases the image itself does not matter, transferring a larger and more imperceptible volume of the message is important. There is a challenge among the criteria of robustness, capacity, and invisibility. Accordingly, increasing each one can reduce the number of other criteria ref004 . Therefore, one of the key points in data hiding is to design an approach by considering the main goal and preserve the other goals.
In steganography methods, embedding the message information in an image is carried out in spatial and frequency domains. Generally, embedding in spatial domain is performed in less important bits of the image without considering special conditions, which it is possible to guess whether it is covered or not by evaluating the image histogram. In order to increase the power of LSBbased methods, LSB++ method is proposed, which aims to avoid embedding in certain pixels of the image in order to maintain the image histogram ref006 . Some steganography methods, which are known as reversible methods, try to achieve relatively complete retrieval of host image in the receiver after message extraction ref007 ; ref008 ; ref009 ; ref010 . In terms of classification, the methods with higher capacity of steganography including histogram transmissionbased methods ref011 ; ref012 , Quantizationbased methods ref013
, interpolationbased methods, Pixel Value Difference (PVD) based method
ref5 and other methods ref3 . All available steganography methods assume that the message has a random form, which reduces the embedding capacity of the proposed algorithm.According to the digitalization of academic and official documents and letters, the secure and imperceptible document image transferring and storing as a message is needed. Although in steganography methods, several attempts have been made to send any message as a random bit, there has not been many efforts to embed and send scanned documents and administrative letters as a message in a safer way ref8 . In the present studies, a highcapacity steganography for scanned documents as a message in an image was proposed to embed a significant amount of information in a host image. The paper proceeds as follows. In section 2, the related methods are introduced. In section 3, the proposed method and its substeps are discussed. Finally, the results and conclusion are presented in section 4 and 5, respectively.
2 Related Works
In this section, the strongest methods and most related methods were respectively evaluated on the embedding capacity of the random message and nonrandom message. Besides, the main ideas along with embedding capacity were briefly discussed.
In ref1 , AMBTC compressionbased steganography in an image was presented, in which the input image was converted to of its original size, and then the compressed pixels were dispersed in a particular way in an image, which was the same size as the original image. The empty pixels were calculated through the proposed interpolation ASAI method. An AMBTC compression resulted in a reduction in quality of the embedded image. In this method, amount of PSNR and embedding capacity was 33.39 dB and 1.2 bpp that both criteria had low values.
In ref2 , the main image was converted to a larger image using interpolation, which is called cover image. The difference between the interpolated pixels and the maximum pixels of a neighbor in blocks was used to determine the amount of bit that could be embedded in an interpolated pixel. Therefore, the visual quality of the image was further preserved. The quality of the embedded image was 33.85 dB in terms of PSNR and its embedding capacity was 1.79 bpp.
In ref3 , a method was proposed to have fewer changes in the image and used the index function to calculate the basic pixels. The pixels of each block were being displaced based on the calculated amount for basic pixels. Amount of embedded bit for each pixel was calculated by the difference between each pixel in a block with a base zero number pixel. In this method, in order to maintain the image quality in embedding phase, the ranges table was used and the graylevel of pixels was divided into groups. The embedded image quality was 28.45 dB and its embedding capacity was 2.45 bpp. Although the value of embedding capacity was relatively enough, the embedded image quality was fewer than the embedded image with over 35 dB.
In ref4 , weighted matrix and modular sum resulting from the multiplication of a weighted matrix and image pixels was used to calculate the location of the embedded image and the message information was embedded in three less important bits of the image. In this method, a different weighted matrix was used for different blocks, which resulted in an increase in security of steganography. In terms of PSNR, the quality of the embedded image was 37.97 dB and storage capacity was 2.97 bpp.
In ref5 , an Octanary PVDbased highcapacity steganography method was proposed. It means in each 33 block, all neighbor pixels of central pixel were paired with central pixels and then the amount of embedded bit in that pair, as well as whether the pixels were an edge or not, was decided. In this method, as in many similar methods, a ranges table was used to determine the interval of each pixel placement. After embedding, a phase, under the name of the readjustment, was used on embedded pixels to align on gray level correctly and not go beyond the permissible range. In terms of PSNR metric, the quality of the embedded image was 38.98 dB and storage capacity was about 3.72 bpp, which both criteria had high value.
In ref6
, a high capacity steganography was proposed that used a genetic algorithm to choose the suitable embedding order in a 4
4 block. In fact, this paper indicated that conventional embedding order did not have the best image quality and embedding capacity. This method aimed to convert the best embedding order to an optimization problem and solve it using a genetic algorithm. Besides, this method determined the best LSB bits to have higher capacity. The embedding capacity was 3.95 bpp and the quality of embedded image was about 35 dB.In ref7 , a high capacity steganography method based on determining the image edges was proposed. In this paper, in order to determine the edge, three important bits of each pixel were used in different conventional edge detection methods including Sobel, Canny and fuzzy based methods. Then image pixels were divided into the edge and nonedge pixels. In each edge pixel and nonedge pixel, 4 and 2 bits of the message were respectively embedded. The embedding capacity and quality was 4.7 bpp and 26 dB, respectively. As seen, this method has high embedding capacity but its image quality is fewer than similar method.
In ref8 , a steganography method was proposed, which used the scanned document as a message. This method aimed to perform an algorithm to compress the message by considering the sparse property of the message. Two important achievements of this method were to convert graylevel image to binary image using halftone method and convert the binary string to their equivalent decimal value. One of the main disadvantages of this method was to code the background area in addition to areas containing content. Embedding capacity and quality of embedded image were 5.25 bpp and 36 dB, respectively.
By evaluating the recent high capacity steganography methods it can be found that the most of these methods did not consider the type of input message, i.e., the message was considered as random. In scanned text documents and letters, the background is white and the content part is black, therefore, if input message is produced by scanned text documents, official letters, and etc. the scanned document could be converted to a sparse message through a special method. By considering the message as a sparse form, the high capacity steganography could be presented to hide the message with large size.
3 Proposed Method
In Fig. 1 the proposed algorithm is presented. As seen in Fig. 1, the main operations are shown with 5 numbers. In the first step, which is called preprocessing stage, the halftone image is calculated by scanned document and the sparse message is obtained. In the second step, the operation of content separation from the background is performed using the improved quadtree method. Then in the third step, in order to reduce the number of blocks, the blocks are combined in two vertical and horizontal directions, which results in a reduction in the need of maintaining coordinates for blocks. In next step, in order to achieve more compression, the decimal coding is conducted on content. Finally, in the fifth step, the embedding of compressed message has been shown in three low importance pixels of host image. In extraction phase, information is extracted from LSB pixels and by considering the coordinates of each block, its content is placed in that block. The details are given as follows.
3.1 Preprocessing step
In this stage, the graylevel scanned document by halftone method is converted to embeddable bits. In fact, halftone method creates a binary image from the graylevel of the scanned text image and reduces its size 8 times. It means each 8bit pixel is shown by only one bit. Therefore, it is possible to embed the scanned document in host image, but the number of bits in scanned documents is very high that make it impossible by conventional steganography. There are various methods to calculate the halftone image from the document image, which are divided into two group including the errordiffusion based ref10 ; ref11 ; ref12 and dither based methods ref13 ; ref14 . Both halftone methods, by considering the correlation between proximate pixels, decide to convert each pixel (ranged from 0 to 255) to 0 or 1. In the present study, the proposed method of ref10 was used to calculate the halftone image. In order to convert the halftone image to approximate image of the original graylevel image, there are different inverse halftone calculation methods, which aim to retrieve the original image more realistic ref15 ; ref16
. The reverse halftone image calculation is converted each 0 and 1 bit to an integer value between 0 and 255. The simplest method to calculate the inverse halftone image is to apply a Gaussiansoftening filter on halftone image. Therefore, the relatively good graylevel image is obtained. In the present study, the mentioned method was employed to calculate the reverse halftone image. The advantage of halftone method to simple thresholding on text document is to act smartly when the image document containing a contentious spectrum of pixels such as a personal image. In this case, the simple thresholding is not able to estimate the pixels values from zero or one bits.
3.2 Embedding step
The embedding algorithm contains four substeps. In the first substep, an algorithm was proposed to separate the parts containing text, image, signature, or any signs in the document using improved quadtree method. In the second substep, in order to reduce the number of rectangles, their merge was proposed. In this step, more compression in the message was achieved, while there was more ability for compressing. Therefore, in third substeps, an idea was used to convert the binary message to decimal ones and ignore the zero bits behind the binary bits string. Finally, in the fourth step, the compressed bit strings were embedded in three low importance bits of the pixel with a certain structure.
3.2.1 Improved quadtree
The halftone image of a scanned document with the binary display can include text, image, table, and any other signs, which are shown with zero bits and placed on a surface of a white background with one bits. Definitely, the coding and maintenance of bits of a background are not worth and it is best to separate the document content from the background and only the document content is embedded in the host image. Accordingly, an improved quadtree method is proposed. The main method of quadtree ref17 is performed on the graylevel of the image with square dimensions and power of 2. In the present study, enhanced quadtree idea was proposed, which had the ability to be applied to any image dimensions. The pseudo code of this method was shown in Alg. 1. As seen, the input of this algorithm is a graylevel image of the scanned document, which can be rectangular. Besides, it has two thresholds of and and its outputs are set to , , , and values related to rectangles without the ability to divide into more subrectangles. In this set, and are left and upper side coordinates and and are width and height of the rectangle.
In fact, first, the algorithm considers the input image as a rectangle and if the difference between its largest and smallest pixel is more equal than the threshold and also the minimum width and height of the rectangle is 2 times larger than the threshold , it means that the rectangle should be divided into subrectangles. Therefore, the algorithm has divided the rectangle into four subrectangles, which it is possible to be in a different size (different in one row and column). This process is performed repeatedly on all subrectangles and it would stop when there is no other subrectangle with division conditions. The threshold for the halftone image is one because of its binary property. Fig. 2a and 2b show the square parts of halftone image and RQuadtree algorithm output, respectively. Most of these rectangles contain no special information or text, therefore it is not necessary to keep their content and coordinates.
3.2.2 Proximate Rectangles Integration
As seen in Fig. 1step(2), not all rectangles contain information; therefore, it is only needed to keep the content and coordinates of rectangles that contains information. On the other side, the number of these rectangles can be high and maintain 4 numbers as coordinates for each rectangle increase in the size of the final message and reduce the advantage of its compression. Therefore, the integration of proximate rectangles is proposed. The integration algorithm is shown in Alg.2. Input of algorithm is , all rectangles that contain information, and its output is integrated rectangles in both vertical and horizontal directions. This algorithm attempts to merge rectangles by scanning neighbor rectangles horizontally and then vertically. The output of proximate rectangles integration is shown in Fig. 3. Fig. 3b shows all rectangles that contain important information. As shown in Fig. 3c and Fig. 3d, in the first scan, all rectangles that are neighbors horizontally and have horizontal integration condition are integrated and in the second scan, all output rectangles of the first scan, which have vertical integration condition, are integrated.
3.2.3 Decimal Coding
By ignoring the zeros in the left side of a binary bit string, decimal coding algorithm aims to read longer binary bit strings and convert them to their equivalent decimal value. In the first step, in order to increase the number of zeros in the message, the bits of the original halftone image is complemented (This work is done in step 1 of Fig. 1
). Then, the information of document dimension (two 20bits number), coordinates of all blocks (four 12bits number for coordinates of each block, width and length), and its contents are attached in form of a vector and the decimal coding algorithm is employed to read the binary bit string and convert them to decimal values. In decimal coding algorithm (Alg.
3), first, a string with a maximum length of 63 bits is read such that its decimal value be less or equal to 63. The numerical value of string length and its decimal value are respectively named and . Then, each one of the (an integer value in range 0 to 63) and (an integer value in range 0 to 63) are converted to 6bit binary number and it is used in final embedment substep.3.2.4 Final Embedding
At this point, the information bit strings are compressed using halftone, RQuadtree, and decimal coding ideas. In order to embed the image and increase the invisibility property, the pixels in the more complex texture of image are considered as embeddable and pixels in smooth texture of image are considered nonembeddable. For calculating the embeddable and nonembeddable pixels, first, three fewer important bits of all pixels became zero and then in 3
3 proximity, standard deviation (SD) is calculated. If the SD is more than threshold
the central pixel is embeddable otherwise, it is nonembeddable. The advantage of zeroing the three less important bits of all pixels in host image before calculating SD is to obtain same inputs for calculating embeddable and nonembeddable pixels in both embedding and extraction phases and it is possible to use the three fewer important bits of the embeddable pixel to hide the message. The calculation of SD in 33 proximity is shown in Eq. 1.(1) 
(2) 
(3) 
In Eq. 3, shows the amount of graylevel of pixels in the 33 kernel and in Eq. 2, shows the average of them. In order to deal with any possible problem in extraction phase, only 5 MSBbits per pixel is used to calculate SD. Accordingly, in order to delete the three less importance bits of each pixel of kernel, the floor operator is used. As mentioned in substep of decimal coding, for each 63bits string an integer decimal number for the length of string and an integer decimal number for the decimal representation of string are calculated, which both of the mentioned numbers are placed in a range of 063 (6 bit for each integer decimal number). Therefore, 12 bits are needed to code a string with a length of 63bit. The embedding algorithm places the related 12bit in three LSB bits of four embeddable pixels. In order to increase the security, each produced 12bit string were exclusiveORed with a randomly produced 12bit string by a common key between sender and receiver.
3.3 Extraction Step
In this step, first, the messagecontained embeddable pixels should be found using Eq. 13. Every 4 embeddable pixels contain 12bit information related to a 63bit length string. By extracting and concatenating all of them, a bit vector including information of document dimension (two 20bit number), coordinates of rectangles (four 12bit value for each block), and blocks content are obtained. With the location coordinates of each rectangular block, the information content of each block is easily placed in its place and the image of the complemented document is obtained. Then, in order to achieve a halftone image, it should be performed a complement operation. The different methods have been proposed to calculate the inverse halftone image of the graylevel image up to now. In the present research, the halftone image is convolved by a 33 Gaussian kernel with a standard deviation of 0.5.
4 Experimental Results
In the present study, 20 standard graylevel image of USCSIPI image database was used to evaluate the proposed method. Besides, the scanned document of an article ref18 was used as a message (each page was scanned in the scale of 17741288).
The image quality criterion, which has been mentioned in many articles, is maximum signal to noise ratio or PSNR. The criterion shows amount the added noise to the image by embedding any watermark to it. Although this parameter is not exactly in accordance with the visual invisibility property of the watermark in the image, it provides a proper algebraic relationship for the optimal hiding of information in the image. The evaluation criterion is defined as Eq. 4:
(4) 
The Eq. 4 presents the maximum signal to noise ratio in terms of a decibel or dB. Where f is original image signal, is embedded a watermark, is watermarked image signal, (,) are indexes of the images, and is the number of pixels in images of and . The more the criterion, the more ability of imperceptibility is. Often values of about 35 decibels are considered as acceptable values for this criterion. SSIM is another image quality criterion, which considers the structural property of the image. SSIM can be calculated by Eq. 5.
(5) 
The first term presents the correlation coefficient between two and images and shows the degree of linear dependency between the two images, which is in range of . The second term of Eq. 5 that is in range of shows the average brightness of two images and when this term will be 1. The third term, which is in a range of , is an estimation for color differentiation in x and y and the maximum value occurs when . The SSIM and its updated versions is one of the important methods to determine the similarity of two images. In the present study, both mentioned criteria were used to evaluate the quality of embedded image and extracted document image.
In Table 1, the results of applying the proposed method to the 20 selected standard image are shown. In this test, the minimum size of rectangles was 44 and three different experimental thresholds such as 0, 2.5, and 5 were chosen for standard deviation to select the embeddable pixels. As shown in Table 1, for standard deviation 2.5, the embedding rate, PSNR, and SSIM criteria were 7.98 bpp, 37.83 dB and 0.93 in average state, respectively, which the value of embedding rate was significant and value of PSNR and SSIM were acceptable.
In Tables 25, the comparison of the proposed method with similar works are presented. In this comparisons the same host images are used. Table 6 shows the summary of the average quality and the embedding rate of the proposed method in comparison with the related works. As seen, the proposed method has acceptable image quality and higher embedding rate. In Fig. 4, the proposed method is applied to eight different pages of an article ref18 , as a message, and the Lena image is used as the host image. The mean embedding capacity of the proposed method for four different thresholds with the rectangular size of 44, 88, 1616, and 3232 were 7.51, 8.34, 8.77, and 7.27, respectively. The embedding capacity for the size of 1616 was more than three other forms. Fig. 5 shows the quality of extracted document in terms of PSNR and SSIM for 8 different pages of an article. The mean of these values was 24.77 dB and 0.96 for all pages.
5 Conclisions
In the present research, a high capacity steganography method was introduced to embed the scanned documents as a message. The main ideas of the proposed method includes a) converting scanned document with graylevel to binary halftone image; b) proposing an algorithm to separate the content of the document from its background; c) compressing the message by ignoring the 0bit stings behind the 1bit value in process of converting binary bit string to its equivalent decimal value. The outputs resulting from conducting the proposed method, report the embedding capacity of 7.89 bpp and embedded image quality of 37.83 dB, which is higher and more effective than other methods with a random message. Therefore, the proposed method can be used for imperceptible transmission of text documents in the graylevel images.
One disadvantage of the proposed method is the ineffectiveness of calculating the halftone image and inverse of the halftone image. Design of a method to calculate the halftone and inverse halftone image, which is special for a text document, can improve the quality of the extracted document. Therefore, as a future work, it is suggested to design a method to calculate the halftone and inverse halftone image for the text documents.
As an another future work, it is suggested to use sparse representation and dictionary learning methods in order to more compress the text document images.
References
References

(1)
Cox I, Miller M, Bloom J, Fridrich J, Kalker T. Digital watermarking and steganography. Morgan Kaufmann; 2007 Nov 23.

(2)
Soleymani SH, Taherinia AH. Double expanding robust image watermarking based on Spread Spectrum technique and BCH coding. Multimedia Tools and Applications. 2017 Feb 1;76(3):3485503.

(3)
Soleymani SH, Taherinia AH. Robust image watermarking based on ICADCT and noise augmentation technique. InComputer and Knowledge Engineering (ICCKE), 2015 5th International Conference on 2015 Oct 29 (pp. 1823). IEEE.

(4)
Haghighi BB, Taherinia AH, Harati A. TRLH: Fragile and blind dual watermarking for image tamper detection and selfrecovery based on lifting wavelet transform and halftoning technique. Journal of Visual Communication and Image Representation. 2017 Oct 14.

(5)
Shi H, Li MC, Guo C, Tan R. A regionadaptive semifragile dual watermarking scheme. Multimedia Tools and Applications. 2016 Jan 1;75(1):46595.

(6)
Qazanfari K, Safabakhsh R. A new steganography method which preserves histogram: Generalization of LSB++. Information Sciences. 2014 Sep 1;277:90101.

(7)
Jung KH. A highcapacity reversible data hiding scheme based on sorting and prediction in digital images. Multimedia Tools and Applications. 2017 Jun 1;76(11):1312737.

(8)
Qian Z, Zhang X. Reversible data hiding in encrypted images with distributed source encoding. IEEE Transactions on Circuits and Systems for Video Technology. 2016 Apr;26(4):63646.

(9)
Liao X, Shu C. Reversible data hiding in encrypted images based on absolute mean difference of multiple neighboring pixels. Journal of Visual Communication and Image Representation. 2015 Apr 1;28:217.

(10)
Zhang X, Long J, Wang Z, Cheng H. Lossless and reversible data hiding in encrypted images with publickey cryptography. IEEE transactions on circuits and systems for video technology. 2016 Sep;26(9):162231.

(11)
Li X, Li B, Yang B, Zeng T. General framework to histogramshiftingbased reversible data hiding. IEEE Transactions on Image Processing. 2013 Jun;22(6):218191.

(12)
Wang ZH, Lee CF, Chang CY. Histogramshiftingimitated reversible data hiding. Journal of systems and software. 2013 Feb 1;86(2):31523.

(13)
Chen B, Wornell GW. Quantization index modulation methods for digital watermarking and information embedding of multimedia. Journal of VLSI signal processing systems for signal, image and video technology. 2001 Feb 1;27(12):733.

(14)
Tang M, Zeng S, Chen X, Hu J, Du Y. An adaptive image steganography using AMBTC compression and interpolation technique. OptikInternational Journal for Light and Electron Optics. 2016 Jan 1;127(1):4717.

(15)
Tang M, Hu J, Song W. A high capacity image steganography using multilayer embedding. OptikInternational Journal for Light and Electron Optics. 2014 Aug 1;125(15):39726.

(16)
Jung KH, Yoo KY. Highcapacity index based data hiding method. Multimedia Tools and Applications. 2015 Mar 1;74(6):217993.

(17)
Jana B. High payload reversible data hiding scheme using weighted matrix. OptikInternational Journal for Light and Electron Optics. 2016 Mar 1;127(6):334758.

(18)
Balasubramanian C, Selvakumar S, Geetha S. High payload image steganography with reduced distortion using octonary pixel pairing scheme. Multimedia tools and applications. 2014 Dec 1;73(3):222345.

(19)
Kanan HR, Nazeri B. A novel image steganography scheme with high embedding capacity and tunable visual image quality based on a genetic algorithm. Expert Systems with Applications. 2014 Oct 15;41(14):612330.

(20)
Bai J, Chang CC, Nguyen TS, Zhu C, Liu Y. A high payload steganographic algorithm based on edge detection. Displays. 2017 Jan 1;46:4251.

(21)
Soleymani SH, Taherinia AH. High capacity image steganography on sparse message of scanned document image (SMSDI). Multimedia Tools and Applications. 2017 Oct 1;76(20):2084767.

(22)
Liu L, Chen W, Zheng W, Geng W. Structureaware errordiffusion approach using entropyconstrained threshold modulation. The Visual Computer. 2014 Oct 1;30(10):114556.

(23)
Li X. Edgedirected error diffusion halftoning. IEEE Signal Processing Letters. 2006 Nov;13(11):68890.

(24)
Singh YK. Generalized error diffusion method for halftoning. InElectrical, Computer and Communication Technologies (ICECCT), 2015 IEEE International Conference on 2015 Mar 5 (pp. 16). IEEE.

(25)
Zhou Z, Arce GR, Di Crescenzo G. Halftone visual cryptography. IEEE transactions on image processing. 2006 Aug;15(8):244153.

(26)
Alasseur C, Constantinides AG, Husson L. Colour quantisation through dithering techniques. InImage Processing, 2003. ICIP 2003. Proceedings. 2003 International Conference on 2003 Sep 14 (Vol. 1, pp. I469). IEEE.

(27)
Chung KL, Wu ST. Inverse halftoning algorithm using edgebased lookup table approach. IEEE Transactions on Image Processing. 2005 Oct;14(10):15839.

(28)
Liu YF, Guo JM, Lee JD. Inverse halftoning based on the Bayesian theorem. IEEE Transactions on Image Processing. 2011 Apr;20(4):107784.

(29)
Finkel RA, Bentley JL. Quad trees a data structure for retrieval on composite keys. Acta informatica. 1974 Mar 1;4(1):19.

(30)
Hien TD, Nakao Z, Chen YW. Robust multilogo watermarking by RDWT and ICA. Signal Processing. 2006 Oct 1;86(10):298193.
 (31) ”SIPI Image Database”. Sipi.usc.edu. N.p., 2016. Web. 25 Mar. 2016.