提出了一种基于排序的直接在JPEG码流中嵌入水印的算法,该方法在保证嵌完水印后图像无失真的条件下提高了嵌入容量。根据对JPEG图像中可变长度码使用情况的统计分析,通过将一幅图像中没有使用过的可变长度码映射为使用过的可变长度码来嵌入水印。在建立映射关系之前,首先对码流中出现过的可变长度码依据其在码流中出现的频率进行排序,然后使用排序后的结果建立映射关系,从而提高可变长度码的利用率,进而提高嵌入容量。在水印嵌入过程中,根据相应的映射关系和水印信息将码流中出现的可变长度码替换为映射的可变长度码。分析和实验结果表明,这种方法能够实现较高容量的水印嵌入,并且嵌完水印后图像无失真。
A modified scheme of embedding watermark in JPEG bitstream based on sorting is proposed, which ensures that the embeding capacity is improved while the cover image is loss-less after embedding the watermark. According to the statistical results of variable length eodeing (VLC) usage in an image, watermark is embedded by mapping one unused VLC to one used VLC. Sorting VLC(s) aecording to their appearing rate in the bitstream before mapping, will improve the VLC utilization rate and increase the embedding capacity after sorting. During the data embedding, the codes appearing in the bitstream are replaced by the mapped codes ac-cording to the watermark. The results prove that the proposed scheme has high embedding ca-pacity and can preserve the image with no quality distortion.