gunjannandy / steganography

Compare efficiency of steganographic processes LSB,DCT and DWT
59 stars 20 forks source link

Doubt regarding embedding watermark using DCT #8

Open GowthamGottimukkala opened 4 years ago

GowthamGottimukkala commented 4 years ago

In your report, you said that the secret message is embedded by modifying the coefficients of the middle-frequency sub-band due to given reasons. But in the code DCT Class -> encode_image function, you embedded each bit of each character of the secret into the LSB of the first element of each block. Why is that?

. .

for quantizedBlock in quantizedDCT:
            #find LSB in DC coeff and replace with message bit
            DC = quantizedBlock[0][0]
            DC = np.uint8(DC)
            DC = np.unpackbits(DC)
            DC[7] = self.bitMess[messIndex][letterIndex]
            DC = np.packbits(DC)
            DC = np.float32(DC)
            DC= DC-255

. . Also, why are you subtracting the value with 255 and making it negative as the maximum value of DC will be 255?