IP Library › Granted Patent US 12,744,861
Granted Patent B2
US 12,744,861 · App. 18/254,575 · Granted Sep 22, 2026

Method for replacing background in picture, device, storage medium and program product

Inventors: Yingyi Chen (Beijing, CN); Shaohui Jiao (Beijing, CN)
Assignee: Beijing Bytedance Network Technology Co., Ltd.
H04N5/272G06T7/194G06V10/16G06V10/44G06V10/60G06V10/751
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12,744,861
App. No.
18/254,575
Granted
Sep 22, 2026
Kind
B2
Abstract

A method for replacing a background in a picture, a device, a storage medium and a program product provided in the embodiments relate to image processing technologies and include: acquiring a basic background image of a preset scene, where the basic background image is an image obtained by shooting the preset scene in advance; acquiring a captured picture obtained by currently shooting the preset scene, and determining a current background image of the preset scene according to the basic background image and the captured picture; replacing the current background image in the captured picture with a preset background image to obtain a final captured picture.

Claims (75)

1 . A method for replacing a background in a picture, comprising:

acquiring a basic background image of a preset scene, wherein the basic background image is an image obtained by shooting the preset scene in advance;

acquiring a captured picture obtained by currently shooting the preset scene, and determining a current background image of the preset scene according to the basic background image and the captured picture; and

replacing the current background image in the captured picture with a preset background image to obtain a final captured picture,

wherein the determining the current background image of the preset scene according to the basic background image and the captured picture comprises:

extracting basic feature point information of the basic background image, and extracting shooting feature point information in the captured picture; and

determining a matching relationship between each piece of the basic feature point information and each piece of the shooting feature point information, and determining the current background image in the captured picture according to the matching relationship,

wherein the determining the current background image in the captured picture according to the matching relationship comprises:

stitching a background portion in the captured picture and the basic background image according to the matching relationship, to obtain the current background image of the preset scene in the captured picture,

wherein the method further comprises:

extending a boundary of the current background image to obtain an extended background image; and

replacing the extended background image in the captured picture with the preset background image correspondingly according to the extended background image, to obtain the final captured picture,

wherein the method further comprises:

performing any of the following enhancement processing on the extended background image to obtain an enhanced background image:

stitching seam feathering, light transformation; and

replacing the enhanced background image in the captured picture with the preset background image correspondingly according to the enhanced background image, to obtain the final captured picture, and

wherein the extended background image and the enhanced background image are images extended based on a current shooting angle.

2 . The method according to claim 1 , wherein the replacing the current background image in the captured picture with the preset background image to obtain the final captured picture comprises:

determining a foreground image comprised in the captured picture according to the current background image and the captured picture; and

generating the final captured picture according to the foreground image and the preset background image, wherein a background of the final captured picture is the preset background image, and a foreground of the final captured picture is the foreground image.

3 . The method according to claim 2 , wherein the determining the foreground image comprised in the captured picture according to the current background image and the captured picture comprises:

inputting the current background image and the captured picture into a preset segmentation model, wherein the preset segmentation model is used to output the foreground image comprised in the captured picture;

or, inputting the extended background image, which is determined according to the current background image, and the captured picture into a preset segmentation model, wherein the preset segmentation model is used to output the foreground image comprised in the captured picture;

or, inputting the enhanced background image, which is determined according to the current background image, and the captured picture into a preset segmentation model, wherein the preset segmentation model is used to output the foreground image comprised in the captured picture.

4 . The method according to claim 1 , further comprising:

updating the basic background image to the enhanced background image or the extended background image.

5 . The method according to claim 1 , further comprising:

sending the final captured picture.

6 . An apparatus for replacing a background in a picture, comprising:

at least one processor, and

a memory communicatively connected to the at least one processor; wherein,

the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor is configured to:

acquire a basic background image of a preset scene, wherein the basic background image is an image obtained by shooting the preset scene in advance;

acquire a captured picture obtained by currently shooting the preset scene;

determine a current background image of the preset scene according to the basic background image and the captured picture; and

replace the current background image in the captured picture with a preset background image to obtain a final captured picture,

wherein the at least one processor is further configured to:

extract basic feature point information of the basic background image, and extract shooting feature point information in the captured picture; and

determine a matching relationship between each piece of the basic feature point information and each piece of the shooting feature point information, and determine the current background image in the captured picture according to the matching relationship,

wherein the at least one processor is further configured to:

stitch a background portion in the captured picture and the basic background image according to the matching relationship, to obtain the current background image of the preset scene in the captured picture,

wherein the at least one processor is further configured to:

extend a boundary of the current background image to obtain an extended background image; and

replace the extended background image in the captured picture with the preset background image correspondingly according to the extended background image, to obtain the final captured picture,

wherein the at least one processor is further configured to:

perform any of the following enhancement processing on the extended background image to obtain an enhanced background image:

stitching seam feathering, light transformation; and

replace the enhanced background image in the captured picture with the preset background image correspondingly according to the enhanced background image, to obtain the final captured picture, and

wherein the extended background image and the enhanced background image are images extended based on a current shooting angle.

7 . The apparatus according to claim 6 , wherein the at least one processor is configured to:

determine a foreground image comprised in the captured picture according to the current background image and the captured picture; and

generate the final captured picture according to the foreground image and the preset background image, wherein a background of the final captured picture is the preset background image, and a foreground of the final captured picture is the foreground image.

8 . The apparatus according to claim 7 , wherein the at least one processor is configured to:

input the current background image and the captured picture into a preset segmentation model, wherein the preset segmentation model is used to output the foreground image comprised in the captured picture;

or, input the extended background image, which is determined according to the current background image, and the captured picture into a preset segmentation model, wherein the preset segmentation model is used to output the foreground image comprised in the captured picture;

or, input the enhanced background image, which is determined according to the current background image, and the captured picture into a preset segmentation model, wherein the preset segmentation model is used to output the foreground image comprised in the captured picture.

9 . The apparatus according to claim 6 , wherein the at least one processor is configured to:

send the final captured picture.

10 . A non-transitory computer-readable storage medium, wherein the computer-readable storage medium has a computer-executed instruction stored thereon, and when a processor executes the computer-executed instruction, the processor executes steps of:

acquiring a basic background image of a preset scene, wherein the basic background image is an image obtained by shooting the preset scene in advance;

acquiring a captured picture obtained by currently shooting the preset scene, and determining a current background image of the preset scene according to the basic background image and the captured picture; and

replacing the current background image in the captured picture with a preset background image to obtain a final captured picture,

wherein the computer-executed instruction is further used to perform the following steps:

extracting basic feature point information of the basic background image, and extracting shooting feature point information in the captured picture; and

determining a matching relationship between each piece of the basic feature point information and each piece of the shooting feature point information, and determining the current background image in the captured picture according to the matching relationship,

wherein the computer-executed instruction is further used to perform the following steps:

stitching a background portion in the captured picture and the basic background image according to the matching relationship, to obtain the current background image of the preset scene in the captured picture,

wherein the computer-executed instruction is further used to perform the following steps:

extending a boundary of the current background image to obtain an extended background image; and

replacing the extended background image in the captured picture with the preset background image correspondingly according to the extended background image, to obtain the final captured picture,

wherein the computer-executed instruction is further used to perform the following steps:

performing any of the following enhancement processing on the extended background image to obtain an enhanced background image:

stitching seam feathering, light transformation; and

replacing the enhanced background image in the captured picture with the preset background image correspondingly according to the enhanced background image, to obtain the final captured picture, and

wherein the extended background image and the enhanced background image are images extended based on a current shooting angle.

Assignments (3)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 25, 2023
From: CHEN, YINGYI
To: SHENZHEN JINRITOUTIAO TECHNOLOGY CO., LTD.
Reel/Frame 063768/0303 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 25, 2023
From: JIAO, SHAOHUI
To: BEIJING ZITIAO NETWORK TECHNOLOGY CO., LTD.
Reel/Frame 063768/0366 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 25, 2023
From: SHENZHEN JINRITOUTIAO TECHNOLOGY CO., LTD.; BEIJING ZITIAO NETWORK TECHNOLOGY CO., LTD.
To: BEIJING BYTEDANCE NETWORK TECHNOLOGY CO., LTD.
Reel/Frame 063768/0520 →
Priority Claims (1)
CN 202110518684.4 · May 12, 2021 · national
Continuity (1)
Related Publication 20240031518A1 · Jan 25, 2024
References Cited (62)
US 8405780B1 · Schaem · 2013 [cited by examiner]
US 9842420B2 · Koyama · 2017 [cited by examiner]
US 9898847B2 · Wang · 2018 [cited by examiner]
US 9948893B2 · Barzuza · 2018 [cited by examiner]
US 10567739B2 · Middleton · 2020 [cited by examiner]
US 10887531B2 · Punja et al. · 2021 [cited by applicant]
US 10999499B2 · Buford · 2021 [cited by examiner]
US 11954764B2 · Nguyen · 2024 [cited by examiner]
US 20040008773A1 · Itokawa · 2004 [cited by examiner]
US 20050013490A1 · Rinne · 2005 [cited by examiner]
US 20050175101A1 · Honda · 2005 [cited by examiner]
US 20090297061A1 · Mareachen · 2009 [cited by examiner]
US 20100014781A1 · Liu et al. · 2010 [cited by applicant]
US 20130162867A1 · Gupta · 2013 [cited by examiner]
US 20130258138A1 · Ma · 2013 [cited by examiner]
US 20140152658A1 · Ahn · 2014 [cited by examiner]
US 20140368669A1 · Talvala · 2014 [cited by examiner]
US 20160078598A1 · Tanabe · 2016 [cited by examiner]
US 20160191898A1 · Xu · 2016 [cited by examiner]
US 20160284096A1 · Buford et al. · 2016 [cited by applicant]
US 20170142371A1 · Barzuza · 2017 [cited by examiner]
US 20170154450A1 · Wang · 2017 [cited by applicant]
US 20170308990A1 · Middleton · 2017 [cited by examiner]
US 20190313071A1 · Chen · 2019 [cited by examiner]
US 20200211201A1 · Chiang · 2020 [cited by examiner]
US 20210217179A1 · Li · 2021 [cited by examiner]
US 20210312638A1 · Ito · 2021 [cited by examiner]
US 20210357675A1 · Nakamura · 2021 [cited by examiner]
US 20220038641A1 · Chang · 2022 [cited by examiner]
US 20220245941A1 · Zhu · 2022 [cited by examiner]
US 20230178072A1 · Hwang · 2023 [cited by examiner]
US 20240031518A1 · Chen · 2024 [cited by examiner]
US 20240071010A1 · Brent · 2024 [cited by examiner]
US 20240404014A1 · Hassbring · 2024 [cited by examiner]
US 20250157092A1 · Fitzpatrick · 2025 [cited by examiner]
US 20250245986A1 · Song · 2025 [cited by examiner]
US 20250272807A1 · Canet · 2025 [cited by examiner]
CN 107592490A · 2018 [cited by applicant]
CN 108154518A · 2018 [cited by applicant]
CN 110891181A · 2020 [cited by applicant]
CN 111464761A · 2020 [cited by applicant]
CN 112351291A · 2021 [cited by applicant]
CN 112601099A · 2021 [cited by applicant]
CN 112686131A · 2021 [cited by applicant]
CN 113259698A · 2021 [cited by applicant]
JP 2009098718A · 2009 [cited by applicant]
JP 2010183560A · 2010 [cited by applicant]
JP 2011041041A · 2011 [cited by applicant]
JP 2014192557A · 2014 [cited by applicant]
JP 2017212592A · 2017 [cited by applicant]
JP 7592954B2 · 2024 [cited by applicant]
TW 202514531A · 2025 [cited by examiner]
WO 2015032099A1 · 2015 [cited by applicant]
WO 2020110169A1 · 2020 [cited by applicant]
Ding Liu et al. “Real Object Registration Algorithm Based on SURF and RANSAC” Feb. 2022, IEEE (Year: 2022). [cited by examiner]
Japan Patent Office, Decision to Grant a Patent for Japanese Patent Application No. 2023-532118 dated Oct. 22, 2024, 5 pages. [cited by applicant]
Japan Patent Office, Office Action Issued in Application No. 2023532118, Jul. 2, 2024, 10 pages. [cited by applicant]
European Patent Office, Extended European Search Report Issued in Application No. 22806405.1, Jul. 22, 2024, Germany, 10 pages. [cited by applicant]
China National Intellectual Property Administration, Office Action and Search Report Issued in Application No. 202110518684.4, Jun. 1, 2022, 9 pages (submitted with English summary). [cited by applicant]
ISA China National Intellectual Property Administration, International Search Report Issued in Application No. PCT/CN2022/086428, Jun. 17, 2022, WIPO, 16 pages. [cited by applicant]
China National Intellectual Property Administration, Notice of Grant Issued in Application No. 202110518684.4, Oct. 10, 2022, 7 pages (submitted with English summary). [cited by applicant]
Peking University, “Image extension based on learning,” Wangxuan Institute of Computer Technology Graphics Laboratory, May 22, 2023, 5 pages (submitted with English summary). [cited by applicant]