Virtual lens adjustment method and device, electronic equipment and storage medium

By adjusting the position of the virtual camera to place it on either side of the symmetrical plane of the field of view in the virtual scene, the problem of screen imbalance caused by virtual objects deviating from the center in 3D games is solved, thus improving the user's viewing experience.

CN115738258BActive Publication Date: 2026-05-12NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
NETEASE (HANGZHOU) NETWORK CO LTD
Filing Date
2022-11-14
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

In 3D games, when the virtual camera follows the virtual object controlled by the player to capture images, if the interactive virtual object deviates from the center, it will cause the image to be unbalanced and the user experience will be poor.

Method used

The position of the virtual camera is adjusted according to the relative distance between the first virtual object and the second virtual object, so that they are located on opposite sides of the field of view symmetry plane in the virtual scene, ensuring that the distance difference between the two objects to the field of view symmetry plane does not exceed a preset threshold.

Benefits of technology

After the position was adjusted, the virtual objects in the images captured by the virtual camera were arranged more reasonably, the balance and rationality of the image were improved, and the user experience was enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115738258B_ABST
    Figure CN115738258B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of virtual scenes, and discloses a virtual lens adjustment method and device, electronic equipment and a storage medium. The virtual lens is arranged in a virtual scene, and the virtual lens defaults to follow a first virtual object in the virtual scene to collect a picture; the method comprises the following steps: if a second virtual object that interacts with the first virtual object exists in the virtual scene, the relative distance between the first virtual object and the second virtual object is determined; the position of the virtual lens in the virtual scene is adjusted according to the relative distance, so that the first virtual object and the second virtual object are separated on two sides of a visual field symmetry plane corresponding to the virtual lens after adjustment, and the distance difference between the distance from the first virtual object to the visual field symmetry plane and the distance from the second virtual object to the visual field symmetry plane does not exceed a preset threshold value; the scheme can guarantee that the balance of the picture collected by the virtual lens is improved during the interaction between the first virtual object and the second virtual object, and the user experience is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of virtual scene technology, and more specifically, to a method, apparatus, electronic device, and storage medium for adjusting a virtual camera. Background Technology

[0002] In 3D games, the virtual camera is typically set to follow the player-controlled virtual camera to capture images. When the player-controlled virtual object interacts with other virtual objects in the game, the virtual camera also follows the player-controlled virtual object to capture its image. In this scenario, although the player-controlled virtual object may be located near the center axis of the screen, other virtual objects interacting with it may be offset to the left or right. This results in an overall unbalanced image and a poor user experience. Summary of the Invention

[0003] In view of the above problems, this application proposes a method, device, electronic device and storage medium for adjusting a virtual camera, so as to solve the problem of unbalanced images captured by the virtual camera in a virtual scene and poor user experience.

[0004] According to one aspect of the embodiments of this application, a method for adjusting a virtual camera is provided. The virtual camera is located in a virtual scene, and by default, the virtual camera follows a first virtual object in the virtual scene to capture images. The method includes: if there is a second virtual object in the virtual scene that interacts with the first virtual object, determining the relative distance between the first virtual object and the second virtual object; adjusting the position of the virtual camera in the virtual scene according to the relative distance, so that after adjustment, the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual camera, and the distance difference between the distance from the first virtual object to the field of view symmetry plane and the distance from the second virtual object to the field of view symmetry plane does not exceed a preset threshold.

[0005] According to one aspect of the embodiments of this application, a virtual camera adjustment device is provided. The virtual camera is disposed in a virtual scene, and the virtual camera defaults to following a first virtual object in the virtual scene for image capture. The device includes: a determining module, configured to determine the relative distance between the first virtual object and the second virtual object if there is a second virtual object in the virtual scene that interacts with the first virtual object; and an adjusting module, configured to adjust the position of the virtual camera in the virtual scene according to the relative distance, so that after adjustment, the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual camera, and the distance difference between the distance from the first virtual object to the field of view symmetry plane and the distance from the second virtual object to the field of view symmetry plane does not exceed a preset threshold.

[0006] According to one aspect of the embodiments of this application, an electronic device is provided, including: a processor; and a memory storing computer-readable instructions, which, when executed by the processor, implement the virtual camera adjustment method described above.

[0007] According to one aspect of the embodiments of this application, a computer-readable storage medium is provided, on which computer-readable instructions are stored, which, when executed by a processor, implement the virtual camera adjustment method as described above.

[0008] According to one aspect of the embodiments of this application, a computer program product is provided, including computer instructions that, when executed by a processor, implement the virtual camera adjustment method described above.

[0009] In the solution of this application, when a second virtual object interacts with the first virtual object in the virtual scene, the position of the virtual camera that originally followed the first virtual object is adjusted according to the relative distance between the first and second virtual objects. This adjustment places the first and second virtual objects on opposite sides of the symmetrical plane of the adjusted virtual camera's field of view, with the difference between the distances from the first and second virtual objects to this plane not exceeding a preset threshold. Thus, in the image captured by the adjusted virtual camera, the first and second virtual objects are positioned on opposite sides of the central axis of the image, and the difference between their distances is small. Therefore, the arrangement of the first and second virtual objects in the image captured by the adjusted virtual camera is more reasonable, ensuring overall image balance and rationality, providing better composition during interaction, and effectively improving the user's viewing experience. Attached Figure Description

[0010] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application. It is obvious that the drawings described below are merely some embodiments of this application, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort.

[0011] Figure 1 This diagram illustrates how a virtual camera captures images during the interaction between a player-controlled virtual object and an NPC, as described in the relevant technology.

[0012] Figure 2This is a flowchart illustrating a method for adjusting a virtual camera according to an embodiment of this application.

[0013] Figure 3 yes Figure 2 Step 220 in one embodiment is shown in a flowchart.

[0014] Figure 4 This is a schematic diagram illustrating the virtual camera's viewfinder position adjustment according to one embodiment.

[0015] Figure 5 An example shows the following according to Figure 3 A schematic diagram of a corresponding embodiment where the virtual camera is positioned in the first central position for image capture.

[0016] Figure 6 An example shows the following according to Figure 3 A schematic diagram of a corresponding embodiment where the virtual camera is positioned at the first target location to capture images.

[0017] Figure 7 yes Figure 2 The flowchart of step 220 in the corresponding embodiment is shown in another embodiment.

[0018] Figure 8 This is a schematic diagram showing the distribution of the first and second view planes within the field of view corresponding to the virtual lens, according to an embodiment of this application.

[0019] Figure 9 This is a schematic diagram illustrating the virtual camera's viewfinder position adjustment according to another embodiment.

[0020] Figure 10 An example shows the following according to Figure 7 A schematic diagram of the corresponding embodiment where the virtual camera is positioned in the second middle position for image capture.

[0021] Figure 11 An example shows the following according to Figure 7 A schematic diagram of a corresponding embodiment where the virtual camera is positioned at the second target location to capture images.

[0022] Figure 12 yes Figure 2 The flowchart of step 220 in the corresponding embodiment is shown in another embodiment.

[0023] Figure 13 This is a schematic diagram illustrating the virtual camera's viewfinder position adjustment according to another embodiment.

[0024] Figure 14 An example shows the following according to Figure 12 A schematic diagram of the corresponding embodiment where the virtual camera is located in the fourth middle position for image capture.

[0025] Figure 15 An example is shown in Figure 14 A schematic diagram showing the distribution of the second and third view planes corresponding to the virtual camera in a virtual scene.

[0026] Figure 16 An example shows the following according to Figure 12 A schematic diagram of the corresponding embodiment where the virtual camera is positioned in the middle of the fifth position to capture images.

[0027] Figure 17 An example shows the following according to Figure 12 A schematic diagram of a corresponding embodiment where the virtual camera is positioned at a third target location to capture images.

[0028] Figure 18 This is a block diagram of a virtual camera adjustment device according to an embodiment of this application.

[0029] Figure 19 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Detailed Implementation

[0030] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided to make this application more comprehensive and complete, and to fully convey the concept of the exemplary embodiments to those skilled in the art.

[0031] Furthermore, the described features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. Numerous specific details are provided in the following description to give a thorough understanding of embodiments of this application. However, those skilled in the art will recognize that the technical solutions of this application can be practiced without one or more of the specific details, or other methods, components, apparatuses, steps, etc., can be employed. In other instances, well-known methods, apparatuses, implementations, or operations are not shown or described in detail to avoid obscuring various aspects of this application.

[0032] The block diagrams shown in the accompanying drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities can be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.

[0033] The flowcharts shown in the accompanying drawings are merely illustrative and do not necessarily include all content and operations / steps, nor do they necessarily have to be performed in the described order. For example, some operations / steps can be broken down, while others can be combined or partially combined; therefore, the actual execution order may change depending on the specific circumstances.

[0034] It should be noted that "multiple" in this article refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone. The character " / " generally indicates that the preceding and following related objects have an "or" relationship.

[0035] In related technologies, in a 3D game scene, during the interaction between a virtual object controlled by the player and a virtual object that is a non-player character (NPC), the virtual camera in the game follows the virtual object controlled by the player to capture the image.

[0036] Figure 1 This diagram illustrates the image capture process of a virtual camera during the interaction between a first virtual object controlled by a player and a second virtual object representing an NPC, as described in the relevant technology. Figure 1 In diagram A, an interaction response area 130 is shown where a first virtual object 110, controlled by the player, interacts with a second virtual object 120, representing an NPC. Here, R1 is the radius of the interaction response area 130, and r is the relative distance between the first virtual object 110 and the second virtual object 120. Figure 1 In A, the first virtual object 110 is located at the center of the field of view of the virtual lens 140, and the corresponding fan-shaped area formed with the virtual lens as the center is the field of view area 150 of the virtual lens.

[0037] When the virtual camera 140 is in Figure 1 The scene image captured in the virtual scene at position A is shown in the image. Figure 1 As shown in Figure B, although the first virtual object 110 is located near the central axis of the screen, the second virtual object 120 is located slightly to the right of the scene. This indicates a certain degree of imbalance in the screen layout, which negatively impacts the user experience. To address this issue, the solution proposed in this application is presented.

[0038] The implementation details of the technical solutions in the embodiments of this application are described in detail below:

[0039] Figure 2This is a flowchart illustrating a virtual camera adjustment method according to an embodiment of this application. This method can be executed by an electronic device with processing capabilities, such as a terminal. The terminal can be a smartphone, tablet, laptop, desktop computer, smart TV, etc., and is not specifically limited thereto. In the scheme of this application, the virtual camera is located in a virtual scene, and the virtual camera defaults to following a first virtual object in the virtual scene for image capture. (Refer to...) Figure 2 As shown, the method includes at least steps 210 to 220, which are described in detail below:

[0040] Step 210: If there is a second virtual object in the virtual scene that interacts with the first virtual object, determine the relative distance between the first virtual object and the second virtual object.

[0041] The virtual scene can be a scene constructed in a game, and it can be a three-dimensional virtual scene. In this application, for ease of distinction, the virtual object that the virtual camera follows by default is referred to as the first virtual object; the virtual object in the virtual scene that can interact with the first virtual object is referred to as the second virtual object. The virtual object can be a virtual character, an anime character, a virtual animal, etc.

[0042] In some embodiments, the first virtual object may be a virtual object that can be manipulated by a player to represent a player character, and the first virtual object may be manipulated to perform activities such as walking, jumping, crawling, etc. The second virtual object may be a virtual object that is set up in a virtual scene to interact as a non-player character (NPC).

[0043] A virtual lens, also known as a virtual camera or virtual video camera, is used to capture images within a virtual scene. In this application, the virtual lens defaults to following the first virtual object for image capture; that is, by default, the virtual lens is positioned so that the first virtual object is centered in the field of view. Conversely, if the virtual scene does not include a second virtual object, the virtual lens follows the first virtual object for image capture.

[0044] When a second virtual object interacts with the first virtual object in a virtual scene, if the image is still captured in the way that the first virtual object is located in the center of the virtual object's field of vision, the captured image will be such that although the first virtual object is located near the central axis of the image, the second virtual object may be located to the left or right of the image. This will result in an unbalanced image and a poor user experience.

[0045] Therefore, in the solution of this application, if a second virtual object that interacts with the first virtual object appears in the virtual scene, in order to ensure the balance of the image seen by the user and improve the user's viewing experience, the position of the virtual camera is dynamically adjusted through the process of steps 210-220.

[0046] In a specific embodiment, the relative distance between the first virtual object and the second virtual object can be calculated based on the position information of the first virtual object and the second virtual object in the virtual scene.

[0047] Step 220: Adjust the position of the virtual camera in the virtual scene according to the relative distance, so that the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual camera, and the distance difference between the distance of the first virtual object to the field of view symmetry plane and the distance of the second virtual object to the field of view symmetry plane does not exceed a preset threshold.

[0048] The symmetry plane of the virtual lens's field of view refers to a symmetrical plane that divides the virtual field of view into two symmetrical parts. This means that the central axis of the virtual lens lies within the symmetry plane of its corresponding field of view, and this symmetry plane is perpendicular to the imaging plane of the virtual lens. Figure 1 In diagram A, the dotted line representing the player character indicates the plane of symmetry of the virtual camera's view from a top-down perspective. It's worth noting that the position of this plane of symmetry changes depending on the virtual camera's position.

[0049] If the virtual scene is a three-dimensional scene, and the first virtual object and the second virtual object are three-dimensional models occupying a certain three-dimensional space, in this case, the distance from a point or a line (such as the center point, central axis, etc.) on the first virtual object to the view symmetry plane can be used as the distance between the first virtual object and the view symmetry plane; similarly, the distance from a point or a line on the second virtual object to the view symmetry plane corresponding to the virtual camera can be used as the distance between the second virtual object and the view symmetry plane.

[0050] In some embodiments, the distance from the central axis of the first virtual object to the view symmetry plane can be used as the distance from the first virtual object to the view symmetry plane, and correspondingly, the distance from the central axis of the second virtual object to the view symmetry plane can be used as the distance from the second virtual object to the view symmetry plane.

[0051] In other embodiments, the distance from an edge line on the first virtual object to the view symmetry plane can also be used as the distance from the first virtual object to the view symmetry plane, and correspondingly, the distance from an edge line on the second virtual object to the view symmetry plane can be used as the distance from the second virtual object to the view symmetry plane.

[0052] The preset threshold can be set according to actual needs and is not specifically limited here. Of course, a smaller preset threshold indicates that, after adjusting the position of the virtual camera, the difference between the distance from the first virtual object to the corresponding field of view symmetry plane of the virtual camera and the distance from the second virtual object to the corresponding field of view symmetry plane of the virtual camera is smaller. In a specific embodiment, the distance from the first virtual object to the corresponding field of view symmetry plane of the virtual camera can be set to be equal to the distance from the second virtual object to the corresponding field of view symmetry plane of the virtual camera after adjustment.

[0053] The projection of the virtual lens's field of view symmetry plane onto the virtual lens's imaging plane is the central axis of the image. Since the first and second virtual objects are located on opposite sides of the virtual lens's corresponding field of view symmetry plane after adjustment, and the distance difference between the first and second virtual objects from the field of view symmetry plane does not exceed a preset threshold, in the image captured by the adjusted virtual lens, the areas where the first and second virtual objects are located are located on opposite sides of the central axis of the image. Moreover, the distance from the area where the first virtual object is located to the central axis of the image is not significantly different from the distance from the area where the second virtual object is located to the central axis of the image.

[0054] In some embodiments, after step 220, the method further includes: displaying the image captured by the adjusted virtual camera.

[0055] In the solution of this application, when there is a second virtual object interacting with the first virtual object in the virtual scene, the position of the virtual camera that originally followed the first virtual object is adjusted according to the relative distance between the first and second virtual objects. This adjusts the position of the first virtual object so that it is no longer located at the center of the field of view of the adjusted virtual camera, but rather the first and second virtual objects are located on opposite sides of the symmetrical plane of the field of view corresponding to the adjusted virtual camera. The difference between the distance of the first virtual object to the symmetrical plane of the field of view corresponding to the adjusted virtual camera and the distance of the second virtual object to the symmetrical plane of the field of view corresponding to the adjusted virtual camera does not exceed a preset threshold. Thus, in the image captured by the virtual camera after the position adjustment, the first and second virtual objects are located on opposite sides of the central axis of the image, and the difference between the distance of the first virtual object to the central axis of the image and the distance of the second virtual object to the central axis of the image is small. Compared to the layout of player characters near the central axis of the screen and NPCs slightly to the left or right in the images captured by related technologies, the positions of the first and second virtual objects are more reasonable in the images captured by the virtual camera after position adjustment. This ensures the overall balance and rationality of the image, provides better composition during interaction, and effectively improves the user's viewing experience.

[0056] In a specific embodiment, the adjustment method for the position of the virtual camera at different relative distances can be preset, and then the position of the virtual camera can be adjusted according to the adjustment method corresponding to the relative distance.

[0057] When the relative distance between the first and second virtual objects is large, there may be a significant difference between the distance from the first virtual object to the virtual lens and the distance from the second virtual object to the virtual lens. For the virtual lens, the farther away an object is, the smaller its image appears on the lens's imaging plane. Therefore, if the relative distance between the first and second virtual objects is large, there may be an image imbalance due to a significant difference in the size of the images of the first and second virtual objects in the captured image. To address this, a first reference distance can be preset. If the relative distance between the first and second virtual objects is not less than the first reference distance, then... Figure 3 The process shown is used to adjust the position of the virtual camera.

[0058] It is understandable that, since the first virtual object and the second virtual object interact in a preset interaction area, the projection of this interaction area from a top-down perspective is a circular area with the center of the first virtual object as the center and a radius of R1, and the relative distance is less than R1.

[0059] like Figure 3 As shown, when the relative distance is not less than the first reference distance, the position is adjusted according to the following steps 310-330, which are detailed below:

[0060] Step 310: Based on the position information of the first virtual object and the current position information of the virtual camera, determine the first translation information. The first translation information is used to indicate that the virtual camera is translated from the current position to the first intermediate position so that the central axis of the first virtual object is located in the first view plane within the field of view corresponding to the virtual camera.

[0061] That is, when the virtual camera is located in the first intermediate position, the central axis of the first virtual object is located in the first view plane within the field of view corresponding to the virtual camera. The first view plane is located between the field of view symmetry plane and the field of view boundary plane of the virtual camera.

[0062] In this application, for ease of distinction, the intermediate position to which the virtual camera is translated, as indicated by the first translation information, is referred to as the first intermediate position. The first translation information is used at least to indicate the translation direction and translation distance for translating the virtual camera from its current position to the first intermediate position.

[0063] The field of view boundary plane of a virtual camera refers to the plane located at the boundary of the virtual camera's field of view area. The angle between the two field of view boundary planes of a virtual camera is the corresponding angle of view. For example, in... Figure 1 In the diagram, point O represents the location of the center point of the virtual lens, and OP1 and OP2 are the projections of the virtual lens's field of view boundary plane into the top view. Since the first-view plane lies between the virtual lens's field of view symmetry plane and the virtual lens's field of view boundary plane, OP3 is the projection of the virtual lens's corresponding field of view symmetry plane into the top view. Correspondingly, the projection of the first-view plane into the top view also lies within the sector area governed by OP1 and OP3, or within the sector area governed by OP3 and OP5.

[0064] exist Figure 1 In the diagram, OP2 and OP4 are the dividing lines of the trisection of ∠P1OP5. Correspondingly, OP2 and OP4 can also be the trisection view plane 160 corresponding to the virtual lens. In a specific embodiment, it can be... Figure 1 In diagram A, the left-hand trisection of the view plane 160 is used as the first view plane. It is worth mentioning that if the position of the virtual camera changes, the position of the first view plane in the corresponding field of view of the virtual camera changes accordingly; however, the relative position of the first view plane with respect to the virtual camera remains unchanged.

[0065] In some embodiments, the first translation information may be an instruction to translate the virtual lens from its current position to a first intermediate position along a direction perpendicular to the central axis of the virtual lens.

[0066] Step 320: Based on the position information of the first virtual object and the first intermediate position, determine the first rotation information. The first rotation information is used to indicate that the virtual camera is rotated from the first intermediate position to the first target position with the central axis of the first virtual object as the rotation center.

[0067] The target position to which the virtual camera is rotated, as indicated by the first rotation information, is called the first target position. The first rotation information at least indicates the direction and angle of rotation of the virtual camera. Therefore, the first target position can be determined based on the first rotation information, the position information of the first virtual object, and the first intermediate position. Rotating the virtual camera changes its field of view, thus providing different viewing angles for observing the virtual scene. It is understood that when the virtual camera is rotated, its central axis rotates accordingly, meaning the placement direction of the virtual camera changes. Therefore, the first rotation information can also be used to indicate the placement direction of the virtual camera when it is located at the first target position.

[0068] It is worth mentioning that when the virtual camera is located at the first target position, the first virtual object is also located on the first view plane within the field of view of the virtual camera.

[0069] Step 330: Based on the first translation information and the first rotation information, control the virtual camera to move to the first target position, where the first target position is the adjusted position of the virtual camera.

[0070] Based on the first translation information and the second rotation information, the coordinates of the first target position and the placement direction of the virtual lens at the first target position can be determined accordingly. Thus, the placement state of the virtual lens at the first target position can be determined accordingly. Correspondingly, the electronic device can control the virtual lens to move to the first target position and set the virtual lens according to the corresponding placement state.

[0071] The first target position is used as the position of the adjusted virtual camera. Correspondingly, when the virtual camera is located at the first target position, the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual camera. Furthermore, the distance difference between the distance of the first virtual object to the field of view symmetry plane corresponding to the virtual camera and the distance of the second virtual object to the field of view symmetry plane corresponding to the virtual camera is less than a preset threshold.

[0072] In some embodiments, when the virtual camera is located at the first target position, the distance from the first virtual object to the field of view symmetry plane corresponding to the virtual camera is equal to the distance from the second virtual object to the field of view symmetry plane corresponding to the virtual camera.

[0073] In some embodiments, since the volume difference between the models corresponding to the first virtual object and the second virtual object may be large, in order to maintain a certain distance between the first virtual object and the second virtual object in the image captured by the adjusted virtual lens, the distance from the first edge of the first virtual object to the view symmetry plane can be used as the distance from the first virtual object to the view symmetry plane, and the distance from the second edge of the second virtual object to the view symmetry plane can be used as the distance from the second virtual object to the view symmetry plane. The first edge is the edge of the first virtual object closer to the second virtual object, and the second edge is the edge of the second virtual object closer to the first virtual object.

[0074] Assuming the fourth view plane is defined as the view plane symmetrically distributed with respect to the view symmetry plane in the field of view corresponding to the virtual lens, then the distance from the first view plane to the view symmetry plane is equal to the distance from the fourth view plane to the view symmetry plane. In this embodiment, when the virtual lens is located at the first target position, the central axis of the first virtual object is located in the first view plane, and the difference between the distance from the first virtual object to the view symmetry plane and the distance from the second virtual object to the view symmetry plane is less than a preset threshold, indicating that when the virtual lens is located at the first target position, the second virtual object is located near the fourth view plane. The projections of the first and second view planes onto the imaging plane of the virtual lens are symmetrically distributed. Therefore, in the image captured by the virtual lens located at the first target position, the difference between the distance from the area where the first virtual object is located to the central axis of the image and the distance from the area where the second virtual object is located to the central axis of the image is small, resulting in a more balanced layout of the first and second virtual objects in the captured image.

[0075] Since viewers' eyes naturally fall on the 1 / 3 mark of the image, placing the main subject at this point aligns better with user aesthetics and enhances the viewing experience. Therefore, in some embodiments, the first perspective plane is a third-divided perspective plane obtained by dividing the virtual camera's viewpoint into thirds, and the corresponding fourth perspective plane is another third-divided perspective plane corresponding to the virtual camera. Consequently, in the image captured by the adjusted virtual camera, the first virtual object is located at the 1 / 3 mark of the image, and the second virtual object is located near the other side of the 1 / 3 mark. This layout in the captured image better suits the user's aesthetic preferences and improves the viewing experience.

[0076] In some embodiments, the first reference distance is equal to the product of the first coefficient and the first distance, wherein the first coefficient ∈ (0, 1), and the first distance is equal to the maximum distance between the first view plane and the fourth view plane within the field of view of the virtual lens; the fourth view plane and the first view plane are symmetrically distributed with respect to the field of view symmetry.

[0077] For example, if the first-view plane and the fourth-view plane are each a third-divided view plane within the field of view of the virtual camera, please refer to... Figure 1 Since the fan-shaped area under the jurisdiction of P1OP5 is the field of view of the virtual camera, if the three-part view plane represented by OP2 is taken as the first view plane and the three-part view plane represented by OP4 is taken as the second view plane, then the maximum distance between the first view plane and the fourth view plane is equal to the distance between point P2 and point P4.

[0078] In one specific embodiment, the first coefficient is equal to 1 / 3. In this case, please refer to [link to relevant documentation]. Figure 1Assume Q1 is the closest trisection point to point O on OP2, and Q2 is the closest trisection point to point O on OP4. Since the first coefficient is equal to 1 / 3, the first reference distance is equal to the distance between point Q1 and point Q2; correspondingly, the first distance is equal to the distance between point P2 and point P4.

[0079] Figure 4 An exemplary diagram illustrates the virtual camera capturing images before position adjustment. Figure 4 The left image shows a schematic diagram of the positions of the virtual camera, the first virtual object, and the second virtual object from a top-down view before the virtual camera position was adjusted. Figure 4 The left side shows the trisectioned view plane 160 within the field of view corresponding to the virtual lens. At this time, the first virtual object 110 is located at the center of the field of view of the virtual lens 140. The relative distance between the first virtual object 110 and the second virtual object 120 is relatively large. Therefore, the first reference distance ≤ relative distance < R1. If the image is captured using the virtual lens in its default position, the captured image will be as follows... Figure 4 As shown in the right figure.

[0080] Figure 4 In the right-hand diagram, dashed line I represents the dividing line of the image into thirds, which can also be understood as the projection of the 160° angle plane corresponding to the third division of the virtual lens onto the imaging plane. Dashed line II represents the dividing line of the image into two equal parts, which can also be understood as the central axis of the image. Figure 4 As can be seen in the middle right image, although the first virtual object 110 is located in the center of the image, the second virtual object 120 is located in a position slightly to the right of the image, resulting in an overall imbalance in the image. Moreover, since the second virtual object is farther away from the virtual camera and the first virtual object is closer to the virtual camera, the size difference between the first and second virtual objects is significant in the captured image, making the image even more unbalanced.

[0081] against Figure 4 The virtual scene corresponding to the left image can be arranged according to... Figure 3 The illustrated embodiment adjusts the position of the virtual camera. Figures 5-6 An example shows the following according to Figure 3 The diagram illustrates how the virtual camera position is adjusted.

[0082] Figure 5 The middle left figure shows the... Figure 4 The diagram shows the virtual camera moving to the first intermediate position indicated by the first translation information. At this time, the central axis of the first virtual object is located on the third-order viewing plane 160 to the left of the virtual camera. Figure 5 The image captured by the virtual camera 140 in the first central position is as follows: Figure 5As shown in the right-middle figure, it can be seen that the first virtual object 110 is located at 1 / 3 of the screen, but the size difference between the first virtual object 110 and the second virtual object 120 is still significant. In this embodiment, a third-divided view plane 160 within the field of view corresponding to the virtual object is used as the first view plane.

[0083] Figure 6 The middle left figure shows the... Figure 5 The diagram shows the virtual camera rotating to the first target position. After rotation, the central axis of the first virtual object 110 is located on a three-part view plane 160 of the virtual camera. At this time, the central axis of the second virtual object 120 is located near another three-part view plane of the virtual camera.

[0084] In this embodiment, due to the significant difference in size between the 3D models corresponding to the first and second virtual objects, to avoid the visual effect being affected by a small distance between them in the image, the distance from the first edge (i.e., the right edge) of the first virtual object to the viewpoint interface corresponding to the virtual camera is used as the distance from the first virtual object to the viewpoint interface corresponding to the virtual camera. Similarly, the distance from the second edge (i.e., the left edge) of the second virtual object to the viewpoint interface corresponding to the virtual camera is used as the distance from the second virtual object to the viewpoint interface corresponding to the virtual camera. Figure 6 In the left-hand image, when the virtual camera rotates to the first target position indicated by the first rotation information, the distance from the first edge of the first virtual object to the field of view interface corresponding to the virtual camera is equal to the distance from the second edge of the second virtual object to the field of view interface corresponding to the virtual camera.

[0085] based on Figure 6 The image captured by the virtual camera 140 in the left image can be like... Figure 6 As shown in the right figure, Figure 6 The image shows the projection point (point M1) of the first edge on the first virtual object 110 onto the imaging plane and the projection point (point M2) of the second edge on the second virtual object onto the imaging plane. Correspondingly, the distance from point M1 to the central axis of the image (i.e., the dashed line II) is equal to the distance from point M2 to the dashed line II.

[0086] contrast Figure 4 The right image in the middle, Figure 5 The right image in the middle and Figure 6 As can be seen in the right figure, according to Figure 3After adjusting the position of the virtual camera in the corresponding embodiment, the layout of the first and second virtual objects in the captured image is more reasonable. This avoids image imbalance caused by unreasonable positions of the first and second virtual objects in the image, as well as image imbalance caused by differences in body size between the first and second virtual objects. This ensures the quality of the captured image and improves the user's viewing experience.

[0087] When the relative distance between the first and second virtual objects is small, if the image is captured according to the default position of the virtual camera, in addition to the image imbalance described above, there may also be a significant overlap between the first and second virtual objects in the captured image, resulting in a poor viewing experience for the user. When the relative distance is less than the first reference distance, it can be adjusted according to... Figure 7 and Figure 12 The corresponding implementation uses a method to adjust the position of the virtual camera.

[0088] In some embodiments, a second reference distance can also be set, wherein the second reference distance is less than the first reference distance, and in the case where the second reference distance ≤ relative distance < first reference distance, according to Figure 7 The corresponding implementation adjusts the position of the virtual camera; if the relative distance is less than the second reference distance, then... Figure 12 The corresponding implementation uses a method to adjust the position of the virtual camera.

[0089] In other embodiments of this application, if the second reference distance ≤ relative distance < first reference distance, such as Figure 7 As shown, step 220 includes:

[0090] Step 710: Based on the position information of the first virtual object and the current position information of the virtual camera, determine the second translation information. The second translation information is used to indicate that the virtual camera is translated from the current position to the second intermediate position so that the central axis of the first virtual object is located in the first viewing plane within the field of view corresponding to the virtual camera.

[0091] The intermediate position to which the virtual camera is translated, as indicated by the second translation information, is called the second intermediate position. The second translation information is used to indicate at least the translation direction and translation distance for translating the virtual camera from its current position to the second intermediate position.

[0092] The first-view plane is located between the virtual lens's field of view symmetry plane and the virtual lens's field of view boundary plane. It can be selected as needed and is not specifically limited here. For example, a three-part view plane within the virtual lens's field of view can be used as the first-view plane.

[0093] It is understandable that when the virtual camera is located in the second middle position, the central axis of the first virtual object is located in the first view plane within the field of view corresponding to the virtual camera.

[0094] In a specific embodiment, the third translation information may be an instruction to translate the virtual lens from its current position to a second intermediate position along the direction of the central axis of the virtual lens.

[0095] Step 720: Based on the position information of the second intermediate position and the first virtual object, determine the third translation information. The third translation information is used to indicate that the virtual camera is translated from the second intermediate position to the third intermediate position in a direction closer to the first virtual object.

[0096] The intermediate position to which the virtual camera is translated, as indicated by the third translation information, is called the third intermediate position. The second translation information is used at least to indicate the translation direction and translation distance for translating the virtual camera from the second intermediate position to the third intermediate position.

[0097] In a specific embodiment, the translation based on the third translation information can be a translation along the central axis of the virtual camera at the second intermediate position, moving closer to the first virtual object. This ensures that the central axis of the virtual camera remains unchanged at both the second and third intermediate positions. Moving the virtual camera from the second intermediate position to the third intermediate position is equivalent to pulling the virtual camera closer to the first virtual object.

[0098] In some embodiments, a first condition can be preset, wherein the first condition is used to indicate that when the virtual camera is located in the third intermediate position, the distance from the first virtual object to the virtual camera is not less than the target distance, so that the translation distance can be determined according to the distance threshold defined by the first condition and the position information of the first virtual object and the second intermediate position.

[0099] In some implementations, a specified distance can be pre-set between the first virtual object and the virtual camera when the virtual camera is in the third intermediate position, and the translation distance from the second intermediate position to the third intermediate position can be determined according to the specified distance.

[0100] Step 730: Based on the position information of the first virtual object and the third intermediate position, determine the second rotation information. The second rotation information is used to indicate that the virtual camera is rotated from the third intermediate position to the second target position with the central axis of the first virtual object as the rotation center.

[0101] The target position to which the virtual camera is rotated, as indicated by the second rotation information, is called the second target position. The second rotation information indicates at least the direction and angle of rotation of the virtual camera. Similarly, since the placement orientation of the virtual camera changes accordingly after rotation, the second rotation information also indicates the placement orientation of the virtual camera at the second target position.

[0102] Step 740: Based on the second translation information, the third translation information, and the second rotation information, control the virtual camera to move to the second target position, which is the adjusted position of the virtual camera.

[0103] Using the second target position as the adjusted virtual camera position, correspondingly, when the virtual camera is located at the second target position, the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual camera, and the distance difference between the first virtual object and the second virtual object is less than a preset threshold. Similarly, in a specific embodiment, when the virtual camera is located at the second target position, the distance between the first virtual object and the second virtual object can be equal.

[0104] Similarly, the distance from the central axis of the first virtual object to the symmetry plane of the virtual lens's field of view can be taken as the distance from the first virtual object to the symmetry plane of the virtual lens's field of view. Correspondingly, the distance from the central axis of the second virtual object to the symmetry plane of the virtual lens's field of view can be taken as the distance from the second virtual object to the symmetry plane of the virtual lens's field of view.

[0105] Similarly, the distance from the first edge of the first virtual object to the view symmetry plane can be taken as the distance from the first virtual object to the view symmetry plane, and the distance from the second edge of the second virtual object to the view symmetry plane can be taken as the distance from the second virtual object to the view symmetry plane.

[0106] Through the above embodiments, it can be ensured that when the virtual camera is located at the second target position, in the image captured by the virtual camera, the first virtual object and the second virtual object are located on opposite sides of the central axis of the image, and the difference between the distances from the area where the first virtual object is located to the central axis of the image and the distances from the area where the second virtual object is located to the central axis of the image is small. Furthermore, since the virtual camera can be zoomed in towards the first virtual object based on the third translation information, the areas where the first and second virtual objects are located occupy a higher proportion of the image, while the proportions of other areas occupying the image are reduced, resulting in a more balanced image layout.

[0107] In some embodiments, the second reference distance is equal to the distance between the third and fourth intersection lines. The third intersection line is the intersection line between the second reference plane and the first view plane. The fourth intersection line is the intersection line between the second reference plane and the fourth view plane within the field of view of the virtual lens. The fourth view plane and the first view plane are symmetrically distributed with respect to the field of view. The second reference plane is a plane that is perpendicular to the central axis of the virtual lens and whose distance from the virtual lens is the target distance.

[0108] For example, such as Figure 8 As shown, the first view plane is represented by the trisection of the view plane OP2 within the field of view corresponding to the virtual lens, and the fourth view plane is represented by the trisection of the view plane OP4. OP3 is the central axis of the virtual lens. Assuming the distance from point Q3 on OP3 to the virtual lens is the target distance (assuming the target distance is S2), line segment Q4Q5 passes through point Q3 and is perpendicular to OP3. Point Q4 is located on OP2, and point Q5 is located on OP4. Then Q4Q5 is the projection of the second reference plane onto the top view plane. Furthermore, Q4 is the projection of the third intersection line onto the top view plane, and Q5 is the projection of the fifth intersection line onto the top view plane. Therefore, the second reference distance is the length of line segment Q4Q5.

[0109] In a specific embodiment, the target distance can be preset, and the target distance can be the minimum distance between the defined first virtual object and the virtual camera.

[0110] Figure 9 The left image shows a schematic diagram of the positions of the first virtual object, the second virtual object, and the virtual camera before adjustment. Figure 9 In the left image, the second reference distance ≤ relative distance < first reference distance. In this case, the distance between the first virtual object 110 and the second virtual object 120 is relatively close. If the image is captured using a virtual camera in its default position, the captured image will look like... Figure 9 As shown in the right figure. Figure 9 As can be seen in the right image, there is an overlapping area between the first virtual object 110 and the second virtual object 120 in the captured image.

[0111] against Figure 9 The left image can be followed as follows Figure 7 The corresponding embodiment adjusts the position of the virtual camera. Figures 10-11 An example shows the following according to Figure 7 The diagram illustrates how the virtual camera position is adjusted. Figures 10-11 In the corresponding embodiment, a three-part view plane 160 corresponding to the virtual lens is used as the first view plane.

[0112] Figure 10 The middle left figure shows the... Figure 9 The diagram shows the virtual camera moving to the second intermediate position indicated by the second translation information. At this time, the central axis of the first virtual object 110 is located on the tri-division view plane 160 to the left of the virtual camera. Figure 10 The image captured by the virtual camera in the second middle position is as follows: Figure 10 As shown in the middle right figure, it can be seen that the first virtual object 110 is located at 1 / 3 of the screen. However, due to the close distance between the first virtual object and the second virtual object in the virtual scene, the first virtual object 110 and the second virtual object 120 are located on the left side of the screen. Moreover, there is an area in the screen where the first virtual object and the second virtual object overlap.

[0113] Next, according to the third translation information, the virtual camera is first translated from the second intermediate position to the third intermediate position, and then according to the second rotation information, the virtual camera is rotated from the third intermediate position to the second target position. Figure 11 The left-middle image shows a schematic diagram of the virtual camera being rotated to the position of the second target. Figure 11 As can be seen in the left image, on the one hand, the distance between the virtual camera and the first virtual object 110 and the second virtual object 120 is reduced (i.e., translated according to the third translation information); on the other hand, compared to... Figure 10 The virtual camera in the left image has been rotated.

[0114] based on Figure 11 The image on the left shows the scene captured by the virtual camera. Figure 11 As shown in the right figure, in the captured image, because the virtual camera was zoomed in based on the third translation information, only a portion of the models of the first virtual object 110 and the second virtual object 120 are presented in the image captured by the virtual camera located at the second target position. Moreover, in this image, the central axis of the first virtual object 110 is located at the left 1 / 3 of the image, and the central axis of the second virtual object 120 is located near the right 1 / 3 of the image.

[0115] In this embodiment, the distance from the first edge (i.e., the right edge) of the first virtual object to the field of view interface corresponding to the virtual lens is taken as the distance from the first virtual object to the field of view interface corresponding to the virtual lens, and the distance from the second edge (i.e., the left edge) of the second virtual object to the field of view interface corresponding to the virtual lens is taken as the distance from the second virtual object to the field of view interface corresponding to the virtual lens. When the virtual lens is located at the second target position, the distance from the first edge (i.e., the right edge) of the first virtual object to the field of view interface corresponding to the virtual lens is equal to the distance from the second edge (i.e., the left edge) of the second virtual object to the field of view interface corresponding to the virtual lens.

[0116] Figure 11 The right-middle figure shows the projection point (point M3) of the first edge on the first virtual object onto the imaging plane and the projection point (point M4) of the second edge on the second virtual object onto the imaging plane. Correspondingly, the distance from point M3 to the dashed line II is equal to the distance from point M4 to the dashed line II.

[0117] contrast Figure 9 The right image in the middle, Figure 10 The right image in the middle and Figure 11 As can be seen in the right figure, according to Figure 3 After adjusting the position of the virtual camera in the corresponding embodiment, the first virtual object and the second virtual object in the captured image are distributed in the left 1 / 3 and the right 1 / 3 of the image, respectively. The image layout is more reasonable. Moreover, because the virtual camera is brought closer, the area where the first virtual object and the second virtual object are located in the image occupies a larger proportion of the image, thereby improving the balance of the image and thus improving the user's viewing experience.

[0118] In some embodiments of this application, if the relative distance is less than the second reference distance, it can be calculated according to... Figure 12 The process shown is used to adjust the position of the virtual camera. It is understandable that, compared to the case where the second reference distance ≤ relative distance < the first reference distance, when the relative distance is less than the second reference distance, the overlap area between the first and second virtual objects in the image captured by the virtual camera at the default position may be greater. For example... Figure 12 As shown, step 220 includes:

[0119] Step 1210: Determine the fourth translation information based on the preset target distance. The fourth translation information is used to indicate that the virtual camera is translated from the current position to the fourth intermediate position in the direction closer to the first virtual object, so that the distance between the first virtual object and the virtual camera is the target distance.

[0120] The intermediate position to which the virtual camera is translated, as indicated by the fourth translation information, is called the fourth intermediate position. The fourth translation information is used to indicate at least the translation direction and translation distance for translating the virtual camera from its current position to the fourth intermediate position.

[0121] It is understandable that, when the virtual camera is located in the fourth middle position, the distance between the first virtual object and the virtual camera is the target distance.

[0122] In some embodiments, the target distance may be the minimum distance between the defined first virtual object and the virtual camera.

[0123] In some embodiments, the fourth translation information can be used to indicate a translation towards the fourth intermediate position along the central axis direction of the virtual camera at its current position, in a direction closer to the first virtual object.

[0124] Step 1220: Based on the position information of the fourth intermediate position and the first virtual object, determine the fifth translation information. The fifth translation information is used to indicate that the virtual camera is translated from the fourth intermediate position to the fifth intermediate position so that the central axis of the first virtual object is located on the second viewing plane within the field of view corresponding to the virtual camera. The angle between the second viewing plane and the symmetry plane of the field of view corresponding to the virtual camera is smaller than the angle between the first viewing plane and the symmetry plane of the field of view.

[0125] The middle position to which the virtual camera is moved, as indicated by the fifth translation information, is called the fifth middle position.

[0126] In this embodiment, since the relative distance is less than the second reference distance, if the central axis of the first virtual object is still located on the first viewing angle plane within the field of view of the virtual lens when the virtual lens is in the fifth intermediate position, it cannot be guaranteed that the second virtual object will subsequently be located near the fourth viewing angle plane within the field of view of the virtual lens. Therefore, in this embodiment, when the virtual lens is in the fifth intermediate position, the central axis of the first virtual object is located on the second viewing angle plane within the field of view of the virtual lens.

[0127] In some embodiments, the fifth translation information can be used to indicate that the virtual lens is translated from the fourth intermediate position to the fifth intermediate position along a direction perpendicular to the central axis of the virtual lens.

[0128] Step 1230: Based on the fifth intermediate position, the position information of the first virtual object, and the position information of the second virtual object, determine the third rotation information. The third rotation information is used to indicate that the virtual camera is rotated from the fifth intermediate position to the third target position with the central axis of the first virtual object as the rotation center, so that the central axis of the second virtual object is located in the third view plane.

[0129] The target position to which the virtual camera will be rotated, as indicated by the third rotation information, is called the third target position. The third rotation information at least indicates the direction and angle of rotation of the virtual camera.

[0130] It is understandable that when the virtual camera is located at the third target position, the central axis of the second virtual object lies within the third view plane. Since the central axis of the first virtual object lies within the second view plane corresponding to the virtual camera when the virtual camera is at the third target position, and the second and third view planes are symmetrically distributed with respect to the field of view symmetry, the distance from the central axis of the first virtual object to the field of view symmetry is equal to the distance from the central axis of the second virtual object to the field of view symmetry. This distance can be used as the distance from the first virtual object to the field of view symmetry, and vice versa. Therefore, it can be ensured that when the virtual camera is at the third target position, the difference between the distances from the first and second virtual objects to the field of view symmetry does not exceed a preset threshold.

[0131] Step 1240: Based on the fourth translation information, the fifth translation information, and the third rotation information, control the virtual camera to move to the third target position, which is the adjusted position of the virtual camera.

[0132] Using the second target position as the adjusted virtual camera position, correspondingly, when the virtual camera is located at the second target position, the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual camera, and the distance difference between the first virtual object and the second virtual object is less than a preset threshold. Similarly, in a specific embodiment, when the virtual camera is located at the second target position, the distance between the first virtual object and the second virtual object can be equal.

[0133] In this embodiment, the distance from the central axis of the first virtual object to the symmetry plane of the virtual lens's field of view can be used as the distance from the first virtual object to the symmetry plane of the virtual lens's field of view. Correspondingly, the distance from the central axis of the second virtual object to the symmetry plane of the virtual lens's field of view can be used as the distance from the second virtual object to the symmetry plane of the virtual lens's field of view. In some embodiments, the second viewing plane within the field of view of the virtual lens can be determined in advance based on the relative distance and the target distance. Specifically, a plane perpendicular to the central axis of the virtual lens and at a distance equal to the target distance from the virtual lens is used as the first reference plane. The intersection line between the second viewing plane and the first reference plane is called the first intersection line. The intersection line between the first reference plane and the third viewing plane within the field of view of the virtual lens is also used. The third viewing plane and the second viewing plane are symmetrically distributed with respect to the symmetry plane of the virtual lens's field of view. Based on this, the distance between the first intersection line and the second intersection line is made equal to the relative distance.

[0134] In this way, it can be ensured that, under the conditions of satisfying the current relative distance and the distance between the first virtual object and the virtual lens is not less than the target distance, the determined second and third view planes are view planes with the largest corresponding angles, thereby ensuring that a large distance is maintained between the central axis of the first virtual object and the central axis of the second virtual object in the image captured by the virtual lens located at the third target position.

[0135] Through the above embodiments, it can be ensured that when the virtual camera is located at the third target position, in the image captured by the virtual camera, the first virtual object and the second virtual object are located on opposite sides of the central axis of the image, and the difference between the distance of the area where the first virtual object is located and the distance of the area where the second virtual object is located to the central axis of the image is small. Moreover, since the virtual camera can be zoomed in towards the first virtual object based on the third translation information, the area where the first and second virtual objects are located occupies a higher proportion of the image, while the proportion of other areas in the image besides the first and second virtual objects decreases, making the image layout more balanced.

[0136] In addition, compared to Figure 7 In a corresponding embodiment, due to the smaller relative distance, after adjusting the position of the virtual lens, the central axis of the first virtual object is located on the second view plane corresponding to the virtual lens, and the central axis of the second virtual object is located on the third view plane corresponding to the virtual lens. The angle between the second and third view planes is smaller than the angle between the first and fourth view planes. Therefore, compared to... Figure 7 In the corresponding embodiment, the first virtual object and the second virtual object are closer to the central axis of the image in the image obtained in this embodiment.

[0137] Figure 13 The left image shows a schematic diagram of the positions of the first virtual object, the second virtual object, and the virtual camera before adjustment. Figure 13 In the left image, the relative distance is less than the second reference distance, compared to... Figure 9 ,exist Figure 13 The distance between the first virtual object 110 and the second virtual object 120 is closer. If the image is captured using the virtual camera currently in its default position, the captured image will look like... Figure 13 As shown in the right image, there is a significant overlap between the first virtual object 110 and the second virtual object 120 in the captured image.

[0138] against Figure 13 The left image in the middle can be followed as follows Figure 12 The corresponding embodiment adjusts the position of the virtual camera. Figures 14-17 An example shows the following according to Figure 12 The diagram illustrates how the virtual camera position is adjusted.

[0139] Figure 14 The middle left figure shows the... Figure 13 The diagram illustrates the virtual camera moving to the fourth middle position, at which point the distance between the first virtual object and the virtual camera is the target distance S2. (The text abruptly ends here, likely due to an incomplete sentence or a formatting error.) Figure 14 The image captured by the virtual camera in the fourth central position is as follows: Figure 14 As shown in the middle right figure, compared to Figure 13 As can be seen in the right image, due to the zooming in of the virtual camera, Figure 14 The right image in the image shows partial models of the first and second virtual objects.

[0140] Figure 15 The left-middle figure shows a schematic diagram of the second and third view planes corresponding to the virtual lens, where the second view plane 161 and the third view plane 163 are symmetrically distributed with respect to the field of view of the virtual lens. Figure 15 and Figure 13 and Figure 14 A comparison reveals that... Figure 15 The angle between the second perspective plane 161 and the third perspective plane 162 is less than Figure 13 (or Figure 14 The angle between the two trisected perspective planes at 160° (in the middle). Figure 15 The right image in the diagram shows a schematic of the captured image when the virtual camera is positioned in the fourth center position. Figure 15 In the right figure, dashed line III is the projection of the second view plane 161 onto the imaging plane, and dashed line IV is the projection of the third view plane 162 onto the imaging plane.

[0141] Figure 16 The middle left figure shows the... Figure 15 The diagram shows the virtual camera panning to the fifth intermediate position. At this point, the central axis of the first virtual object 110 is located on the second view plane 161 corresponding to the virtual camera. Figure 16 The image captured by the virtual camera in the middle of the fifth position is as follows: Figure 16 As shown in the middle right figure, it can be seen that in this picture, the central axis of the first virtual object 110 is located at the dotted line III in the picture. At this time, there is a lot of overlap between the first virtual object and the second virtual object in the picture.

[0142] Figure 17 The left-middle image shows a schematic diagram of the virtual camera being rotated to the position of the third target. Figure 17 As can be seen in the left image, the central axis of the first virtual object 110 is located on the second view plane 161 corresponding to the virtual lens, and the central axis of the second virtual object 120 is located on the third view plane 162 corresponding to the virtual lens. Based on Figure 17 The image captured by the virtual camera located at the third target position is as follows: Figure 17 As shown in the right-middle image, it can be seen that the central axis of the first virtual object is located at dashed line III, and the central axis of the second virtual object 120 is located at dashed line IV.

[0143] contrast Figure 13 , Figure 14 , Figure 16 and Figure 17 As can be seen in the right figure, according to Figure 12 After adjusting the position of the virtual camera in the corresponding embodiment, the central axis of the first virtual object in the captured image is located at the dotted line III and the central axis of the second virtual object is located at the dotted line IV. Moreover, since the virtual camera has been rotated, the overlapping area in the captured image is reduced, making the image layout more balanced, thereby improving the user's viewing experience.

[0144] In related technologies, when virtual objects representing player characters and virtual objects representing NPCs overlap in a virtual scene, one solution is to make the virtual objects representing NPCs transparent. However, after making them transparent, the virtual objects representing NPCs are not in harmony with the virtual scene, resulting in a poor user experience. Another solution is to move the virtual camera above the virtual objects. However, this method does not allow the details of the virtual objects to be seen in the image captured from a top-down perspective.

[0145] The solution adopted in this application, for example Figure 7 and Figure 12The proposed solution addresses the issue of overlapping virtual objects by adjusting the position of the virtual camera through panning, zooming in, and rotating. This eliminates the need to make one of the interactive virtual objects transparent or to capture the image from a top-down perspective. The captured image shows a more reasonable and balanced layout between the first and second virtual objects, and the details of the virtual objects are visible, thus effectively improving the user experience.

[0146] The following describes an apparatus embodiment of this application, which can be used to perform the methods described in the above embodiments of this application. For details not disclosed in the apparatus embodiments of this application, please refer to the method embodiments described in the above embodiments of this application.

[0147] Figure 18 This is a block diagram of a virtual camera adjustment device according to an embodiment of this application. The virtual camera adjustment device can be configured in an electronic device for executing the virtual camera adjustment method provided in this application. The virtual camera is positioned in a virtual scene, and by default, it follows a first virtual object in the virtual scene for image capture; such as... Figure 18 As shown, the virtual camera adjustment device includes: a determining module 1810, used to determine the relative distance between the first virtual object and the second virtual object if there is a second virtual object interacting with the first virtual object in the virtual scene; and an adjusting module 1820, used to adjust the position of the virtual camera in the virtual scene according to the relative distance, so that the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual camera after adjustment, and the distance difference between the distance of the first virtual object to the field of view symmetry plane and the distance of the second virtual object to the field of view symmetry plane does not exceed a preset threshold.

[0148] In some embodiments of this application, the adjustment module 1820 includes: a first translation information determining unit, configured to determine first translation information based on the position information of the first virtual object and the current position information of the virtual lens if the relative distance is not less than a first reference distance; the first translation information is used to instruct the virtual lens to be translated from the current position to a first intermediate position so that the central axis of the first virtual object is located in the first viewing angle plane within the field of view corresponding to the virtual lens; a first rotation information determining unit, configured to determine first rotation information based on the position information of the first virtual object and the first intermediate position; the first rotation information is used to instruct the virtual lens to be rotated from the first intermediate position to a first target position with the central axis of the first virtual object as the rotation center; and a first control unit, configured to control the virtual lens to move to the first target position based on the first translation information and the first rotation information; the first target position is the position of the adjusted virtual lens.

[0149] In some other embodiments of this application, the adjustment module 1820 includes: a second translation information determining unit, configured to determine second translation information based on the position information of the first virtual object and the current position information of the virtual lens if the relative distance is less than the first reference distance and the relative distance is greater than or equal to the second reference distance; the second translation information is used to instruct the virtual lens to be translated from the current position to a second intermediate position so that the central axis of the first virtual object is located in the first viewing angle plane within the field of view corresponding to the virtual lens; a third translation information determining unit, configured to determine third translation information based on the second intermediate position and the position information of the first virtual object; the third translation information is used to instruct the virtual lens to be translated from the second intermediate position to the third intermediate position in a direction closer to the first virtual object; a second rotation information determining unit, configured to determine second rotation information based on the position information of the first virtual object and the third intermediate position; the second rotation information is used to instruct the virtual lens to be rotated from the third intermediate position to a second target position with the central axis of the first virtual object as the rotation center; and a second control unit, configured to control the virtual lens to move to the second target position based on the second translation information, the third translation information, and the second rotation information; the second target position is the position of the adjusted virtual lens.

[0150] In some embodiments of this application, after adjusting the position of the virtual camera, the distance from the first virtual object to the field of view symmetry plane corresponding to the virtual camera is equal to the distance from the second virtual object to the field of view symmetry plane corresponding to the virtual camera.

[0151] In some embodiments of this application, the distance from the first virtual object to the view symmetry plane is equal to the distance from the first edge of the first virtual object to the view symmetry plane; the distance from the second virtual object to the view symmetry plane is the distance from the second edge of the second virtual object to the view symmetry plane; the first edge is the edge of the first virtual object closer to the second virtual object; the second edge is the edge of the second virtual object closer to the first virtual object.

[0152] In other embodiments of this application, the adjustment module 1820 includes: a fourth translation information determining unit, configured to determine fourth translation information based on a preset target distance if the relative distance is less than a second reference distance, the fourth translation information indicating that the virtual camera is translated from its current position to a fourth intermediate position in a direction closer to the first virtual object, so that the distance between the first virtual object and the virtual camera is the target distance; and a fifth translation information determining unit, configured to determine fifth translation information based on the fourth intermediate position and the position information of the first virtual object, the fifth translation information indicating that the virtual camera is translated from the fourth intermediate position to the fifth intermediate position, so that the central axis of the first virtual object is located within the field of view corresponding to the virtual camera. On the second perspective plane; the angle between the second perspective plane and the symmetry plane of the field of view corresponding to the virtual lens is smaller than the angle between the first perspective plane and the symmetry plane of the field of view; the third rotation information determination unit is used to determine the third rotation information based on the fifth intermediate position, the position information of the first virtual object, and the position information of the second virtual object. The third rotation information is used to indicate that the virtual lens is rotated from the fifth intermediate position to the third target position with the central axis of the first virtual object as the rotation center, so that the central axis of the second virtual object is located in the third perspective plane; the third control unit is used to control the virtual lens to move to the third target position based on the fourth translation information, the fifth translation information, and the third rotation information. The third target position is the position of the adjusted virtual lens.

[0153] In some embodiments of this application, the distance between the first intersection line and the second intersection line is equal to the relative distance. The first intersection line refers to the intersection line between the second view plane and the first reference plane. The second intersection line refers to the intersection line between the first reference plane and the third view plane within the field of view of the virtual lens. The third view plane and the second view plane are symmetrically distributed with respect to the field of view of the virtual lens. The first reference plane refers to the plane that is perpendicular to the central axis of the virtual lens and whose distance from the virtual lens is equal to the relative distance.

[0154] In some embodiments of this application, the distance from the central axis of the first virtual object to the view symmetry plane is taken as the distance from the first virtual object to the view symmetry plane; the distance from the central axis of the second virtual object to the view symmetry plane is taken as the distance from the second virtual object to the view symmetry plane.

[0155] In some embodiments of this application, the first reference distance is equal to the product of the first coefficient and the first distance, wherein the first coefficient ∈ (0, 1), and the first distance is equal to the maximum distance between the first view plane and the fourth view plane within the field of view of the virtual lens; the fourth view plane and the first view plane are symmetrically distributed with respect to the field of view symmetry.

[0156] In some embodiments of this application, the first coefficient is equal to 1 / 3.

[0157] In some embodiments of this application, the second reference distance is equal to the distance between the third and fourth intersection lines. The third intersection line refers to the intersection line between the second reference plane and the first viewing angle plane. The fourth intersection line refers to the intersection line between the second reference plane and the fourth viewing angle plane within the field of view corresponding to the virtual lens. The fourth viewing angle plane and the first viewing angle plane are symmetrically distributed with respect to the field of view. The second reference plane refers to the plane that is perpendicular to the central axis of the virtual lens and whose distance from the virtual lens is the target distance.

[0158] In some embodiments of this application, the first view plane is a three-part view plane obtained by dividing the view corresponding to the virtual lens into three equal parts.

[0159] Figure 19 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. The electronic device may be a server, a smartphone, or other terminal; it may also be any other device capable of executing the virtual camera adjustment method provided in this application.

[0160] like Figure 19 As shown, the electronic device may include: a processor 1901, such as a CPU (Central Processing Unit), a network interface 1904, a user interface 1903, a memory 1905, and a communication bus 1902. The communication bus 1902 is used to enable communication between these components. The user interface 1903 can be used to connect a display screen or an input unit such as a keyboard. The network interface 1904 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface). The memory 1905 may be high-speed RAM or non-volatile memory, such as a disk drive. Alternatively, the memory 1905 may be a storage device independent of the aforementioned processor 1901.

[0161] Those skilled in the art will understand that Figure 19 The structure of the electronic device shown does not constitute a limitation on the electronic device and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0162] like Figure 19 As shown, the memory 1905, which is a computer-readable storage medium, may include an operating system, a network communication module, a user interface module, and a program for implementing a virtual camera adjustment method.

[0163] exist Figure 19In the illustrated electronic device, the network interface 1904 is mainly used for communication connections with other devices. The user interface 1903 is mainly used for connecting to the client (user end) and communicating data with the client; while the processor 1901 can be used to call the program storing the virtual lens adjustment method in the memory 1905 and execute the steps of the virtual lens adjustment method as described in any of the above method embodiments.

[0164] According to one aspect of the embodiments of this application, a computer-readable storage medium is provided, on which computer-readable instructions are stored, which, when executed by a processor, implement the virtual camera adjustment method as described in any of the above method embodiments.

[0165] It should be noted that the computer-readable medium shown in the embodiments of this application can be a computer-readable signal medium or a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), flash memory, optical fiber, portable compact disc read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this application, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In this application, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such transmitted data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. The computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to wireless, wired, etc., or any suitable combination thereof.

[0166] According to one aspect of the embodiments of this application, a computer program product is provided, which includes computer instructions that, when executed by a processor, implement the virtual camera adjustment method as described in any of the above method embodiments.

[0167] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. Each block in a flowchart or block diagram may represent a module, segment, or portion of code, which contains one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0168] Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, touch terminal, or network device, etc.) to execute the method according to the embodiments of this application.

[0169] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the embodiments disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein.

[0170] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.

Claims

1. A method for adjusting a virtual camera lens, characterized in that, The virtual camera is positioned within a virtual scene, and by default, the virtual camera follows a first virtual object in the virtual scene to capture images; the method includes: If there is a second virtual object in the virtual scene that interacts with the first virtual object, determine the relative distance between the first virtual object and the second virtual object; The position of the virtual lens in the virtual scene is adjusted according to the relative distance so that the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual lens after adjustment, and the distance difference between the distance of the first virtual object to the field of view symmetry plane and the distance of the second virtual object to the field of view symmetry plane does not exceed a preset threshold. The field of view symmetry plane corresponding to the virtual lens is a symmetrical plane that divides the field of view corresponding to the virtual lens into two symmetrical parts. The step of adjusting the position of the virtual camera in the virtual scene according to the relative distance includes: If the relative distance is not less than the first reference distance, the first translation information is determined based on the position information of the first virtual object and the current position information of the virtual lens. The first translation information is used to indicate that the virtual lens is translated from the current position to the first intermediate position so that the central axis of the first virtual object is located in the first viewing plane within the field of view of the virtual lens. The first viewing plane is located between the field of view symmetry plane of the virtual lens and the field of view boundary plane of the virtual lens. Based on the position information of the first virtual object and the first intermediate position, first rotation information is determined. The first rotation information is used to instruct the virtual camera to be rotated from the first intermediate position to the first target position with the central axis of the first virtual object as the rotation center. Based on the first translation information and the first rotation information, control the virtual camera to move to the first target position, where the first target position is the adjusted position of the virtual camera; or If the relative distance is less than the first reference distance and the relative distance is greater than or equal to the second reference distance, the second translation information is determined based on the position information of the first virtual object and the current position information of the virtual lens. The second translation information is used to indicate that the virtual lens is translated from the current position to the second intermediate position so that the central axis of the first virtual object is located in the first viewing plane within the field of view corresponding to the virtual lens. Based on the position information of the second intermediate position and the first virtual object, a third translation information is determined. The third translation information is used to indicate that the virtual camera is translated from the second intermediate position to the third intermediate position in a direction closer to the first virtual object. Based on the position information of the first virtual object and the third intermediate position, second rotation information is determined. The second rotation information is used to indicate that the virtual camera is rotated from the third intermediate position to the second target position with the central axis of the first virtual object as the rotation center. Based on the second translation information, the third translation information, and the second rotation information, control the virtual camera to move to the second target position, where the second target position is the adjusted position of the virtual camera; or If the relative distance is less than the second reference distance, the fourth translation information is determined according to the preset target distance. The fourth translation information is used to indicate that the virtual camera is translated from the current position to a fourth intermediate position in a direction closer to the first virtual object, so that the distance between the first virtual object and the virtual camera is the target distance. Based on the fourth intermediate position and the position information of the first virtual object, a fifth translation information is determined. The fifth translation information is used to indicate that the virtual camera is translated from the fourth intermediate position to the fifth intermediate position so that the central axis of the first virtual object is located on the second viewing plane within the field of view corresponding to the virtual camera. The angle between the second viewing plane and the symmetry plane of the field of view corresponding to the virtual camera is smaller than the angle between the first viewing plane and the symmetry plane of the field of view. Based on the fifth intermediate position, the position information of the first virtual object, and the position information of the second virtual object, a third rotation information is determined. The third rotation information is used to indicate that the virtual camera is rotated from the fifth intermediate position to the third target position with the central axis of the first virtual object as the rotation center, so that the central axis of the second virtual object is located in the third view plane. The third view plane and the second view plane are symmetrically distributed with respect to the field of view of the virtual camera. Based on the fourth translation information, the fifth translation information, and the third rotation information, the virtual camera is controlled to move to the third target position, which is the adjusted position of the virtual camera.

2. The method according to claim 1, characterized in that, After adjusting the position of the virtual camera, the distance from the first virtual object to the field of view symmetry plane corresponding to the virtual camera is equal to the distance from the second virtual object to the field of view symmetry plane corresponding to the virtual camera.

3. The method according to claim 1, characterized in that, The distance from the first virtual object to the view symmetry plane is the distance from the first edge of the first virtual object to the view symmetry plane; the distance from the second virtual object to the view symmetry plane is the distance from the second edge of the second virtual object to the view symmetry plane; the first edge is the edge of the first virtual object closer to the second virtual object; the second edge is the edge of the second virtual object closer to the first virtual object.

4. The method according to claim 1, characterized in that, The distance from the central axis of the first virtual object to the visual symmetry plane is taken as the distance from the first virtual object to the visual symmetry plane; the distance from the central axis of the second virtual object to the visual symmetry plane is taken as the distance from the second virtual object to the visual symmetry plane.

5. The method according to claim 1, characterized in that, The distance between the first and second lines of intersection is equal to the relative distance. The first line of intersection is the line of intersection between the second view plane and the first reference plane. The second line of intersection is the line of intersection between the first reference plane and the third view plane within the field of view of the virtual lens. The third view plane and the second view plane are symmetrically distributed with respect to the field of view of the virtual lens. The first reference plane is a plane that is perpendicular to the central axis of the virtual lens and whose distance from the virtual lens is equal to the relative distance.

6. The method according to any one of claims 1 to 2, characterized in that, The first reference distance is equal to the product of the first coefficient and the first distance, where the first coefficient ∈ (0, 1), and the first distance is equal to the maximum distance between the first view plane and the fourth view plane within the field of view of the virtual lens; the fourth view plane and the first view plane are symmetrically distributed with respect to the field of view.

7. The method according to claim 6, characterized in that, The first coefficient is equal to 1 / 3.

8. The method according to claim 1, characterized in that, The second reference distance is equal to the distance between the third and fourth intersection lines. The third intersection line is the intersection line between the second reference plane and the first viewing angle plane. The fourth intersection line is the intersection line between the second reference plane and the fourth viewing angle plane within the field of view of the virtual lens. The fourth viewing angle plane and the first viewing angle plane are symmetrically distributed with respect to the field of view. The second reference plane is a plane that is perpendicular to the central axis of the virtual lens and whose distance from the virtual lens is the target distance.

9. The method according to claim 1, characterized in that, The first view plane is a three-part view plane obtained by dividing the view corresponding to the virtual lens into three equal parts.

10. A virtual camera adjustment device, characterized in that, The virtual camera is positioned within a virtual scene, and by default, the virtual camera follows a first virtual object in the virtual scene to capture images; the device includes: The determining module is used to determine the relative distance between the first virtual object and the second virtual object if there is a second virtual object in the virtual scene that interacts with the first virtual object; An adjustment module is used to adjust the position of the virtual lens in the virtual scene according to the relative distance, so that the first virtual object and the second virtual object are located on opposite sides of the field of view symmetry plane corresponding to the virtual lens after adjustment, and the distance difference between the distance of the first virtual object to the field of view symmetry plane and the distance of the second virtual object to the field of view symmetry plane does not exceed a preset threshold. The field of view symmetry plane corresponding to the virtual lens is a symmetrical plane that divides the field of view corresponding to the virtual lens into two symmetrical parts. The step of adjusting the position of the virtual camera in the virtual scene according to the relative distance includes... If the relative distance is not less than the first reference distance, the first translation information is determined based on the position information of the first virtual object and the current position information of the virtual lens. The first translation information is used to indicate that the virtual lens is translated from the current position to the first intermediate position so that the central axis of the first virtual object is located in the first viewing plane within the field of view of the virtual lens. The first viewing plane is located between the field of view symmetry plane of the virtual lens and the field of view boundary plane of the virtual lens. Based on the position information of the first virtual object and the first intermediate position, first rotation information is determined. The first rotation information is used to instruct the virtual camera to be rotated from the first intermediate position to the first target position with the central axis of the first virtual object as the rotation center. Based on the first translation information and the first rotation information, control the virtual camera to move to the first target position, where the first target position is the adjusted position of the virtual camera; or If the relative distance is less than the first reference distance and the relative distance is greater than or equal to the second reference distance, the second translation information is determined based on the position information of the first virtual object and the current position information of the virtual lens. The second translation information is used to indicate that the virtual lens is translated from the current position to the second intermediate position so that the central axis of the first virtual object is located in the first viewing plane within the field of view corresponding to the virtual lens. Based on the position information of the second intermediate position and the first virtual object, a third translation information is determined. The third translation information is used to indicate that the virtual camera is translated from the second intermediate position to the third intermediate position in a direction closer to the first virtual object. Based on the position information of the first virtual object and the third intermediate position, second rotation information is determined. The second rotation information is used to indicate that the virtual camera is rotated from the third intermediate position to the second target position with the central axis of the first virtual object as the rotation center. Based on the second translation information, the third translation information, and the second rotation information, control the virtual camera to move to the second target position, where the second target position is the adjusted position of the virtual camera; or If the relative distance is less than the second reference distance, the fourth translation information is determined according to the preset target distance. The fourth translation information is used to indicate that the virtual camera is translated from the current position to a fourth intermediate position in a direction closer to the first virtual object, so that the distance between the first virtual object and the virtual camera is the target distance. Based on the fourth intermediate position and the position information of the first virtual object, a fifth translation information is determined. The fifth translation information is used to indicate that the virtual camera is translated from the fourth intermediate position to the fifth intermediate position so that the central axis of the first virtual object is located on the second viewing plane within the field of view corresponding to the virtual camera. The angle between the second viewing plane and the symmetry plane of the field of view corresponding to the virtual camera is smaller than the angle between the first viewing plane and the symmetry plane of the field of view. Based on the fifth intermediate position, the position information of the first virtual object, and the position information of the second virtual object, a third rotation information is determined. The third rotation information is used to indicate that the virtual camera is rotated from the fifth intermediate position to the third target position with the central axis of the first virtual object as the rotation center, so that the central axis of the second virtual object is located in the third view plane. The third view plane and the second view plane are symmetrically distributed with respect to the field of view of the virtual camera. Based on the fourth translation information, the fifth translation information, and the third rotation information, the virtual camera is controlled to move to the third target position, which is the adjusted position of the virtual camera.

11. An electronic device, characterized in that, include: processor; A memory storing computer-readable instructions that, when executed by the processor, implement the method as described in any one of claims 1 to 9.

12. A computer-readable storage medium having stored thereon computer-readable instructions that, when executed by a processor, implement the method as described in any one of claims 1 to 9.