Image processing method, apparatus and electronic device
Abstract
The present disclosure provides an image processing method, an apparatus and an electronic device. The method includes: determining N texture images corresponding to a first image, and a correspondence between the N texture images and N model faces of a three-dimensional model, where N is an integer greater than 1; determining, according to the correspondence and an offset coefficient, a mapping region corresponding to each model face in the N texture images, where the mapping region is at least partial region of a texture image; mapping regions in the N texture images to the three-dimensional model to obtain a three-dimensional image corresponding to the first image. A display effect of the three-dimensional image is improved and flexibility of three-dimensional image acquisition is improved.
Interactive Citation Constellation Global Citation Ranking
Interactive SVG Citation Constellation renders in Rust/WebAssembly. Prior art cited: 24 · Forward citations: 0.
Claims (8)
- Claim 1Independent Claim
An image processing method, comprising: determining N texture images corresponding to a first image, and a correspondence between the N texture images and N model faces of a three-dimensional model, wherein N is an integer greater than 1; determining, in the N texture images, a mapping region corresponding to each of the N model faces according to the correspondence and an offset coefficient, wherein the mapping region is an at least partial region of a texture image; and mapping mapping regions in the N texture images to the three-dimensional model to obtain a three-dimensional image corresponding to the first image.
- Claim 2Depends on #1
The method according to claim 1, wherein the at least partial region is a middle region of the texture image; determining, in the N texture images, the mapping region corresponding to the each of the N model faces according to the correspondence and the offset coefficient comprises: combining the N texture images into a region of L rows and K columns according to the correspondence to obtain a sampling region, wherein a product of L and K is N, and L and K are positive integers; and determining the mapping region corresponding to the each of the N model faces according to the sampling region and the offset coefficient.
- Claim 3Depends on #2
The method according to claim 2, wherein for any one of the N model faces, determining the mapping region corresponding to the each of the N model faces according to the sampling region and the offset coefficient comprises: determining a first position of the texture image corresponding to the any one of the N model faces in the sampling region; acquiring vertex texture coordinates of the any one of the N model faces; determining vertex sampling coordinates in the sampling region according to the vertex texture coordinates, the offset coefficient and the first position; and determining the mapping region corresponding to the any one of the N model faces according to the vertex sampling coordinates and the first position.
- Claim 4Depends on #3
The method according to claim 3, wherein the vertex texture coordinates comprise vertex texture abscissas and vertex texture ordinates; determining the vertex sampling coordinates in the sampling region according to the vertex texture coordinates, the offset coefficient and the first position comprises: determining abscissas of the vertex sampling coordinates according to the vertex texture abscissas, the first position, a number of columns of the sampling region and the offset coefficient; determining ordinates of the vertex sampling coordinates according to the vertex texture ordinates, the first position, the number of columns of the sampling region, a number of rows of the sampling region and the offset coefficient; and obtaining the vertex sampling coordinates according to the abscissas of the vertex sampling coordinates and the ordinates of the vertex sampling coordinates.
- Claim 5Depends on #3
The method according to claim 3, wherein a number of rows of the sampling region is 2; determining the mapping region corresponding to the any one of the N model faces according to the vertex sampling coordinates and the first position comprises: upon determining that the first position is located in a first row of the sampling region, determining the mapping region corresponding to the any one of the N model faces according to the vertex sampling coordinates; and upon determining that the first position is located in a second row of the sampling region, performing flipping processing of a preset angle on the vertex sampling coordinates to obtain target vertex sampling coordinates, and determining the mapping region corresponding to the any one of the N model faces according to the target vertex sampling coordinates.
- Claim 6Depends on #5
The method according to claim 5, wherein determining the mapping region corresponding to the any one of the N model faces according to the vertex sampling coordinates comprises: determining a first region corresponding to the vertex sampling coordinates in the sampling region; and determining the first region as the mapping region corresponding to the any one of the N model faces.
- Claim 7Depends on #5
The method according to claim 5, wherein determining the mapping region corresponding to the any one of the N model faces according to the target vertex sampling coordinates comprises: determining a second region corresponding to the target vertex sampling coordinates in the sampling region; and determining the second region as the mapping region corresponding to the any one of the N model faces.
- Claim 8Depends on #1
The method according to claim 1, before determining, in the N texture images, the mapping region corresponding to the each of the N model faces according to the correspondence and the offset coefficient, further comprising: acquiring a preset region size of edges of the N texture images; and determining the offset coefficient according to the preset region size.
Technical Overview & Description
CROSS-REFERENCE TO RELATED APPLICATION The present disclosure is a National Stage of International Application No. PCT/CN2022/123543, filed on Sep. 30, 2022, which claims priority to Chinese Patent Application No. 202210262157.6, filed to China National Intellectual Property Administration on Mar. 16, 2022 and entitled “ Image Processing Method, Apparatus and Electronic Device ” . The content of the above applications are is incorporated by reference in their entireties. TECHNICAL FIELD The present disclosure relates to the field of image processing technology and, in particular, to an image processing method, an apparatus, an electronic device, a computer-readable storage medium, a computer program product and a computer program. BACKGROUND A terminal device can make a virtual reality (Virtual Reality, VR) video by a cube-mapping (Cube-mapping) method. For example, the terminal device pastes 6 texture images corresponding to a two-dimensional image on six faces of a cube to obtain a VR image corresponding to the two-dimensional image and then obtain a virtual reality video. At present, vertex texture coordinates of each face of a model can be preset, and the model can acquire multiple regions in texture images according to the preset vertex texture coordinates and map them to the model to obtain a VR image. For example, when a cube model receives 6 texture images, the cube model can acquire target regions in the 6 texture images respectively according to preset vertex texture coordinates of each face, and then map 6 target regions to 6 faces to obtain a VR image. However, according to the above method, the regions acquired by the model in the texture images according to the preset vertex texture coordinates are fixed and unchanged, which leads to poor flexibility of VR image acquisition. SUMMARY The present disclosure provides an image processing method, an apparatus, an electronic device, a computer-readable storage medium, a computer program product and a compute
Cited By — Indexed Forward Citations (0 of 0 total)
No indexed citing patents in this generation yet. Ingest USPTO/PatentsView bulk citation tables via patents-ingest to expand the local forward citation graph.
References Cited — Backward Prior Art (24)
| Patent | Title | Year | Citations |
|---|---|---|---|
| CN 111,369,659 A | Texture mapping method, device and equipment based on three-dimensional model | — | 0 |
Non-Patent Literature (10)
- European Patent Office, Extended European Search Report Issued in Application No. 22808577.5, Jan. 2, 2024, 8 pages.
- Purnomo, B. et al.,
- “
- Seamless Texture Atlases,
- ”
- Proceedings of the Second Eurographics Symposium on Geometry Processing, Jul. 8, 2004, Nice, France, 10 pages.
- “
- CubeMap Sampling Process
- ”
- Computer Graphics, available as early as Jun. 17, 2021, 14 pages.