CN111310134B - Screen watermark generation method, device and equipment - Google Patents

Screen watermark generation method, device and equipment Download PDF

Info

Publication number
CN111310134B
CN111310134B CN201811508616.4A CN201811508616A CN111310134B CN 111310134 B CN111310134 B CN 111310134B CN 201811508616 A CN201811508616 A CN 201811508616A CN 111310134 B CN111310134 B CN 111310134B
Authority
CN
China
Prior art keywords
color
watermark
screen
sub
image block
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811508616.4A
Other languages
Chinese (zh)
Other versions
CN111310134A (en
Inventor
刘惠瑛
刘永亮
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201811508616.4A priority Critical patent/CN111310134B/en
Publication of CN111310134A publication Critical patent/CN111310134A/en
Application granted granted Critical
Publication of CN111310134B publication Critical patent/CN111310134B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/10Protecting distributed programs or content, e.g. vending or licensing of copyrighted material ; Digital rights management [DRM]
    • G06F21/16Program or content traceability, e.g. by watermarking

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • Technology Law (AREA)
  • Computer Hardware Design (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Image Processing (AREA)
  • Editing Of Facsimile Originals (AREA)

Abstract

The application discloses a screen watermark generation method, which comprises the following steps: acquiring watermark information for generating a screen watermark; acquiring a screenshot; determining the color of the screen watermark according to the color of the screen capture part area; and generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark. The problem of screen watermark invalidation caused by the fact that the background color of the screen is the same as the color of the screen watermark is solved.

Description

Screen watermark generation method, device and equipment
Technical Field
The present application relates to the field of digital watermarking technologies, and in particular, to a screen watermark generation method and apparatus, an electronic device, and a storage device. The application also relates to a data processing method.
Background
The recent prevalence of significant and pernicious data security incidents, particularly internal breaches, has made traditional data security architectures even more challenging. The digital watermarking technology is a guarantee means for preventing data leakage, and can play a role in tracing to the source of data and protecting copyright. At present, digital watermarking technology is mainly focused on digital media products such as images, videos and audios, and screen watermarking technology is developed slowly.
The security problem faced by screens as carriers for the presentation of information is very serious. And the information leakage is easier by carrying out secret divulging modes such as screen capture, photographing and the like on the screen with the sensitive information. How to perform security protection on the screen display information gradually becomes a hot problem. In order to ensure the safety of the information displayed on the screen, one method is to replace the original pixel points of the screen with a dot diagram with preset meanings. However, in the case where the background color of the screen is similar to the color of the bitmap in the preset meaning, the screen watermark may be disabled. Therefore, how to avoid the failure of the screen watermark caused by the fact that the background color of the screen is the same as the color of the screen watermark is a problem to be solved.
Disclosure of Invention
The application provides a screen watermark generation method, which aims to solve the problem of screen watermark failure caused by the fact that the background color of a screen is the same as the color of a screen watermark.
The application provides a screen watermark generation method, which comprises the following steps:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
and generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
Optionally, the obtaining watermark information for generating a screen watermark includes:
acquiring at least any one of the following user information: user account information and user login information;
and using the user information as the watermark information.
Optionally, the acquiring the screenshot includes: and acquiring a screenshot according to a preset frequency.
Optionally, the determining the color of the screen watermark according to the color of the screen capture partial area includes:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range.
Optionally, the setting, according to the color of the sub-tile block, a value range of the color of the screen watermark in the sub-tile block region includes:
determining a main color block of the sub-image block according to the color of the sub-image block;
determining the color of a main color block of the sub-image block;
and setting the value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block.
Optionally, the determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range includes:
receiving a designated color of a screen watermark;
judging whether the designated color belongs to the value range, if so, taking the designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark; if not, adjusting the designated color according to the value range, and taking the adjusted designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark.
Optionally, the determining, according to the value range, the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark includes:
receiving a contrast preset value of the color of the screen capture and the color of the screen watermark;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the preset contrast value and the value range.
Optionally, the determining the color of the screen watermark according to the color of the screen capture partial area includes:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
determining the main color of the sub-image block according to the color proportion of the sub-image block; wherein, the main color is a color with a color proportion meeting a preset proportion condition;
obtaining an average value of the main colors;
and setting the color of the screen watermark of the sub-image block area according to the average value.
Optionally, the setting, according to the average value, the color of the screen watermark of the sub-tile area includes:
and taking the color with the color difference value meeting the preset color difference threshold range with the main color as the color of the screen watermark of the sub-image block area.
Optionally, the generating a screen watermark according to the watermark information, the color of the screen watermark, and a preset rule for generating the screen watermark includes:
and according to the preset rule and the color of the screen watermark, drawing the watermark information into the screen watermark.
Optionally, the method further includes:
displaying the screen watermark in a dotted manner on the uppermost layer of the screen; or,
and setting the attribute of the screen watermark as a non-mouse event target.
Optionally, the method further includes: and displaying the watermark layer corresponding to the screen watermark on the uppermost layer of the screen in a semitransparent mode or a transparent mode.
Optionally, the generating a screen watermark according to the watermark information, the color of the screen watermark, and the preset rule for generating a screen watermark includes: generating a screen watermark by a process for generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark;
the method further comprises the following steps: and the process judges whether an instruction for closing the process is obtained or not, and if so, the instruction is refused to be executed.
The present application further provides a screen watermark generating apparatus, including:
a watermark information acquisition unit for acquiring watermark information for generating a screen watermark;
a screenshot obtaining unit for obtaining a screenshot;
the screen watermark color determining unit is used for determining the color of the screen watermark according to the color of the screen capture part area;
and the screen watermark generating unit is used for generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
The present application further provides an electronic device, including:
a memory, and a processor;
the memory is to store computer-executable instructions, and the processor is to execute the computer-executable instructions to:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
and generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
The present application further provides a storage device storing instructions capable of being loaded by a processor and performing the steps of:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
and generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
The present application further provides a data processing method, including:
acquiring original data;
acquiring a screenshot;
determining the color of the identification data displayed on the screen according to the color of the screenshot partial area;
and generating the identification data according to the original data, a preset rule for generating the identification data and the color of the identification data.
Compared with the prior art, the method has the following advantages:
according to the screen watermark generation method, the color of the screen watermark is determined according to the color of the screen capture partial area, the screen watermark is generated according to the preset rule for generating the screen watermark by using the color of the screen watermark, the color of the screen capture changes along with the change of a screen display picture, and the color of the screen watermark can be correspondingly adjusted along with the change of the color of the screen capture, so that the condition that the color of the screen watermark is the same as the background color of the screen can be avoided, and the problem of screen watermark invalidation caused by the fact that the background color of the screen is possibly the same as the color of the screen watermark is solved.
Drawings
Fig. 1 is a processing flow chart of a screen watermark generation method according to a first embodiment of the present application;
FIG. 2 is a flowchart of a process for determining the color of a screen watermark provided in a first embodiment of the present application;
fig. 3 is a schematic diagram of a screen watermark generating apparatus according to a second embodiment of the present application;
FIG. 4 is a schematic diagram of an electronic device provided by a third embodiment of the present application;
fig. 5 is a processing flow chart of a data processing method according to a fifth embodiment of the present application;
fig. 6 is a processing flow chart of a data processing method according to a sixth embodiment of the present application.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present application. This application is capable of implementation in many different ways than those herein set forth and of similar import by those skilled in the art without departing from the spirit of this application and is therefore not limited to the specific implementations disclosed below.
The application provides a screen watermark generation method and device, electronic equipment and storage equipment. The application also provides a data processing method. Details are described in the following examples one by one.
A first embodiment of the present application provides a screen watermark generating method.
A screen watermark generating method provided in a first embodiment of the present application is described below with reference to fig. 1 and fig. 2.
The screen watermark generating method shown in fig. 1 includes: step S101 to step S104.
Step S101, acquiring watermark information for generating a screen watermark.
The screen watermark is a digital watermark obtained by embedding watermark information into a screen as a carrier object.
The watermark information refers to identification information to be embedded into the carrier object. The watermark information can be directly embedded into the carrier object or indirectly indicate, for example, the structure of a specific area is modified, the use value of the original carrier object is not influenced, and the watermark information is not easy to be ascertained and modified again. But the watermark information can be identified and recognized by the producer. The watermark information embedded in the carrier can achieve the purposes of confirming content creators and purchasers, transmitting secret information, judging whether the carrier object is tampered or not and the like. The watermark information may be a company name of a certain company, or may be an employee number or other identification information of a certain employee.
The acquiring watermark information for generating the screen watermark includes: acquiring at least any one of the following user information: user account information and user login information; and using the user information as the watermark information.
For example, user account information of a login operating system is obtained as watermark information; the watermark information may also include the time when the user logged into the system. For another example, the user account information for accessing the web page currently displayed on the screen is obtained as the watermark information, and the watermark information may further include any one of the following information: user access time, device information used by the user to access the webpage, and address information.
Further, the watermark information may be information in the form of a character string, or may be presented in other forms, for example, in the form of an image with a preset meaning.
Further, user information for use as the watermark information may be stored in a storage unit, for example, in a TXT document, from which the watermark information is acquired when a screen watermark is generated in a subsequent step.
Step S102, a screenshot is obtained.
The screen may be a display screen of a computing device, such as a screen of a desktop computer, a laptop computer, a tablet computer, a mobile phone, and the like. And performing screen capture or screenshot on the screen to be embedded with the watermark information to obtain the screen capture. The screenshot may be a picture obtained by capturing a current picture in the whole screen, or a picture obtained by capturing any regional content of the current picture in the screen. For example, the current screen is a chat window of an instant messenger, and only the chat window is captured as the screenshot. And in another example, the function similar to a screen capture key PrtScn on a computer keyboard is realized, and a full screen picture is captured to be used as the screen capture. The screen shot may be a JPEG formatted picture.
Preferably, the acquiring the screenshot includes: and acquiring a screenshot according to a preset frequency. Specifically, screen capture or screenshot operation is performed on the screen according to a certain period, so that a screen capture is obtained. And in the subsequent steps, the color of the partial area of the acquired screenshot is analyzed to obtain the color for generating the screen watermark. Because the acquired screen capture at each time can be the capture of the current screen into which the watermark information is to be embedded, the color of the screen watermark can be changed according to the capture color of the current screen into which the watermark information is to be embedded according to a certain period, and the color of the screen watermark can be prevented from being the same as or similar to the color of the background of the screen, so that the screen watermark is displayed.
And step S103, determining the color of the screen watermark according to the color of the screen capture partial area.
The determining the color of the screen watermark according to the color of the screen capture partial area comprises the following steps:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range.
For example, the acquired screenshot is a JPEG picture, and the acquired screenshot is divided into N sub-tiles; obtaining a pixel matrix of each sub-image block, and analyzing the color channel pixel value RGB of each pixel point in the pixel matrix of the N sub-image blocks respectively; and setting the value range of the color channel pixel value RGB of the screen watermark of the sub-image block area of each sub-image block corresponding to the screen by taking the color value analysis as a reference.
In the embodiment of the application, the value range of the color of the screen watermark of the sub-image block area is set by the following processing:
determining a main color block of the sub-image block according to the color of the sub-image block;
determining the color of a main color block of the sub-image block;
and setting the value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block.
A specific implementation manner in the embodiment of the present application includes analyzing color values of sub-tiles by using a mosaic technology. For example, the screenshot is divided into N sub-tiles, and the determination procedure of the color of the screen watermark of the sub-tile region is described by taking one sub-tile as an example. Referring to fig. 2, fig. 2 shows a flowchart of a process for determining a color of a screen watermark of a sub-block region, including:
s103-1, processing the sub-image blocks by adopting a mosaic technology; namely, the details of the color gradation of the sub-image blocks are degraded into small color blocks with different colors, the small color blocks are square small blocks with the same size, and all pixel values in each square small block are equal to the pixel value of the first pixel at the upper left corner;
s103-2, determining a main color block of the mosaic sub-image block; specifically, a color with a large proportion is used as a main color block;
s103-3, setting the value range of the screen watermark color of the screen area corresponding to the sub-image block; specifically, the value range is different from the following colors: the color of the dominant color block and its similar color.
Further, the determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range includes:
receiving a specified color of a screen watermark;
judging whether the designated color belongs to the value range, if so, taking the designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark; if not, adjusting the designated color according to the value range, and taking the adjusted designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark.
Preferably, the contrast between the screen watermark and the screen background is preset, that is, the preset contrast value between the color of the screenshot and the color of the screen watermark is determined, and the color of the screen watermark is determined according to the contrast. The method specifically comprises the following steps:
receiving a preset contrast value of the color of the screenshot and the color of the screen watermark;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the preset contrast value and the value range.
For example, receiving the contrast of the color of the user-defined screen watermark, and selecting a complementary color enhanced watermark effect with the color contrast of the main color block of the sub-image block; or selecting a color with a preset color difference with the main color block of the sub-image block to generate the screen watermark, wherein the preset color difference can be that the difference of pixel values is 5-30 pixel values, so that the screen watermark can be displayed, and the visual interference is reduced.
In another specific implementation of the embodiment of the present application, the color of the screen watermark of the sub-tile region is determined according to an average value of the primary colors of the screen shots. Specifically, the determining the color of the screen watermark according to the color of the screen capture partial area includes:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
determining the main color of the sub-image block according to the color proportion of the sub-image block; wherein, the main color is a color with a color proportion meeting a preset proportion condition;
obtaining an average value of the main colors;
and setting the color of the screen watermark of the sub-image block area according to the average value.
Wherein the color of the screen watermark of the sub tile area is set by: and taking the color with the color difference value meeting the preset color difference threshold range with the main color as the color of the screen watermark of the sub-image block area. The selection of the preset color difference threshold range needs to make the color of the screen watermark different from the following colors: the main color and the similar color of the sub-image blocks ensure that the screen watermark can be displayed in the corresponding area of the sub-image blocks on the screen, thereby achieving the purpose of preventing the shooting attack. When a user takes a picture of a screen embedded with the screen watermark, the screen watermark and the sensitive information are taken into the picture together, and equipment or equipment user information is identified according to the screen watermark information of the picture with the sensitive information, so that tracking and tracing are carried out.
And step S104, generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
In the embodiment of the present application, the screen watermark is generated by the following processing: and according to the preset rule and the color of the screen watermark, drawing the watermark information into the screen watermark.
Preferably, the watermark information is drawn on a watermark layer with the same size as the full screen according to the preset rule and the color of the screen watermark determined in the above step, the watermark layer corresponding to the screen watermark is displayed on the uppermost layer of the screen in a semitransparent mode or a transparent mode, and the generated screen watermark is the full screen watermark. The full-screen watermark enables each window to be under the watermark layer under the condition that a user opens a plurality of windows, and avoids the condition that the window can avoid the screen watermark. The watermark layer corresponding to the screen watermark is displayed in a transparent mode, display card driving is not required to be called, efficiency can be improved, and complexity of the screen watermark is reduced. The watermark layer corresponding to the screen watermark is displayed in a semitransparent mode, so that the information of a lower layer window of the watermark layer is not covered and the receiving operation trigger of the lower layer window is not influenced under the condition that the watermark is displayed.
In a specific implementation manner of the embodiment of the present application, the method further includes obtaining watermark information used for generating the screen watermark from a storage unit in which the watermark information is stored. Of course, the watermark information for generating the screen watermark may also be generated in real time, for example, user information is acquired, and the user information is used as the watermark information.
In a specific implementation manner of the embodiment of the present application, the method further includes: displaying the screen watermark in a dotted manner on the uppermost layer of the screen; or setting the attribute of the screen watermark as a non-mouse event target. When the watermark is displayed in a dot form, the lower window of the watermark layer of the watermark of the display screen can receive mouse click, so that not only is the calculation consumption of the system reduced, but also the operation of a user is not influenced.
In practical implementation, in a specific embodiment, the process for generating the screen watermark generates the screen watermark according to the watermark information, the color of the screen watermark, and the preset rule for generating the screen watermark. The process also judges whether an instruction for closing the process is obtained, and if so, the instruction is refused to be executed. In another embodiment, the method is implemented by a screen watermarking system, and the monitoring module monitors the operation behavior of the user, and refuses to execute the operation of closing the screen watermarking system when the monitoring module monitors that the user closes the operation of the screen watermarking system.
Now, a detailed description is given of an implementation of the screen watermark generation method provided in the first embodiment of the present application. According to the screen watermark generation method, the color of the screen watermark is determined according to the color of the screen capture partial area, and the screen watermark is generated according to the preset rule for generating the screen watermark by using the color of the screen watermark, so that the color of the screen watermark can be correspondingly adjusted along with the change of the color of the screen capture, the color of the screen watermark is prevented from being identical to the background of the screen, and the problem of screen watermark failure caused by the fact that the background color of the screen is possibly identical to the color of the screen watermark is solved.
Corresponding to the screen watermark generation method provided in the first embodiment of the present application, a second embodiment of the present application further provides a screen watermark generation apparatus.
Referring to fig. 3, a schematic diagram of a screen watermark generating apparatus provided in a second embodiment of the present application is shown. Since the apparatus embodiments are substantially similar to the method embodiments, they are described in a relatively simple manner, and reference may be made to the corresponding description of the method embodiments for relevant portions.
A second embodiment provides a screen watermark generation apparatus including:
a watermark information acquisition unit 301 configured to acquire watermark information for generating a screen watermark;
a screenshot obtaining unit 302 for obtaining a screenshot;
a screen watermark color determining unit 303, configured to determine a color of a screen watermark according to a color of the screen capture partial area;
a screen watermark generating unit 304, configured to generate a screen watermark according to the watermark information, the color of the screen watermark, and a preset rule for generating the screen watermark.
The watermark information obtaining unit 301 is specifically configured to:
acquiring at least any one of the following user information: user account information and user login information;
and using the user information as the watermark information.
The screenshot obtaining unit 302 is specifically configured to: and acquiring a screenshot according to a preset frequency.
The screen watermark color determining unit 303 is specifically configured to:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range.
The screen watermark color determining unit 303 is specifically configured to:
determining a main color block of the sub-image block according to the color of the sub-image block;
determining the color of a main color block of the sub-image block;
and setting the value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block.
The screen watermark color determining unit 303 is specifically configured to:
receiving a specified color of a screen watermark;
judging whether the designated color belongs to the value range, if so, taking the designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark; if not, adjusting the designated color according to the value range, and taking the adjusted designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark.
The screen watermark color determining unit 303 is specifically configured to:
receiving a preset contrast value of the color of the screenshot and the color of the screen watermark;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the preset contrast value and the value range.
The screen watermark color determining unit 303 is specifically configured to:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
determining the main color of the sub-image block according to the color proportion of the sub-image block; wherein, the main color is a color with a color proportion meeting a preset proportion condition;
obtaining an average value of the main colors;
and setting the color of the screen watermark of the sub-image block area according to the average value.
The screen watermark color determining unit 303 is specifically configured to:
and taking the color with the color difference value meeting the preset color difference threshold range with the main color as the color of the screen watermark of the sub-image block area.
The screen watermark generating unit 304 is specifically configured to: and according to the preset rule and the color of the screen watermark, drawing the watermark information into the screen watermark.
Wherein the apparatus further comprises a display unit for:
displaying the screen watermark in a dotted manner on the uppermost layer of the screen; or,
and setting the attribute of the screen watermark as a non-mouse event target.
Wherein the display unit is further configured to: and displaying the watermark layer corresponding to the screen watermark on the uppermost layer of the screen in a semitransparent mode or a transparent mode.
The screen watermark generating unit 304 is specifically configured to: generating a screen watermark by a process for generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark; the device further comprises a monitoring unit for: and the process judges whether an instruction for closing the process is obtained or not, and if so, refuses to execute the instruction.
The third embodiment of the present application further provides an electronic device for implementing the screen watermark generating method, and fig. 4 shows a schematic diagram of an electronic device provided in the third embodiment.
The electronic device provided by the third embodiment is relatively simple to describe, and please refer to the corresponding description of the first embodiment for relevant portions.
A third embodiment provides an electronic device comprising:
a memory 401, and a processor 402;
the memory 401 is configured to store computer-executable instructions, and the processor 402 is configured to execute the computer-executable instructions to:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
and generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions:
acquiring at least any one of the following user information: user account information and user login information;
and using the user information as the watermark information.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions: and acquiring a screenshot according to a preset frequency.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions:
determining a main color block of the sub-image block according to the color of the sub-image block;
determining the color of a main color block of the sub-image block;
and setting the value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions:
receiving a specified color of a screen watermark;
judging whether the designated color belongs to the value range, if so, taking the designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark; if not, adjusting the designated color according to the value range, and taking the adjusted designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions:
receiving a contrast preset value of the color of the screen capture and the color of the screen watermark;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the preset contrast value and the value range.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
determining the main color of the sub-image block according to the color proportion of the sub-image block; the main color is a color with a color proportion meeting a preset proportion condition;
obtaining an average value of the main colors;
and setting the color of the screen watermark of the sub-image block area according to the average value.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions: and taking the color with the color difference value with the main color meeting the preset color difference threshold range as the color of the screen watermark of the sub-image block area.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions: and according to the preset rule and the color of the screen watermark, drawing the watermark information into the screen watermark.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions: displaying the screen watermark in a dotted manner on the uppermost layer of the screen; or setting the attribute of the screen watermark as a non-mouse event target.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions: and displaying the watermark layer corresponding to the screen watermark on the uppermost layer of the screen in a semitransparent mode or a transparent mode.
Optionally, the processor 402 is further configured to execute the following computer-executable instructions: generating a screen watermark by a process for generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark; and judging whether an instruction for closing the process is obtained or not, and if so, refusing to execute the instruction.
The fourth embodiment of the present application further provides a storage device for the screen watermark generating method, which is described more simply, and please refer to the corresponding description of the first embodiment for related parts.
A fourth embodiment provides a memory device storing instructions capable of being loaded by a processor and performing the steps of:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
and generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
A fifth embodiment of the present application provides a data processing method based on the first embodiment. Since the fifth embodiment is based on the first embodiment, the description is simple, and please refer to the corresponding description of the first embodiment for related parts. Referring to fig. 5, fig. 5 shows a process flow diagram of the data processing method.
The data processing method shown in fig. 5 includes: step S501 to step S504.
In step S501, raw data is acquired.
The original data refers to identification information to be embedded in the carrier object. The original data can be directly embedded into the carrier object or indirectly expressed, for example, the structure of a specific area is modified, the use value of the original carrier object is not influenced, and the original data is not easy to be ascertained and modified again. But the raw data can be identified and recognized by the producer. The original data embedded in the carrier can achieve the purposes of confirming content creators and purchasers, transmitting secret information, judging whether the carrier object is tampered or not, and the like. The original data may be the company name of a certain company, or may be the employee number or other identification information of a certain employee. The original data may be watermark information.
Specifically, the original data may be data in the form of a character string, or may be presented in other forms, for example, in the form of an image with a preset meaning.
Further, the original data may be user information for use as watermark information and may be stored in a storage unit, e.g. in a TXT document, from which it is retrieved when the original data is used in a subsequent step.
Step S502, acquiring a screenshot.
The screen may be a display screen of a computing device, such as a screen of a desktop computer, a laptop computer, a tablet computer, a cell phone, and so on. And performing screen capture or screenshot on the screen to be embedded with the watermark information to obtain a screen capture. The screenshot may be a picture obtained by capturing a current picture in the whole screen, or a picture obtained by capturing any regional content of the current picture in the screen. For example, the current screen is a chat window of an instant messenger, and only the chat window is captured as the screenshot. And in another example, the function similar to a screen capture key PrtScn on a computer keyboard is realized, and a full screen picture is captured to be used as the screen capture. The screen shot may be a JPEG formatted picture.
The purpose of acquiring the screenshot is to analyze the color of the screenshot so as to take the screen as a carrier object in the following, and embed the original data on the screen according to the color of the screenshot to generate identification data.
Preferably, the acquiring the screenshot includes: and acquiring a screenshot according to a preset frequency. Specifically, screen capture or screenshot operation is performed on the screen according to a certain period, so that a screen capture is obtained. In the subsequent steps, the color of the partial region of the acquired screenshot is analyzed to obtain the color for generating the identification data. The acquired screenshot can be the screenshot of the current screenshot of the original data to be embedded, so that the color of the identification data can be changed according to the change of the color of the current screenshot of the original data to be embedded according to a certain period, the color of the identification data can be prevented from being the same as or similar to the color of the background of the screen, and the identification data can be displayed.
And S503, determining the color of the identification data displayed on the screen according to the color of the screenshot partial area.
In the embodiment of the present application, determining the color of the identification data displayed on the screen by the following processing includes:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
setting the value range of the color of the identification data of the sub-image block area according to the color of the sub-image block;
and determining the color of the identification data according to the value range.
For example, the acquired screenshot is a JPEG picture, and the acquired screenshot is divided into N sub-image blocks; obtaining a pixel matrix of each sub-image block, and analyzing the color channel pixel value RGB of each pixel point in the pixel matrix of the N sub-image blocks respectively; and setting the value range of the color channel pixel value RGB of the identification data of the sub-image block area of each sub-image block on the screen corresponding to each sub-image block by taking the color value analysis as reference.
In the embodiment of the present application, the value range of the color of the identification data of the sub-tile block region is set by the following processing:
determining a main color block of the sub-image block according to the color of the sub-image block;
determining the color of a main color block of the sub-image block;
and setting the value range of the color of the identification data of the sub-image block area according to the color of the main color block of the sub-image block.
A specific implementation manner in the embodiment of the present application includes analyzing color values of sub-tiles by using a mosaic technology. Taking one of the sub-tiles as an example to illustrate a process of determining the color of the identification data of the sub-tile area, the process includes:
mosaic the sub-picture blocks; namely, the details of the color gradation of the sub-image blocks are degraded into small color blocks with different colors, the small color blocks are square small blocks with the same size, and all pixel values in each square small block are equal to the pixel value of the first pixel at the upper left corner;
determining a main color block of the mosaic sub-image block; specifically, a color with a large proportion is used as a main color block;
setting a value range of the color of the identification data of the screen area corresponding to the sub-image block; specifically, the value range is different from the following colors: the color of the dominant color patch and its similar colors.
Further, the determining the color of the identification data according to the value range includes:
receiving a specified color of the identification data;
judging whether the designated color belongs to the value range, if so, taking the designated color as the color of the identification data; if not, adjusting the designated color according to the value range, and taking the adjusted designated color as the color of the identification data.
Preferably, the contrast between the identification data and the screen background is preset, that is, a preset contrast value between the color of the screenshot and the color of the identification data is determined, and the color of the identification data is determined according to the contrast. The method specifically comprises the following steps:
receiving a preset contrast value of the color of the screenshot and the color of the identification data;
and determining the color of the identification data according to the preset contrast value and the value range.
For example, receiving the contrast of the color of the user-defined identification data, and selecting a complementary color enhanced watermark effect with a large contrast with the color of the main color block of the sub-image block; or selecting a color having a predetermined color difference with the main color block of the sub-color block to generate the identification data, wherein the predetermined color difference can be a pixel value difference of 5-30 pixel values, so that the identification data can be displayed, and the visual interference can be reduced.
In another specific implementation of the embodiment of the present application, the color of the identification data of the sub-tile region is determined according to an average of the primary colors of the screenshots. Specifically, the determining the color of the identification data according to the color of the partial area of the screenshot includes:
dividing the screenshot into a plurality of sub-tiles;
acquiring the color of the sub-image block;
determining the main color of the sub-image block according to the color proportion of the sub-image block; the main color is a color with a color proportion meeting a preset proportion condition;
obtaining an average value of the main colors;
and setting the color of the identification data of the sub-image block area according to the average value.
Wherein the color of the identification data of the sub tile region is set by: and taking the color with the color difference value meeting the preset color difference threshold range with the main color as the color of the identification data of the sub-image block area. The selection of the preset color difference threshold range requires that the color of the identification data is different from the following colors: the main color and the similar color of the sub-image blocks ensure that the identification data can be displayed in the corresponding area of the sub-image blocks on the screen, thereby achieving the purpose of preventing the photo attack. When a user takes a picture of the screen embedded with the identification data, the identification data and the sensitive information are taken into the picture together, and the equipment or the equipment user information is identified according to the identification data of the picture with the sensitive information, so as to track and trace the source.
Step S504, generating the identification data according to the original data, a preset rule for generating the identification data and the color of the identification data.
In the embodiment of the present application, the identification data is generated by the following processes: and drawing the original data into identification data according to the preset rule and the color of the identification data.
Preferably, according to the preset rule and the color of the identification data determined in the above step, the original data is drawn on a watermark layer with the same size as the full screen, and the watermark layer corresponding to the identification data is displayed on the uppermost layer of the screen in a semitransparent mode or a transparent mode. The watermark layer is full-screen in size, so that under the condition that a user opens a plurality of windows, each window is under the watermark layer, and the condition that the window can avoid identification data is avoided. The watermark layer corresponding to the identification data is displayed in a transparent mode, a display card drive is not required to be called, the efficiency can be improved, and the complexity of displaying the identification data is reduced. Displaying the watermark layer corresponding to the identification data in a semitransparent mode, wherein under the condition of displaying the identification data, the information of a lower layer window of the watermark layer is not covered, and the receiving operation trigger of the lower layer window is not influenced.
In a specific implementation manner of the embodiment of the present application, the method further includes obtaining original data used for generating the identification data from a storage unit in which the original data is stored. Of course, the original data for generating the identification data may be generated in real time, for example, user information is obtained, and the user information is used as the original data.
In a specific implementation manner of the embodiment of the present application, the method further includes: and displaying the identification data on the uppermost layer of the screen in a dotted manner, so that the lower layer window of the watermark layer can accept mouse click, not only is the calculation consumption of the system reduced, but also the operation of a user is not influenced.
In practical implementation, in a specific embodiment, the process for generating the identification data generates the identification data according to the original data, the color of the identification data, and a preset rule for generating the identification data. The process also judges whether an instruction for closing the process is obtained, and if so, the instruction is refused to be executed. In another embodiment, the method is implemented by an identification data system, and the monitoring module monitors the user operation behavior, and when the monitoring module monitors that the user closes the identification data system, the monitoring module refuses to execute the operation of closing the identification data system.
According to the screen watermark generation method, the color of the identification data is determined according to the color of the screen capture partial area, the color of the identification data is used, and the identification data is generated according to the preset rule for generating the identification data, so that the color of the identification data can be correspondingly adjusted along with the change of the color of the screen capture, the condition that the color of the identification data is the same as the background of a screen is avoided, and the problem that the identification data is invalid due to the fact that the background color of the screen is possibly the same as the color of the identification data is solved.
Based on the foregoing embodiments, a sixth embodiment of the present application provides a data processing method. Since the sixth embodiment is based on the above embodiments, the description is simple, and the relevant portions should be referred to the corresponding description of the above embodiments. Referring to fig. 6, fig. 6 shows a process flow diagram of the data processing method.
The data processing method shown in fig. 6 includes: step S601 to step S603.
Step S601, acquiring an image of the target interface.
The target interface may be an interface displayed by a display screen of a computing device. Specifically, the image of the target interface may be obtained by performing screenshot or screen capture on the target interface. For example, the current picture in the whole screen may be captured to obtain a picture of the target interface, or the current picture in the screen may be captured to obtain any regional content of the current picture. Of course, the image of the target interface may also be obtained in other manners, for example, the image of the target interface is obtained by obtaining interface element information showing the target interface.
Preferably, the image of the target interface is acquired according to a preset frequency. Specifically, the screen capture or screen capture operation may be performed on the target interface according to a certain period, so as to obtain an image of the target interface. In the subsequent steps, the color of the image of the target interface acquired each time is analyzed to determine the color of the target watermark. Because the image of the target interface obtained each time is the current display content of the target interface, and the colors of the images may be different, the color for generating the target watermark obtained by each analysis is changed correspondingly, so that the target watermarks with different colors can be obtained, that is, the color of the target watermark is changed along with the change of the color of the image.
Step S602, determining the color of the target watermark according to the color of the image.
In the embodiment of the present application, the color of the target watermark is specifically determined by the following processing:
dividing the image into a plurality of sub-tiles;
acquiring the color of the sub-image block;
and determining the color of the target watermark according to the color of the sub-image block.
For example, the acquired image of the target interface is a JPEG picture, and the image is divided into N sub-image blocks; and obtaining a pixel matrix of each sub-image block, and analyzing the color channel pixel value (RGB value) of each pixel point in the pixel matrices of the N sub-image blocks respectively to determine the color channel pixel value of the target watermark.
For another example, the main color of the sub-image block is determined according to the color proportion of the sub-image block; determining the watermark color of the sub-image block area according to the main color of the sub-image block; and obtaining the color of the target watermark according to the watermark color of the sub-image block area.
Further, the method also comprises the following steps: acquiring a contrast preset value of the color of the image and the color of the target watermark; and determining the color of the target watermark for enhancing the watermark effect or reducing the visual interference of the watermark according to the preset contrast value. For example, determining the main color of the image according to the color ratio, and selecting a complementary color with a large contrast ratio with the main color of the image as the color of the target watermark according to the obtained preset contrast ratio value so as to enhance the watermark effect; or, selecting a color having a slight color difference with the main color of the image as a watermark color to reduce visual interference of the watermark, where the slight color difference refers to a color difference that a pixel value difference value meets a preset threshold value, for example, 5 to 30 pixel values, and can display the target watermark and reduce the visual interference.
For another example, the image is divided into a plurality of sub-image blocks, and the main color of the sub-image blocks is determined; selecting complementary colors with large contrast with the main colors of the sub-image blocks as watermark colors of the sub-image block areas according to the main colors of the sub-image blocks and the preset contrast value; and obtaining the color of the target watermark by the watermark color of the sub-image block area, wherein the color of the target watermark can achieve the effect of enhancing the watermark. If the color with slight color difference with the main color of the sub-image block is selected as the watermark color of the sub-image block area, the target watermark which can display the target watermark and reduce the visual interference can be obtained.
And step S603, generating the target watermark according to the color of the target watermark.
In the embodiment of the present application, the target watermark is generated by the following processing:
acquiring a user ID;
and generating the target watermark according to the color of the target watermark and the user ID.
The user ID is information capable of identifying a device or a device user, for example: user account information and user login information. The user ID is used as watermark information, so that the purpose of preventing the photo attack can be achieved. When a user takes a picture of a target interface embedded with a user ID as a target watermark, the user ID and the display information of the target interface are taken into the picture together, and the user information of the equipment can be identified according to the target watermark of the picture with sensitive information, so that tracking and tracing are performed.
Further, the watermark information may be information in the form of a character string, or may be presented in other forms, for example, in the form of an image with a preset meaning.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
1. Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include non-transitory computer readable media (transient media), such as modulated data signals and carrier waves.
2. As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and so forth) having computer-usable program code embodied therein.
Although the present application has been described with reference to the preferred embodiments, it is not intended to limit the present application, and those skilled in the art can make variations and modifications without departing from the spirit and scope of the present application, therefore, the scope of the present application should be determined by the claims that follow.

Claims (17)

1. A screen watermark generation method, comprising:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
generating a screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark;
the method for determining the color of the screen watermark according to the color of the screen capture partial area comprises the following first step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block; determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range; wherein, the setting of the value range of the color of the screen watermark of the sub-tile block area according to the color of the sub-tile block includes: determining a main color block of the sub-image block according to the color of the sub-image block; determining the color of a main color block of the sub-image block; setting a value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block;
or, the determining the color of the screen watermark according to the color of the screen capture partial area includes the following second step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; determining the main color of the sub-image block according to the color proportion of the sub-image block; wherein, the main color is a color with a color proportion meeting a preset proportion condition; obtaining an average value of the main colors; and setting the color of the screen watermark of the sub-image block area according to the average value.
2. The method of claim 1, wherein obtaining watermark information for generating a screen watermark comprises:
acquiring at least any one of the following user information: user account information and user login information;
and using the user information as the watermark information.
3. The method of claim 1, wherein the obtaining the screenshot comprises: and acquiring a screenshot according to a preset frequency.
4. The method of claim 1, wherein for the first set of steps, the determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range comprises:
receiving a specified color of a screen watermark;
judging whether the designated color belongs to the value range, if so, taking the designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark; if not, adjusting the designated color according to the value range, and taking the adjusted designated color as the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark.
5. The method of claim 1, wherein for the first set of steps, the determining, according to the value range, a color of the screen watermark for enhancing the screen watermark or reducing visual interference of the watermark comprises:
receiving a preset contrast value of the color of the screenshot and the color of the screen watermark;
and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the preset contrast value and the value range.
6. The method of claim 1, wherein for the second set of steps, the setting a color of a screen watermark for a sub-tile region according to the average value comprises:
and taking the color with the color difference value with the main color meeting the preset color difference threshold range as the color of the screen watermark of the sub-image block area.
7. The method of claim 1, wherein generating the screen watermark according to the watermark information, the color of the screen watermark, and the preset rule for generating the screen watermark comprises:
and according to the preset rule and the color of the screen watermark, drawing the watermark information into the screen watermark.
8. The method of claim 7, further comprising:
displaying the screen watermark in a dotted manner on the uppermost layer of the screen; or,
and setting the attribute of the screen watermark as a non-mouse event target.
9. The method of claim 7, further comprising: and displaying the watermark layer corresponding to the screen watermark on the uppermost layer of the screen in a semitransparent mode or a transparent mode.
10. The method of claim 1, wherein generating the screen watermark according to the watermark information, the color of the screen watermark, and a preset rule for generating the screen watermark comprises: generating a screen watermark by a process for generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark;
the method further comprises the following steps: and the process judges whether an instruction for closing the process is obtained or not, and if so, refuses to execute the instruction.
11. A screen watermark generation apparatus, comprising:
a watermark information acquiring unit for acquiring watermark information for generating a screen watermark;
a screenshot obtaining unit for obtaining a screenshot;
a screen watermark color determining unit, configured to determine a color of a screen watermark according to the color of the screen capture partial area, where the determining the color of the screen watermark according to the color of the screen capture partial area includes the following first step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block; determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range; wherein, the setting of the value range of the color of the screen watermark of the sub-tile block area according to the color of the sub-tile block includes: determining a main color block of the sub-image block according to the color of the sub-image block; determining the color of a main color block of the sub-image block; setting a value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block; or, the determining the color of the screen watermark according to the color of the screen capture partial area includes the following second step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; determining the main color of the sub-image block according to the color proportion of the sub-image block; the main color is a color with a color proportion meeting a preset proportion condition; obtaining an average value of the main colors; setting the color of the screen watermark of the sub-image block area according to the average value;
and the screen watermark generating unit is used for generating the screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark.
12. An electronic device, comprising:
a memory, and a processor;
the memory to store computer-executable instructions, the processor to execute the computer-executable instructions:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
generating a screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark;
the method for determining the color of the screen watermark according to the color of the screen capture partial area comprises the following first step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block; determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range; wherein, the setting of the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block includes: determining a main color block of the sub-image block according to the color of the sub-image block; determining the color of a main color block of the sub-image block; setting a value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block;
or, the determining the color of the screen watermark according to the color of the screen capture partial area includes the following second step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; determining the main color of the sub-image block according to the color proportion of the sub-image block; wherein, the main color is a color with a color proportion meeting a preset proportion condition; obtaining an average value of the main colors; and setting the color of the screen watermark of the sub-image block area according to the average value.
13. A storage device having stored thereon instructions capable of being loaded by a processor and performing the steps of:
acquiring watermark information for generating a screen watermark;
acquiring a screenshot;
determining the color of the screen watermark according to the color of the screen capture part area;
generating a screen watermark according to the watermark information, the color of the screen watermark and a preset rule for generating the screen watermark;
wherein, the determining the color of the screen watermark according to the color of the screen capture partial area comprises the following first step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; setting the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block; determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the value range; wherein, the setting of the value range of the color of the screen watermark of the sub-image block area according to the color of the sub-image block includes: determining a main color block of the sub-image block according to the color of the sub-image block; determining the color of a main color block of the sub-image block; setting a value range of the color of the screen watermark of the sub-image block area according to the color of the main color block of the sub-image block;
or, the determining the color of the screen watermark according to the color of the screen capture partial area includes the following second step set: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; determining the main color of the sub-image block according to the color proportion of the sub-image block; the main color is a color with a color proportion meeting a preset proportion condition; obtaining an average value of the main colors; and setting the color of the screen watermark of the sub-image block area according to the average value.
14. A data processing method, comprising:
acquiring original data;
acquiring a screenshot;
determining the color of the identification data displayed on the screen according to the color of the screenshot partial area;
generating the identification data according to the original data, a preset rule for generating the identification data and the color of the identification data;
wherein, the determining the color of the identification data displayed on the screen according to the color of the screenshot partial area comprises: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; setting the value range of the color of the identification data of the sub-image block area according to the color of the sub-image block; determining the color of the identification data according to the value range; wherein, the setting of the value range of the color of the identification data of the sub-image block region according to the color of the sub-image block comprises: determining a main color block of the sub-image block according to the color of the sub-image block; determining the color of a main color block of the sub-image block; setting a value range of the color of the identification data of the sub-image block area according to the color of the main color block of the sub-image block;
or,
the determining the color of the identification data displayed on the screen according to the color of the screenshot partial area comprises: dividing the screenshot into a plurality of sub-tiles; acquiring the color of the sub-image block; determining the main color of the sub-image block according to the color proportion of the sub-image block; the main color is a color with a color proportion meeting a preset proportion condition; obtaining an average value of the main colors; and setting the color of the identification data of the sub-image block area according to the average value.
15. A data processing method, comprising:
acquiring an image of a target interface;
determining the color of the target watermark according to the color of the image;
generating a target watermark according to the color of the target watermark;
wherein the determining the color of the target watermark according to the color of the image comprises: dividing the image into a plurality of sub-tiles; acquiring the color of the sub-image block; determining the color of the target watermark according to the color of the sub-image block;
wherein the determining the color of the target watermark according to the color of the sub-image block comprises: obtaining a pixel matrix of each sub-tile; analyzing the color channel pixel value of each pixel point in the pixel matrix of the sub-image block to determine the color of the target watermark;
or, the determining the color of the target watermark according to the color of the sub-tile block includes: determining the main color of the sub-image block according to the color proportion of the sub-image block; determining the watermark color of the sub-image block area according to the main color of the sub-image block; and obtaining the color of the target watermark according to the watermark color of the sub-image block area.
16. The method of claim 15, wherein generating a target watermark based on a color of the target watermark comprises:
acquiring a user ID;
and generating the target watermark according to the color of the target watermark and the user ID.
17. The method of claim 15, further comprising: acquiring a preset contrast value of the color of the image and the color of the target watermark;
the determining the color of the target watermark according to the color of the image comprises: and determining the color of the screen watermark for enhancing the screen watermark or reducing the visual interference of the watermark according to the preset contrast value.
CN201811508616.4A 2018-12-11 2018-12-11 Screen watermark generation method, device and equipment Active CN111310134B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811508616.4A CN111310134B (en) 2018-12-11 2018-12-11 Screen watermark generation method, device and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811508616.4A CN111310134B (en) 2018-12-11 2018-12-11 Screen watermark generation method, device and equipment

Publications (2)

Publication Number Publication Date
CN111310134A CN111310134A (en) 2020-06-19
CN111310134B true CN111310134B (en) 2022-07-22

Family

ID=71150463

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811508616.4A Active CN111310134B (en) 2018-12-11 2018-12-11 Screen watermark generation method, device and equipment

Country Status (1)

Country Link
CN (1) CN111310134B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112288618B (en) * 2020-12-22 2021-05-11 北京联想协同科技有限公司 Picture processing method and device
CN114092307A (en) * 2021-11-25 2022-02-25 合芯科技(苏州)有限公司 Watermark generation method, watermark addition method, watermark tracing equipment and storage medium
TWI796265B (en) 2022-07-27 2023-03-11 友達光電股份有限公司 Display apparatus and image displaying method
CN115659295B (en) * 2022-11-14 2023-06-06 广州闪畅信息科技有限公司 Page protection method, device, equipment and storage medium
CN117237177B (en) * 2023-11-15 2024-03-19 杭州海康威视数字技术股份有限公司 Watermark processing method and device and electronic equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101188749A (en) * 2006-11-20 2008-05-28 索尼株式会社 Video transmission method, video transmission system, and video processing apparatus
CN102404649A (en) * 2011-11-30 2012-04-04 江苏奇异点网络有限公司 Watermark position self-adaptive video watermark adding method
CN104461539A (en) * 2014-12-09 2015-03-25 久邦计算机技术(广州)有限公司 Automatic color matching method for icon base
CN104867096A (en) * 2014-02-25 2015-08-26 腾讯科技(深圳)有限公司 Method for dynamically changing watermark content and device thereof
CN107392832A (en) * 2017-06-30 2017-11-24 广东欧珀移动通信有限公司 Image processing method and related product

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101188749A (en) * 2006-11-20 2008-05-28 索尼株式会社 Video transmission method, video transmission system, and video processing apparatus
CN102404649A (en) * 2011-11-30 2012-04-04 江苏奇异点网络有限公司 Watermark position self-adaptive video watermark adding method
CN104867096A (en) * 2014-02-25 2015-08-26 腾讯科技(深圳)有限公司 Method for dynamically changing watermark content and device thereof
CN104461539A (en) * 2014-12-09 2015-03-25 久邦计算机技术(广州)有限公司 Automatic color matching method for icon base
CN107392832A (en) * 2017-06-30 2017-11-24 广东欧珀移动通信有限公司 Image processing method and related product

Also Published As

Publication number Publication date
CN111310134A (en) 2020-06-19

Similar Documents

Publication Publication Date Title
CN111310134B (en) Screen watermark generation method, device and equipment
US10068071B2 (en) Screen shot marking and identification for device security
JP6127226B1 (en) Image processing apparatus, image processing method, and program
KR102423710B1 (en) Translucent image watermark detection
US8599270B2 (en) Computing device, storage medium and method for identifying differences between two images
US20170104893A1 (en) System and method of pixel manipulation and screen display disruption
CN108563930A (en) A kind of method, apparatus, medium and the system of confidential document addition watermark
US9600298B2 (en) Active and efficient monitoring of a graphical user interface
Gugelmann et al. Screen watermarking for data theft investigation and attribution
CN108427589B (en) Data processing method and electronic equipment
CN111223032A (en) Watermark embedding method, watermark extracting method, watermark embedding device, watermark extracting equipment and data processing method
US10706488B2 (en) Embedding debugging information via watermarks
US8824778B2 (en) Systems and methods for depth map generation
CN110969563B (en) Watermark embedding method, watermark extracting method, watermark embedding device, watermark extracting equipment and data processing method
JP6127225B1 (en) Image processing apparatus, image processing method, and program
CN115659295B (en) Page protection method, device, equipment and storage medium
CN114708138B (en) Network disk image watermark adding method and device, network disk and storage medium
KR102347137B1 (en) Screen data leakage prevention apparatus and method
US20140093121A1 (en) Image processing apparatus and method
US20230325961A1 (en) Zoom agnostic watermark extraction
US20230325959A1 (en) Zoom agnostic watermark extraction
CN113379582A (en) Information adding method, information extracting device and electronic equipment
US20220351323A1 (en) Steganographic techniques for tracking video access events
CN117237177B (en) Watermark processing method and device and electronic equipment
RU2739936C1 (en) Method of adding digital labels to digital image and apparatus for realizing method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 40031972

Country of ref document: HK

GR01 Patent grant
GR01 Patent grant