CN115131472A - Transition processing method, device, equipment and medium for panoramic switching - Google Patents

Transition processing method, device, equipment and medium for panoramic switching Download PDF

Info

Publication number
CN115131472A
CN115131472A CN202211059470.6A CN202211059470A CN115131472A CN 115131472 A CN115131472 A CN 115131472A CN 202211059470 A CN202211059470 A CN 202211059470A CN 115131472 A CN115131472 A CN 115131472A
Authority
CN
China
Prior art keywords
segmentation
panoramic image
scene
subgraphs
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202211059470.6A
Other languages
Chinese (zh)
Other versions
CN115131472B (en
Inventor
曲达
张骥
潘林林
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202211059470.6A priority Critical patent/CN115131472B/en
Publication of CN115131472A publication Critical patent/CN115131472A/en
Application granted granted Critical
Publication of CN115131472B publication Critical patent/CN115131472B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T13/00Animation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • G06F3/04815Interaction with a metaphor-based environment or interaction object displayed as three-dimensional, e.g. changing the user viewpoint with respect to the environment or object
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04845Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range for image manipulation, e.g. dragging, rotation, expansion or change of colour
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20021Dividing image into blocks, subimages or windows

Abstract

The disclosure provides a transition processing method, device, equipment and medium for panoramic switching, and relates to the field of artificial intelligence, in particular to the field of computer vision. The specific implementation scheme is as follows: acquiring a plurality of segmentation subgraphs corresponding to the current display panoramic image, wherein different segmentation subgraphs comprise scene elements with different scene depths; generating local transition animations corresponding to the segmentation subgraphs according to the scene depth of the scene elements contained in the segmentation subgraphs; and rendering and displaying each local transition animation according to the image position of each segmented sub-image in the current display panoramic image so as to realize the transition of switching from the current display panoramic image to the next display panoramic image. Through the technical scheme, the space display effect of the panoramic image transition process can be enhanced, and the sense of reality during switching of the panoramic image is improved.

Description

Method, device, equipment and medium for transition processing of panoramic switching
Technical Field
The present disclosure relates to the field of computer vision technologies, and in particular, to a method, an apparatus, a device, and a medium for transition processing of panorama handover.
Background
With the rapid development of computer vision technology, panoramic roaming technology is gradually used for real environment simulation. In the prior art, a plurality of images shot in the horizontal 360-degree direction and the vertical 180-degree direction are spliced into a panoramic image by using a camera with a fisheye lens; then, a virtually realized panoramic space is constructed through the series connection of the panoramic images; when the user clicks and inquires the surrounding environment, the movement of the panoramic space can be controlled by using the mouse, so that the user can browse the roaming scene. In addition, in the prior art, in the panoramic image switching process under the continuous sampling points, the transition animation effect can be increased so as to improve the live-action experience of the user.
However, in the prior art, when the display is switched between different panoramic images, one panoramic image is usually used for stitching transition, and the sense of spatial depth and the sense of speed of the near and far vision are lacked. In addition, the conventional transition animation effect is realized only by stretching the whole panoramic image before transition, and the spatial depth sense and the visual near-large and far-small speed sense are lacked.
Disclosure of Invention
The disclosure provides a transition processing method, device, equipment and medium for panoramic switching.
According to an aspect of the present disclosure, there is provided a method of transition processing of panorama switching, including:
acquiring a plurality of segmentation subgraphs corresponding to the current display panoramic image, wherein different segmentation subgraphs comprise scene elements with different scene depths;
generating local transition animations corresponding to the segmentation subgraphs according to the scene depth of the scene elements contained in the segmentation subgraphs;
and rendering and displaying each local transition animation according to the image position of each partition subgraph in the current display panoramic image so as to realize the transition of switching from the current display panoramic image to the next display panoramic image.
According to another aspect of the present disclosure, there is provided an electronic device including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to cause the at least one processor to perform the method of any of the embodiments of the present disclosure.
According to another aspect of the present disclosure, there is provided a non-transitory computer readable storage medium having stored thereon computer instructions for causing a computer to perform the method of any one of the embodiments of the present disclosure.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not to be construed as limiting the present disclosure. Wherein:
fig. 1 is a flowchart of a method for transition processing of panorama switching according to an embodiment of the present disclosure;
fig. 2 is a flowchart of another method of transition processing of panorama switching provided according to an embodiment of the present disclosure;
fig. 3 is a schematic diagram illustrating a recognition result of a scene element according to an embodiment of the disclosure;
FIG. 4 is a schematic illustration of a display of a horizon provided in accordance with an embodiment of the present disclosure;
fig. 5 is a schematic structural diagram of an apparatus for transition processing of panorama switching according to an embodiment of the present disclosure;
fig. 6 is a block diagram of an electronic device used to implement a method of transition processing for panorama switching of an embodiment of the present disclosure.
Detailed Description
Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, in which various details of the embodiments of the disclosure are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present disclosure. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a flowchart of a transition processing method for panorama switching according to an embodiment of the present disclosure. The embodiment of the disclosure is applicable to the situation of transition processing of the panoramic image in the panoramic roaming technology, and is used for enhancing the reality and the spatial effect of the panoramic image. The method may be performed by an apparatus for transition processing of panorama switching, which may be implemented in hardware and/or software, and may be generally integrated in an electronic device, and for example, may be integrated in a computer device.
As shown in fig. 1, a transition processing method for panoramic switching provided in an embodiment of the present disclosure includes the following specific steps:
s110, obtaining a plurality of segmentation subgraphs corresponding to the current display panoramic image, wherein different segmentation subgraphs comprise scene elements with different scene depths.
The currently displayed panoramic image may refer to a currently displayed panoramic image, and the currently displayed panoramic image may include a plurality of elements, for example, sky, roads, buildings, numbers, pedestrians, and the like.
The segmentation subgraphs may refer to sub-images obtained by segmenting the current display panoramic image, and it should be noted that no intersection is generated between the segmentation subgraphs, and a current display panoramic image can be formed by combining all the segmentation subgraphs.
The scene elements may refer to various symbolic elements contained in the currently displayed panoramic image, and may be, for example, roads, trees, buildings, pedestrians, and the like. The scene depth can refer to the distance degree of each scene element in the segmentation subgraph; generally, the deeper the level depth, the further the visual distance of the scene element in the segmented sub-image.
And S120, generating local transition animations corresponding to the segmentation subgraphs according to the scene depth of the scene element contained in the segmentation subgraphs.
The local transition animation may be an animation composed of a plurality of images generated after local transition processing is performed on the segmented subgraph corresponding to each scene element according to the scene depth of each scene element.
Specifically, after obtaining a plurality of segmented sub-images corresponding to the currently displayed panoramic image, local transition processing may be performed on each segmented sub-image according to the scene depth of different scene elements in different segmented sub-images, so as to obtain a plurality of images, and the plurality of images are combined, so as to obtain local transition animations corresponding to each segmented sub-image.
And S130, rendering and displaying the local transition animations according to the image position of each partition subgraph in the current display panoramic image so as to realize the transition of switching from the current display panoramic image to the next display panoramic image.
The rendering and displaying can be that the local transition animation is used for replacing a segmentation subgraph corresponding to the local transition animation in the current displayed panoramic image and displaying.
According to the technical scheme of the embodiment, the local transition animations respectively corresponding to the split sub-images are generated by utilizing the scene depth of the scene elements contained in the split sub-images corresponding to the current display panoramic image, and then the local transition animations are rendered and displayed according to the image positions of the split sub-images in the current display panoramic image, so that the transition from the current display panoramic image to the next display panoramic image is realized, the problems that the space effect of the panoramic image is weak and the sense of reality is poor in the existing panoramic roaming technology are solved, the space effect of the panoramic image can be enhanced, and the sense of reality during switching of the panoramic image is improved.
Fig. 2 is a flowchart of another method of transition processing of panorama switching provided according to an embodiment of the present disclosure; in this embodiment, the operation of generating the local transition animation corresponding to each of the segmented subgraphs according to the scene depth of the scene element included in each of the segmented subgraphs is embodied as: determining motion rates respectively corresponding to the segmentation subgraphs according to the scene depth of scene elements contained in the segmentation subgraphs, wherein the scene depth and the motion rates are in an inverse proportion relation; determining the number of transitional animation display frames according to the preset transitional animation duration and the preset frame interval; and generating local transition animations respectively corresponding to the segmentation subgraphs according to the motion rate and the transition animation display frame number respectively corresponding to the segmentation subgraphs.
As shown in fig. 2, a transition processing method for panoramic switching according to an embodiment of the present disclosure includes the following specific steps:
s210, obtaining a plurality of segmentation subgraphs corresponding to the current displayed panoramic image, wherein different segmentation subgraphs comprise scene elements with different scene depths.
In the embodiment of the present disclosure, optionally, the scene element may include: ground, buildings, and sky; the depth of the scene difference on the ground is smaller than that of the building, and the depth of the scene difference of the building is smaller than that of the sky. Therefore, the scene elements in the panoramic image can be refined by dividing the scene elements, and an effective basis is provided for the generation of a subsequent segmentation sub-image.
In an optional embodiment, the obtaining of multiple split sub-graphs corresponding to the currently displayed panoramic image may include: if a route dragging instruction aiming at the currently displayed panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation sub-images corresponding to the currently displayed panoramic image; or if a selection instruction for setting an image position point in the current exhibition panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation subgraphs corresponding to the current exhibition panoramic image.
The route dragging instruction may refer to an instruction for performing dragging processing on a route in a currently displayed panoramic image. The set image location point may refer to a location point previously set in the currently displayed panorama image. The selection instruction may refer to an instruction to select a set image position point in the currently presented panoramic image. Illustratively, a device such as a mouse which initiates a route dragging instruction or a selection instruction may be monitored, and when it is detected that there is a time for triggering a set image position point in the currently displayed panoramic image, it is proved that there is a selection instruction; when the opportunity of dragging the route in the current display panoramic image exists, the route dragging instruction is proved to exist.
Specifically, by monitoring a route dragging instruction for the currently displayed panoramic image or a selection instruction for setting an image position point in the currently displayed panoramic image, when the route dragging instruction for the currently displayed panoramic image is detected in the panoramic roaming scene, or when the selection instruction for setting the image position point in the currently displayed panoramic image is detected in the panoramic roaming scene, a plurality of segmented sub-images corresponding to the currently displayed panoramic image are acquired, so that an accurate time is provided for acquiring the plurality of segmented sub-images corresponding to the currently displayed panoramic image, waste of storage space is avoided, and acquisition efficiency of the segmented sub-images can be effectively improved.
S220, determining motion rates respectively corresponding to the segmentation subgraphs according to the scene depth of the scene element contained in each segmentation subgraph, wherein the scene depth and the motion rates are in inverse proportion.
The motion rate can refer to the motion speed of the scene element in the panoramic switching transition process; generally, the deeper the scene depth, the smaller the motion rate; illustratively, in the disclosed embodiment, the motion rates of the landscape elements ground, buildings and sky are: the ground has a motion rate greater than that of the building, which is greater than that of the sky.
And S230, determining the number of transition animation display frames according to the preset transition animation time length and the preset frame interval.
The preset transition animation duration may refer to a preset display duration of the transition animation in the panorama switching transition process. The inter-frame distance may refer to an interval time between two adjacent frames. The number of transition animation display frames may refer to the number of frames displayed by the transition animation in the panorama switching transition process, and may be determined as the number of transition animation display frames, for example, according to a quotient obtained by dividing a preset transition animation duration by a frame interval.
And S240, generating local transition animations respectively corresponding to the segmentation subgraphs according to the motion rate and the transition animation display frame number respectively corresponding to the segmentation subgraphs.
Specifically, the corresponding local transition animation can be generated for each segmentation subgraph according to the motion rate and the transition animation display frame number respectively corresponding to each segmentation subgraph, so that layered transition can be realized, and the sense of reality during panoramic image switching can be effectively improved.
In an optional embodiment, generating the local transition animation corresponding to each of the segmented sub-images according to the motion rate and the number of the transition animation display frames corresponding to each of the segmented sub-images may include: acquiring a current processing segmentation subgraph; calculating a stretching distance according to the motion rate corresponding to the current processing segmentation subgraph and the frame interval; stretching the current processing segmentation subgraph according to the stretching distance, and adding the obtained stretched subgraph into an image set corresponding to the current processing segmentation subgraph; after the stretched subgraph is taken as a new current processing segmentation subgraph, returning to execute the operation of stretching the current processing segmentation subgraph according to the stretching distance until the number of the images in the image set reaches the number of transition animation display frames; and generating a local transition animation corresponding to the current processing segmentation subgraph according to the image set.
The stretching distance may refer to a distance between two adjacent inter-frame distance maps corresponding to the same partition subgraph, and for example, the stretching distance between two adjacent inter-frame distance maps may be determined according to a product of the motion rate and the inter-frame distance. The stretched subgraph may refer to a split subgraph after stretching.
Specifically, the stretching distance may be calculated according to the motion rate and the frame interval corresponding to the currently processed segmented subgraph; further, stretching the current processing segmentation subgraph according to the stretching distance, and adding the obtained stretched subgraph into the image set corresponding to the current processing segmentation subgraph; and after the stretched subgraph is taken as a new current processing segmentation subgraph, returning to execute the operation of stretching the current processing segmentation subgraph according to the stretching distance until the number of the images in the image set reaches the number of transition animation display frames; finally, according to the image set, the local transition animation corresponding to the currently processed segmentation subgraph is generated, so that the corresponding local transition animation can be generated for different segmentation subgraphs according to the motion rates of different scene elements, and the sense of reality during switching of the panoramic image can be effectively improved.
And S250, after the local transition animations corresponding to the ground are rendered and displayed for a set frame number, rendering and displaying the local transition animations corresponding to the building and the sky respectively together so as to realize transition from the currently displayed panoramic image to the next displayed panoramic image.
Specifically, when each local transition animation is rendered and displayed, the local transition animation corresponding to the ground is rendered and displayed, and further the local transition animation corresponding to the building and the sky respectively is rendered and displayed together, so that the transition of the panoramic image is realized, and the sense of reality during switching of the panoramic image can be greatly improved.
The technical scheme of the embodiment of the disclosure determines the motion rate corresponding to each segmented sub-image by using the scene depth of the scene element contained in the plurality of segmented sub-images corresponding to the current displayed panoramic image, and determines the number of the transitional animation display frames according to the preset transitional animation duration and the preset frame interval; further, according to the motion rate and the number of the transition animation display frames which respectively correspond to each segmentation subgraph, local transition animations which respectively correspond to each segmentation subgraph are generated; furthermore, after the local transition animation corresponding to the ground is rendered and displayed for the set frame number, the local transition animation corresponding to the building and the sky respectively starts to be rendered and displayed together, so that the transition from the current displayed panoramic image to the next displayed panoramic image is realized, the problems of weaker spatial effect and poorer sense of reality of the panoramic image in the existing panoramic roaming technology are solved, the spatial display effect in the transition process of the panoramic image can be enhanced, and the sense of reality during switching of the panoramic image is improved.
On the basis of the above embodiments, the embodiments of the present disclosure may further include: acquiring panoramic images matched with the panoramic roaming scene; and identifying each scene element contained in each panoramic image, and dividing each panoramic image into a plurality of divided sub-images according to the identification result of the scene element. The panoramic roaming scene may refer to a scene that needs to be subjected to panoramic roaming, and may be a tourist attraction or a street, for example. Therefore, each panoramic image can be divided into a plurality of divided sub-images according to the identification result of each scene element contained in each panoramic image, and an effective basis is provided for the subsequent operation.
In an alternative embodiment, identifying scene elements included in each panoramic image, and dividing each panoramic image into a plurality of divided sub-images according to the identification result of the scene elements may include: determining a horizon according to the ground identification position in the current panoramic image; identifying a ground type matched with the current panoramic image, and acquiring a rising angle and a dropping angle matched with the ground type; respectively rotating the raising angle and the drooping angle in clockwise and counterclockwise directions by taking the horizontal line as a rotating edge and the central point of the horizontal line as a rotating vertex to obtain a raising edge in the clockwise direction, a raising edge in the counterclockwise direction, a drooping edge in the clockwise direction and a drooping edge in the counterclockwise direction; and according to the raising edge in the clockwise direction, the raising edge in the anticlockwise direction, the downward hanging edge in the clockwise direction and the downward hanging edge in the anticlockwise direction, obtaining segmentation subgraphs respectively corresponding to the ground, the building and the sky in the current panoramic image by segmentation.
The ground identification position may refer to a position for identifying the ground, and may be, for example, a position where the planes of the scene elements intersect. The horizon may refer to a line that contains the ground recognition location and is parallel to the bottom edge of the panoramic image. FIG. 3 is a schematic diagram of recognition results of scene elements; specifically, the ground, buildings, and sky contained in the panoramic image may be identified. FIG. 4 is a schematic view of the display of the horizon; specifically, the other scene elements except the scene element sky and the ground can be used as two side elements, the intersection point of the sky, the ground and each two side surfaces is identified as a ground identification position, and finally, a line which passes through the ground identification position and is parallel to the bottom edge of the panoramic image can be used as a horizon line.
The ground type may refer to a road type to which a scene element ground in the panoramic image belongs, and may be, for example, a high-speed type, a provincial road type, a county road type, a rural road type, an expressway type, a main road type, a secondary main road type, a branch road type, and the like, which is not limited in this disclosure. The raising angle and the dropping angle may refer to a scene element division angle corresponding to a ground type matched with the panoramic image; for example, since the high-speed type ground is extremely wide and there are few trees, the uplift angle may be set to 20 ° and the droop angle to 10 °; the provincial road type has wider ground and more trees, so that the uplift angle and the droop angle can be increased adaptively, the uplift angle is set to be 45 degrees, and the droop angle is set to be 30 degrees; because county and county road types have wide ground and trees and shorter buildings, the uplift angle can be set to be 30 degrees, and the droop angle can be set to be 30 degrees; similarly, the uplift angle of the rural type ground can be set to 45 degrees, and the droop angle can be set to 30 degrees; the uplift angle of the express way type ground is set to be 20 degrees, and the droop angle is set to be 10 degrees; the uplift angle of the trunk type ground is set to be 60 degrees, and the droop angle is set to be 5 degrees; the uplift angle of the secondary trunk type ground is set to be 60 degrees, and the droop angle is set to be 15 degrees; the uplift angle of the branch type ground was set to 60 °, and the sag angle was set to 15 °.
Specifically, the horizon can be determined according to the ground identification position in the current panoramic image; identifying the ground type matched with the current panoramic image, and acquiring the rising angle and the falling angle matched with the ground type; further, the horizontal line is taken as a rotating edge, the central point of the horizontal line is taken as a rotating vertex, and the raising angle and the dropping angle are respectively rotated along the clockwise direction and the anticlockwise direction to obtain a raising edge in the clockwise direction, a raising edge in the anticlockwise direction, a dropping edge in the clockwise direction and a dropping edge in the anticlockwise direction; finally, according to the raising edge in the clockwise direction, the raising edge in the anticlockwise direction, the downward hanging edge in the clockwise direction and the downward hanging edge in the anticlockwise direction, the current panoramic image is divided to obtain the divided sub-images respectively corresponding to the ground, the buildings and the sky, therefore, each panoramic image can be accurately divided into a plurality of divided sub-images according to the ground type matched with each panoramic image, and an effective basis is provided for subsequent work.
As an implementation of the above-described method for transition processing of each panorama switch, the present disclosure also provides an alternative embodiment of an execution apparatus for implementing the above-described method for transition processing of each panorama switch.
Fig. 5 is a schematic structural diagram of an apparatus for transition processing of panorama switching according to an embodiment of the present disclosure; as shown in fig. 5, the apparatus for transition processing of panorama switching includes: a data acquisition module 310, a local transition module 320, and a rendering display module 330;
the data obtaining module 310 is configured to obtain a plurality of segmented sub-images corresponding to a currently displayed panoramic image, where different segmented sub-images include scene elements with different scene depths;
a local transition module 320, configured to generate local transition animations corresponding to the respective segmented subgraphs according to the scene depth of the scene element included in the respective segmented subgraphs;
and the rendering and displaying module 330 is configured to render and display each local transition animation according to an image position of each segmented sub-image in the currently displayed panoramic image, so as to implement transition from the currently displayed panoramic image to a next displayed panoramic image.
According to the technical scheme, the partial transition animations corresponding to the segmentation subgraphs are generated by utilizing the scene depth of the scene element contained in the segmentation subgraphs corresponding to the current displayed panoramic image, and then the partial transition animations are rendered and displayed according to the image positions of the segmentation subgraphs in the current displayed panoramic image, so that the transition from the current displayed panoramic image to the next displayed panoramic image is achieved, the problems that the space effect of the panoramic image is weak and the sense of reality is poor in the existing panoramic roaming technology are solved, the space display effect of the transition process of the panoramic image can be enhanced, and the sense of reality during switching of the panoramic image is improved.
Optionally, the data obtaining module 310 may be specifically configured to: if a route dragging instruction aiming at the currently displayed panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation sub-images corresponding to the currently displayed panoramic image; or if a selection instruction for setting an image position point in the current exhibition panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation subgraphs corresponding to the current exhibition panoramic image.
Optionally, the local transition module 320 may specifically include: the device comprises a motion rate determining unit, a display frame number determining unit and a local transition animation generating unit;
the motion rate determining unit is used for determining motion rates respectively corresponding to the segmentation subgraphs according to the scene depth of scene elements contained in the segmentation subgraphs, and the scene depth and the motion rates are in an inverse proportion relation;
the display frame number determining unit is used for determining the display frame number of the transition animation according to the preset transition animation duration and the preset frame interval;
and the local transition animation generating unit is used for generating local transition animations respectively corresponding to the segmentation subgraphs according to the motion rate and the transition animation display frame number respectively corresponding to the segmentation subgraphs.
Optionally, the local transition animation generating unit may be specifically configured to: acquiring a current processing segmentation subgraph; calculating a stretching distance according to the motion rate corresponding to the current processing segmentation subgraph and the frame interval; stretching the current processing segmentation subgraph according to the stretching distance, and adding the obtained stretched subgraph into an image set corresponding to the current processing segmentation subgraph; after the stretched subgraph is taken as a new current processing segmentation subgraph, returning to execute the operation of stretching the current processing segmentation subgraph according to the stretching distance until the number of the images in the image set reaches the number of transition animation display frames; and generating a local transition animation corresponding to the current processing segmentation subgraph according to the image set.
Optionally, the scene elements may include: ground, buildings and sky; the depth of the scene difference on the ground is smaller than that of the building, and the depth of the scene difference of the building is smaller than that of the sky.
Optionally, the rendering and displaying module 330 may be specifically configured to: after the local transition animation corresponding to the ground is rendered and displayed for a set number of frames, the local transition animation corresponding to the building and the sky respectively is rendered and displayed together.
Optionally, the apparatus for transition processing of panorama switching may further include an image segmentation module, configured to: acquiring panoramic images matched with the panoramic roaming scene; and identifying each scene element contained in each panoramic image, and dividing each panoramic image into a plurality of divided sub-images according to the identification result of the scene element.
Optionally, the image segmentation module may be specifically configured to: determining a horizon according to the ground identification position in the current panoramic image; identifying a ground type matched with the current panoramic image, and acquiring a rising angle and a falling angle matched with the ground type; respectively rotating the raising angle and the drooping angle in clockwise and counterclockwise directions by taking the horizontal line as a rotating edge and the central point of the horizontal line as a rotating vertex to obtain a raising edge in the clockwise direction, a raising edge in the counterclockwise direction, a drooping edge in the clockwise direction and a drooping edge in the counterclockwise direction; and according to the raising edge in the clockwise direction, the raising edge in the anticlockwise direction, the downward hanging edge in the clockwise direction and the downward hanging edge in the anticlockwise direction, obtaining segmentation subgraphs respectively corresponding to the ground, the building and the sky in the current panoramic image by segmentation.
The product can execute the method provided by any embodiment of the disclosure, and has corresponding functional modules and beneficial effects of the execution method.
In the technical scheme of the disclosure, the processes of collecting, storing, using, processing, transmitting, providing, disclosing and the like of the personal information of the related user all accord with the regulations of related laws and regulations, and do not violate the common customs of public order.
The present disclosure also provides an electronic device, a readable storage medium, and a computer program product according to embodiments of the present disclosure.
FIG. 6 illustrates a schematic block diagram of an example electronic device 400 that can be used to implement embodiments of the present disclosure. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the disclosure described and/or claimed herein.
As shown in fig. 6, the apparatus 400 includes a computing unit 401 that can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM) 402 or a computer program loaded from a storage unit 408 into a Random Access Memory (RAM) 403. In the RAM 403, various programs and data necessary for the operation of the device 400 can also be stored. The computing unit 401, ROM 402, and RAM 403 are connected to each other via a bus 404. An input/output (I/O) interface 405 is also connected to bus 404.
A number of components in device 400 are connected to I/O interface 405, including: an input unit 406 such as a keyboard, a mouse, or the like; an output unit 407 such as various types of displays, speakers, and the like; a storage unit 408 such as a magnetic disk, optical disk, or the like; and a communication unit 409 such as a network card, modem, wireless communication transceiver, etc. The communication unit 409 allows the device 400 to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunication networks.
Computing unit 401 may be a variety of general and/or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 401 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The calculation unit 401 executes the respective methods and processes described above, such as the method of transition processing of panorama switching. For example, in some embodiments, the method of transition handling of panorama switching may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 408. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device 400 via the ROM 402 and/or the communication unit 409. When the computer program is loaded into RAM 403 and executed by computing unit 401, one or more steps of the method of transition processing of panorama switching described above may be performed. Alternatively, in other embodiments, the computing unit 401 may be configured by any other suitable means (e.g., by means of firmware) as a method of performing the transition processing of the panorama switching.
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), Complex Programmable Logic Devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program code may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program code, when executed by the processor or controller, causes the functions/acts specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical host and VPS service are overcome. The server may also be a server of a distributed system, or a server incorporating a blockchain.
Artificial intelligence is the subject of research that makes computers simulate some human mental processes and intelligent behaviors (such as learning, reasoning, thinking, planning, etc.), both at the hardware level and at the software level. Artificial intelligence hardware technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing, and the like; the artificial intelligence software technology mainly comprises a computer vision technology, a voice recognition technology, a natural language processing technology, a machine learning/deep learning technology, a big data processing technology, a knowledge map technology and the like.
Cloud computing (cloud computing) refers to accessing an elastically extensible shared physical or virtual resource pool through a network, where resources may include servers, operating systems, networks, software, applications, storage devices, and the like, and may be a technical system that deploys and manages resources in a self-service manner as needed. Through the cloud computing technology, high-efficiency and strong data processing capacity can be provided for technical application and model training of artificial intelligence, block chains and the like.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in this disclosure may be performed in parallel or sequentially or in a different order, as long as the desired results of the technical solutions provided by this disclosure can be achieved, and are not limited herein.
The above detailed description should not be construed as limiting the scope of the disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present disclosure should be included in the scope of protection of the present disclosure.

Claims (19)

1. A method of transition handling of panorama switching, comprising:
acquiring a plurality of segmentation subgraphs corresponding to the current display panoramic image, wherein different segmentation subgraphs comprise scene elements with different scene depths;
generating local transition animations corresponding to the segmentation subgraphs according to the scene depth of the scene elements contained in the segmentation subgraphs;
and rendering and displaying each local transition animation according to the image position of each partition subgraph in the current display panoramic image so as to realize the transition of switching from the current display panoramic image to the next display panoramic image.
2. The method of claim 1, wherein obtaining a plurality of segmented sub-graphs corresponding to a currently exhibiting panoramic image comprises:
if a route dragging instruction aiming at the currently displayed panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation subgraphs corresponding to the currently displayed panoramic image; or
And if a selection instruction for setting an image position point in the current display panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation subgraphs corresponding to the current display panoramic image.
3. The method of claim 1, wherein generating the local transition animation corresponding to each of the segmented sub-graphs according to the scene depth of the scene element included in each of the segmented sub-graphs comprises:
determining motion rates respectively corresponding to the segmentation subgraphs according to the scene depth of scene elements contained in the segmentation subgraphs, wherein the scene depth and the motion rates are in an inverse proportion relation;
determining the number of transitional animation display frames according to the preset transitional animation duration and the preset frame interval;
and generating local transition animations corresponding to the segmentation subgraphs respectively according to the motion rate and the number of the transition animation display frames corresponding to the segmentation subgraphs respectively.
4. The method of claim 3, wherein generating the local transition animation corresponding to each of the segmented sub-graphs according to the motion rate and the number of the transition animation display frames corresponding to each of the segmented sub-graphs comprises:
acquiring a current processing segmentation subgraph;
calculating a stretching distance according to the motion rate corresponding to the current processing segmentation subgraph and the frame interval;
stretching the current processing segmentation subgraph according to the stretching distance, and adding the obtained stretching subgraph into an image set corresponding to the current processing segmentation subgraph;
after the stretched subgraph is taken as a new current processing segmentation subgraph, returning to execute the operation of stretching the current processing segmentation subgraph according to the stretching distance until the number of the images in the image set reaches the number of transition animation display frames;
and generating a local transition animation corresponding to the current processing segmentation subgraph according to the image set.
5. The method of any of claims 1-4, wherein the scene element comprises: ground, buildings, and sky;
the depth of the scene difference on the ground is smaller than that of the building, and the depth of the scene difference of the building is smaller than that of the sky.
6. The method of claim 5, wherein rendering and displaying the local transition animations according to the image position of each segmented sub-image in the current presentation panoramic image comprises:
after the local transition animation corresponding to the ground is rendered and displayed for a set number of frames, the local transition animation corresponding to the building and the sky respectively is rendered and displayed together.
7. The method of claim 5, further comprising:
acquiring panoramic images matched with the panoramic roaming scene;
and identifying each scene element contained in each panoramic image, and dividing each panoramic image into a plurality of divided sub-images according to the identification result of the scene element.
8. The method of claim 7, wherein identifying scene elements contained in each panoramic image and segmenting each panoramic image into a plurality of segmented sub-images according to the identification of the scene elements comprises:
determining a horizon according to the ground identification position in the current panoramic image;
identifying a ground type matched with the current panoramic image, and acquiring a rising angle and a falling angle matched with the ground type;
respectively rotating the raising angle and the drooping angle in clockwise and counterclockwise directions by taking the horizontal line as a rotating edge and the central point of the horizontal line as a rotating vertex to obtain a raising edge in the clockwise direction, a raising edge in the counterclockwise direction, a drooping edge in the clockwise direction and a drooping edge in the counterclockwise direction;
and according to the raising edge in the clockwise direction, the raising edge in the anticlockwise direction, the downward hanging edge in the clockwise direction and the downward hanging edge in the anticlockwise direction, obtaining segmentation subgraphs respectively corresponding to the ground, the building and the sky in the current panoramic image by segmentation.
9. An apparatus of transition handling of panorama switching, comprising:
the data acquisition module is used for acquiring a plurality of segmentation subgraphs corresponding to the current display panoramic image, wherein different segmentation subgraphs comprise scene elements with different scene depths;
the local transition module is used for generating local transition animations corresponding to the segmentation subgraphs according to the scene depth of the scene elements contained in the segmentation subgraphs;
and the rendering display module is used for rendering and displaying the local transition animations according to the image positions of the segmentation subgraphs in the current display panoramic image so as to realize the transition from the current display panoramic image to the next display panoramic image.
10. The apparatus according to claim 9, wherein the data acquisition module is specifically configured to: if a route dragging instruction aiming at the currently displayed panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation sub-images corresponding to the currently displayed panoramic image; or
And if a selection instruction for setting an image position point in the current display panoramic image is detected in the panoramic roaming scene, acquiring a plurality of segmentation subgraphs corresponding to the current display panoramic image.
11. The apparatus of claim 9, the local transition module comprising:
the motion rate determining unit is used for determining motion rates respectively corresponding to the segmentation subgraphs according to the scene depth of the scene element contained in each segmentation subgraph, and the scene depth and the motion rate are in an inverse proportion relation;
the display frame number determining unit is used for determining the display frame number of the transition animation according to the preset transition animation duration and the preset frame interval;
and the local transition animation generating unit is used for generating local transition animations respectively corresponding to the segmentation subgraphs according to the motion rate and the transition animation display frame number respectively corresponding to the segmentation subgraphs.
12. The apparatus according to claim 11, wherein the local transition animation generation unit is specifically configured to: acquiring a current processing segmentation subgraph; calculating a stretching distance according to the motion rate corresponding to the current processing segmentation subgraph and the frame interval; stretching the current processing segmentation subgraph according to the stretching distance, and adding the obtained stretched subgraph into an image set corresponding to the current processing segmentation subgraph; after the stretching subgraph is used as a new current processing segmentation subgraph, returning to execute the operation of stretching the current processing segmentation subgraph according to the stretching distance until the number of the images in the image set reaches the number of the display frames of the transition animation; and generating a local transition animation corresponding to the current processing segmentation subgraph according to the image set.
13. The apparatus of any of claims 9-12, the scene element comprising: ground, buildings and sky;
the landscape depth of the ground is smaller than that of the building, and the landscape depth of the building is smaller than that of the sky.
14. The apparatus of claim 13, the rendering display module being specifically configured to: after the local transition animation corresponding to the ground is rendered and displayed for a set number of frames, the local transition animation corresponding to the building and the sky respectively is rendered and displayed together.
15. The apparatus of claim 13, further comprising an image segmentation module to: acquiring panoramic images matched with the panoramic roaming scene;
and identifying each scene element contained in each panoramic image, and dividing each panoramic image into a plurality of divided sub-images according to the identification result of the scene element.
16. The apparatus of claim 15, the image segmentation module being specifically configured to:
determining a horizon according to the ground identification position in the current panoramic image;
identifying a ground type matched with the current panoramic image, and acquiring a rising angle and a falling angle matched with the ground type;
respectively rotating the raising angle and the drooping angle in clockwise and counterclockwise directions by taking the horizontal line as a rotating edge and the central point of the horizontal line as a rotating vertex to obtain a raising edge in the clockwise direction, a raising edge in the counterclockwise direction, a drooping edge in the clockwise direction and a drooping edge in the counterclockwise direction;
and according to the raising edge in the clockwise direction, the raising edge in the anticlockwise direction, the downward hanging edge in the clockwise direction and the downward hanging edge in the anticlockwise direction, segmenting the current panoramic image to obtain segmented sub-images respectively corresponding to the ground, the building and the sky.
17. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein, the first and the second end of the pipe are connected with each other,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-8.
18. A non-transitory computer readable storage medium having stored thereon computer instructions for causing a computer to perform the method of any one of claims 1-8.
19. A computer program product comprising a computer program which, when executed by a processor, carries out the steps of the method of any one of claims 1 to 8.
CN202211059470.6A 2022-08-30 2022-08-30 Transition processing method, device, equipment and medium for panoramic switching Active CN115131472B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211059470.6A CN115131472B (en) 2022-08-30 2022-08-30 Transition processing method, device, equipment and medium for panoramic switching

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211059470.6A CN115131472B (en) 2022-08-30 2022-08-30 Transition processing method, device, equipment and medium for panoramic switching

Publications (2)

Publication Number Publication Date
CN115131472A true CN115131472A (en) 2022-09-30
CN115131472B CN115131472B (en) 2022-12-02

Family

ID=83387026

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211059470.6A Active CN115131472B (en) 2022-08-30 2022-08-30 Transition processing method, device, equipment and medium for panoramic switching

Country Status (1)

Country Link
CN (1) CN115131472B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110032371A1 (en) * 2009-08-04 2011-02-10 Olympus Corporation Image capturing device
CN107633241A (en) * 2017-10-23 2018-01-26 三星电子(中国)研发中心 A kind of method and apparatus of panoramic video automatic marking and tracking object
CN112308948A (en) * 2020-09-30 2021-02-02 深圳市聚点数码科技有限公司郑州分公司 Construction method and application of light field roaming model for house property marketing
CN112634414A (en) * 2020-12-24 2021-04-09 北京百度网讯科技有限公司 Map display method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110032371A1 (en) * 2009-08-04 2011-02-10 Olympus Corporation Image capturing device
CN107633241A (en) * 2017-10-23 2018-01-26 三星电子(中国)研发中心 A kind of method and apparatus of panoramic video automatic marking and tracking object
CN112308948A (en) * 2020-09-30 2021-02-02 深圳市聚点数码科技有限公司郑州分公司 Construction method and application of light field roaming model for house property marketing
CN112634414A (en) * 2020-12-24 2021-04-09 北京百度网讯科技有限公司 Map display method and device

Also Published As

Publication number Publication date
CN115131472B (en) 2022-12-02

Similar Documents

Publication Publication Date Title
EP3951741A2 (en) Method for acquiring traffic state, relevant apparatus, roadside device and cloud control platform
CN112634414B (en) Map display method and device
CN113781631A (en) Mass point cloud data processing and visualization method and system
CN112529097B (en) Sample image generation method and device and electronic equipment
CN112714266B (en) Method and device for displaying labeling information, electronic equipment and storage medium
US20220375186A1 (en) Method and apparatus for generating bounding box, device and storage medium
CN114443794A (en) Data processing and map updating method, device, equipment and storage medium
CN113378834A (en) Object detection method, device, apparatus, storage medium, and program product
CN115439543A (en) Method for determining hole position and method for generating three-dimensional model in metauniverse
CN113378605B (en) Multi-source information fusion method and device, electronic equipment and storage medium
CN113011298A (en) Truncated object sample generation method, target detection method, road side equipment and cloud control platform
CN115830207B (en) Three-dimensional scene roaming method, device, equipment and medium
CN115423919B (en) Image rendering method, device, equipment and storage medium
CN115131472B (en) Transition processing method, device, equipment and medium for panoramic switching
US20230169680A1 (en) Beijing baidu netcom science technology co., ltd.
CN108280887B (en) Shadow map determination method and device
CN113920273B (en) Image processing method, device, electronic equipment and storage medium
CN113361519B (en) Target processing method, training method of target processing model and device thereof
CN116188587A (en) Positioning method and device and vehicle
CN115527028A (en) Map data processing method and device
CN113379750A (en) Semi-supervised learning method of semantic segmentation model, related device and product
CN116051925B (en) Training sample acquisition method, device, equipment and storage medium
CN113177545B (en) Target object detection method, target object detection device, electronic equipment and storage medium
CN116229209B (en) Training method of target model, target detection method and device
CN115328607B (en) Semiconductor device rendering method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant