# US 2020/0288186 A1 · Method for generating video mask information, method for preventing occlusion from barrage, server and client

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2020/0288186 A1
- Document ID: US20200288186A1
- Status: Published application
- Kind: A1
- Application number: 16/440,881
- Filed: 2019-06-13
- Published: 2020-09-10
- Earliest claimed: 2019-02-01
- Assignees: Wangsu Science & Technology Co., Ltd.
- Applicants: Wangsu Science & Technology Co., Ltd.
- Inventors: Lei SUN; Fenglei WANG
- Web page: https://patentgrep.com/patent/US20200288186A1

## CPC

- H04N 21/23424: {involving splicing one content stream with another content stream, e.g. for inserting or substituting an advertisement}
- H04N 21/2353: {specifically adapted to content descriptors, e.g. coding, compressing or processing of metadata}
- G06T 3/00: Geometric image transformations in the plane of the image
- H04N 21/00: Selective content distribution, e.g. interactive television or video on demand [VOD] (real-time bi-directional transmission of motion video data H04N7/14 {; broadcast or conference over packet switching networks H04L12/18})
- H04N 21/2187: Live feed
- H04N 21/23418: {involving operations for analysing video streams, e.g. detecting features or characteristics (television picture signal circuitry for scene change detection H04N5/147; filtering for image enhancement G06T5/00; methods or arrangements for recognising scenes G06V20/00; arrangements characterised by components specially adapted for monitoring, identification or recognition of video in broadcast systems H04H60/59)}
- H04N 21/4318: {by altering the content in the rendering process, e.g. blanking, blurring or masking an image region (image enhancement or restoration in general G06T5/00)}
- H04N 21/435: Processing of additional data, e.g. decrypting of additional data, reconstructing software from modules extracted from the transport stream
- H04N 21/4542: {Blocking scenes or portions of the received content, e.g. censoring scenes}
- H04N 21/45455: {applied to a region of the image}
- G06N 20/00: Machine learning
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION
- G06T: IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

Some embodiments of the present disclosure provide a method for generating video mask information, a method for preventing occlusion from barrage, a server and a client. The method for generating video mask information comprises: identifying, for any video frame in the video data to be parsed, an area where a target object is located in the video frame; selecting a plurality of geometric figures to fit the area where the target object is located, to allow a combination of the plurality of geometric figures to cover the area where the target object is located; and generating the mask information of the video frame according to a fitting parameter of the plurality of geometric figures, and sending the mask information and data of the video frame to a client synchronously. Some embodiments of the present disclosure are adopted to avoid occlusion caused by the barrage information on the video image while the vast majority of the barrage information remains and reducing a bandwidth consumption of the client.

## Claims

### Claim 1

A method for generating video mask information, comprising:
reading video data to be parsed, and identifying, for any video frame in the video data, an area where a target object is located in the video frame;
selecting a plurality of geometric figures to fit the area where the target object is located, to allow a combination of the plurality of geometric figures to cover the area where the target object is located; and
generating mask information of the video frame according to a fitting parameter of the plurality of geometric figures, and sending the mask information and data of the video frame to a client synchronously.

### Claim 2 (depends on 1)

The method of claim 1, wherein, after identifying an area where a target object is located in the video frame, the method further comprises:
generating a binary mask image of the video frame, wherein in the binary mask image, pixels constituting the area where the target object is located have a first pixel value, and other pixels have a second pixel value, wherein the first pixel value and the second pixel value are different.

### Claim 3 (depends on 2)

The method of claim 2, wherein selecting a plurality of geometric figures to fit the area where the target object is located comprises:
in the binary mask map, fitting an area constituted by the pixels having the first pixel value through the plurality of geometric figures.

### Claim 4 (depends on 2)

The method of claim 2, wherein selecting a plurality of geometric figures to fit the area where the target object is located comprises:
dividing the area where the target object is located into one or more sub-areas according to physical features of the target object;
selecting, for any of the sub-areas, a geometric figure fitting with the sub-area, and determining a layout parameter of the geometric figure, to allow the geometric figure drawn according to the layout parameter to cover the sub-area; and
generating a fitting parameter of the geometric figure according to a type of the selected geometric figure and the layout parameter of the selected geometric figure.

### Claim 5 (depends on 4)

The method of claim 4, wherein generating a fitting parameter of the geometric figure comprises:
identifying a preset graphic identifier corresponding to the type of the geometric figure, coding the preset graphic identifier and the layout parameter respectively, and taking coded data as the fitting parameter of the geometric figure.

### Claim 6 (depends on 1, 6)

The method of claim 1, wherein selecting a plurality of geometric figures to fit the area where the target object is located comprises:
dividing the area where the target object is located into one or more sub-areas according to physical features of the target object;
selecting, for any of the sub-areas, a geometric figure fitting with the sub-area, and determining a layout parameter of the geometric figure, to allow the geometric figure drawn according to the layout parameter to cover the sub-area; and
generating a fitting parameter of the geometric figure according to a type of the selected geometric figure and the layout parameter of the selected geometric FIG. 7. The method of claim 6, wherein generating a fitting parameter of the geometric figure comprises:
identifying a preset graphic identifier corresponding to the type of the geometric figure, coding the preset graphic identifier and the layout parameter respectively, and taking coded data as the fitting parameter of the geometric figure.

### Claim 8 (depends on 1)

The method of claim 1, wherein generating mask information of the video frame according to a fitting parameter of the plurality of geometric figures comprises:
adding an auxiliary identification bit to the fitting parameter, and regarding a combination of the auxiliary identification bit and the fitting parameter as the mask information of the video frame; wherein the auxiliary identification bit includes at least one of the following functions:
indicating a data size of the fitting parameter;
indicating the number of geometric figures included in the fitting parameter; or
indicating a data end position of the fitting parameter.

### Claim 9 (depends on 1)

The method of claim 1, wherein the fitting parameter of the video frame is generated in a following manner:
acquiring a training sample set of the target object in advance, wherein the training sample set includes a plurality of image samples each of which includes the target object, and each of the image samples is provided with a tagged label used to represent a fitting parameter of the geometric figure required to cover the target object in the image sample;
training an identification model by using the image samples of the training sample set, to allow, after any image sample is input into a trained identification model, a predicted result output by the trained identification model to be consistent with the fitting parameter represented by the tagged label of the input image sample; and
inputting the video frame into the trained identification model, and regarding the predicted result output by the trained identification model as the fitting parameter of the video frame.

### Claim 10 (depends on 1)

The method of claim 1, wherein generating mask information of the video frame according to a fitting parameter of the plurality of geometric figures comprises:
sorting the fitting parameter of each of the geometric figures according to a size of the geometric figure represented by the fitting parameter, and generating the mask information of the video frame based on the sorted fitting parameter.

### Claim 11

A server, comprising at least a processor and a memory, the memory being used to store computer-readable instructions which, when being executed at least a processor, performs a method for generating video mask information;
wherein the method comprises:
reading video data to be parsed, and identifying, for any video frame in the video data, an area where a target object is located in the video frame;
selecting a plurality of geometric figures to fit the area where the target object is located, to allow a combination of the plurality of geometric figures to cover the area where the target object is located; and
generating mask information of the video frame according to a fitting parameter of the plurality of geometric figures, and sending the mask information and data of the video frame to a client synchronously.

### Claim 12 (depends on 11)

The server of claim 11, wherein, after identifying an area where a target object is located in the video frame, the method further comprises:
generating a binary mask image of the video frame, wherein in the binary mask image, pixels constituting the area where the target object is located have a first pixel value, and other pixels have a second pixel value, wherein the first pixel value and the second pixel value are different.

### Claim 13 (depends on 11)

The server of claim 11, wherein selecting a plurality of geometric figures to fit the area where the target object is located comprises:
dividing the area where the target object is located into one or more sub-areas according to physical features of the target object;
selecting, for any of the sub-areas, a geometric figure fitting with the sub-area, and determining a layout parameter of the geometric figure, to allow the geometric figure drawn according to the layout parameter to cover the sub-area; and
generating a fitting parameter of the geometric figure according to a type of the selected geometric figure and the layout parameter of the selected geometric figure.

### Claim 14 (depends on 13)

The server of claim 13, wherein generating a fitting parameter of the geometric figure comprises:
identifying a preset graphic identifier corresponding to the type of the geometric figure, coding the preset graphic identifier and the layout parameter respectively, and taking coded data as the fitting parameter of the geometric figure.

### Claim 15 (depends on 11)

The server of claim 11, wherein the fitting parameter of the video frame is generated in a following manner:
acquiring a training sample set of the target object in advance, wherein the training sample set includes a plurality of image samples each of which includes the target object, and each of the image samples is provided with a tagged label used to represent a fitting parameter of the geometric figure required to cover the target object in the image sample;
training an identification model by using the image samples of the training sample set, to allow, after any image sample is input into a trained identification model, a predicted result output by the trained identification model to be consistent with the fitting parameter represented by the tagged label of the input image sample; and
inputting the video frame into the trained identification model, and regarding the predicted result output by the trained identification model as the fitting parameter of the video frame.

### Claim 16 (depends on 11)

The server of claim 11, wherein generating mask information of the video frame according to a fitting parameter of the plurality of geometric figures comprises:
sorting the fitting parameter of each of the geometric figures according to a size of the geometric figure represented by the fitting parameter, and generating the mask information of the video frame based on the sorted fitting parameter.

### Claim 17

A method for preventing occlusion from barrage, wherein the method comprises:
receiving video data and barrage data sent by a server, wherein the video data includes at least mask information of a video frame, and the mask information includes a fitting parameter of a plurality of geometric figures; wherein a combination constituted by the plurality of geometric figures covers a target object in the video frame;
parsing the mask information of the video frame to determine, in the video frame, an area where each of the geometric figures is located according to the fitting parameter of the plurality of geometric figures; and
displaying no barrage data corresponding to the area where each of the geometric figures is located when the barrage data is rendered in the video frame.

### Claim 18 (depends on 17)

The method of claim 17, wherein displaying no barrage data corresponding to the area where each of the geometric figures is located comprises:
determining, for a current pixel in the video frame, whether the current pixel falls into the area where a geometric figure is located; and
wherein determining, for a current pixel in the video frame, whether the current pixel falls into the area where the geometric figure is located comprises:
if the current pixel is located in the area where any of the geometric figures is located, displaying no barrage data corresponding to the area where any of the geometric figures is located at the current pixel; and
if the current pixel is located outside the area where each of the geometric figures is located, displaying the barrage data corresponding to the area outside the area where each of the geometric figures is located at the current pixel.

### Claim 19 (depends on 18)

The method of claim 18, wherein in the mask information, the fitting parameter of each of the geometric figure is sorted according to a size of the geometric figure;
according to a sorted result of the fitting parameter of the geometric figure, whether the current pixel falls into the area where each of the geometric figures is located is determined one by one; wherein if the current pixel is determined to fall into the area where a current geometric figure is located, the barrage data corresponding to the area where the current geometric figure is located is not displayed at the current pixel, and a determination process for the current pixel is stopped, and whether a next pixel falls into the area where each of the geometric figures is located is continued to be determined.

### Claim 20 (depends on 17)

The method of claim 17, wherein the mask information of the video frame further includes an auxiliary identification bit of the fitting parameter of the plurality of geometric figures, wherein the auxiliary identification bit includes at least one of the following functions:
indicating a data size of the fitting parameter;
indicating the number of geometric figures included in the fitting parameter; or
indicating a data end position of the fitting parameter; and
wherein parsing the mask information of the video frame comprises:
identifying a character segment of the mask information in the video data according to the auxiliary identification bit, and parsing the identified character segment of the mask information.
