Invention content
In view of above-mentioned, the present invention provides a kind of virtual scene interaction method and device, computer installation and readable storage medium
Matter promotes the interactive degree between each interaction end.
On the one hand the embodiment of the present invention provides a kind of virtual scene interaction method, applied to including at least the first interaction end
The virtual scene of image and the image of the second interaction end, the method includes:
The first image is obtained in real time using the image acquisition device of first interaction end, and the image of first interaction end is adopted
The visual angle of storage acquisition described first image is corresponding with the first virtual perspective in the virtual scene;And utilize described second
The image acquisition device of interaction end obtains the second image, the visual angle of second image and the second void in the virtual scene in real time
It is corresponding to intend visual angle;Wherein, it is consistent with the initial time of acquisition second image to obtain described first image;
First virtual perspective is updated to by second interaction end and/or with the associated object of the second interaction end
Under virtual scene in;And it is updated to described by first interaction end and/or with the associated object of the first interaction end
In virtual scene under two virtual perspectives.
Further, the method further includes:
If described first image includes the image of second interaction end and/or associated right with second interaction end
The image of elephant, then with predetermined manner extract described first image in second interaction end and/or with second interaction end
Associated object;
If second image include first interaction end and/or with the associated object of the first interaction end,
With predetermined manner extract first interaction end in second image and/or with the associated object of the first interaction end.
Further, the predetermined manner includes:
The mode taken based on Chroma Key technology progress image;And/or
The mode that image takes is carried out to the image section where organism based on organism identification technology.
Further, the method further includes:
It is obtained in real time using the image acquisition device for producing end and includes first interaction end and/or second interaction end
Third image, the third that the image acquisition device at the production end is acquired in the visual angle and virtual scene of the third image virtually regard
Angle is corresponding, and first virtual perspective, second virtual perspective and the third virtual perspective are different.
Further, the method further includes:
Described first image, second image and the third image are output to predetermined server;
It is respectively described first image, second image and third image distribution phase using the predetermined server
The view identifier answered.
Further, the method further includes:
The first sound is obtained in real time using the sound collector of first interaction end, utilizes the sound of second interaction end
Sound collector obtains second sound in real time;
First sound and the second sound are exported to predetermined server, and first sound with it is updated
Virtual scene under first virtual perspective matches, under the second sound and updated second virtual perspective
Virtual scene matches.
Another aspect of the present invention provides a kind of virtual scene interaction device, applied to the image including at least the first interaction end
With the virtual scene of the image of the second interaction end, described device includes:
Acquisition module, for using first interaction end image acquisition device in real time obtain the first image, described first
The visual angle of the image acquisition device acquisition described first image of interaction end is corresponding with the first virtual perspective in the virtual scene;
And obtain the second image in real time using the image acquisition device of second interaction end, the visual angle of second image with it is described virtual
The second virtual perspective in scene is corresponding;Wherein, described first image is obtained with obtaining the initial time of second image
It is consistent;
Update module, for being updated to institute by second interaction end and/or with the associated object of the second interaction end
It states in the virtual scene under the first virtual perspective;And by first interaction end and/or with first interaction end it is associated right
As being updated in the virtual scene under second virtual perspective.
Further, described device further includes:
Extraction module, for the image that includes second interaction end in described first image and/or with described second
During the image of the associated object of interaction end, with predetermined manner extract described first image in second interaction end and/or with
The associated object of second interaction end;
When second image includes first interaction end and/or object associated with first interaction end,
With predetermined manner extract first interaction end in second image and/or with the associated object of the first interaction end.
Another further aspect of the embodiment of the present invention provides a kind of computer installation, and the computer installation includes processor, described
The step of processor when performing the computer program stored in memory for realizing virtual scene interaction method as described above.
The another aspect of the embodiment of the present invention provides a kind of computer readable storage medium, is stored thereon with computer program,
The computer program realizes the step of virtual scene interaction method as described above when being executed by processor.
Virtual scene interaction method and device provided by the invention, computer installation and computer readable storage medium, will
It the image of second interaction end and/or is updated under first virtual perspective with the associated object of the second interaction end
In virtual scene;And it is updated to second void by first interaction end and/or with the associated object of the first interaction end
Intend in the virtual scene under visual angle, corresponding user can see other side in virtual scene, so that each interaction end can be
It is interacted in virtual scene, promotes the interactive degree between each interaction end.Using the image information expression of virtual scene, can give
User brings good interactive experience, and is conducive to deepen the eye impressions of user, based on this, can be provided present embodiment
Virtual scene interaction method be applied to video teaching in, further deepen student study impression.
Further, virtual scene interaction method provided by the invention can be utilized respectively the first interaction end and the second interaction end
On image acquisition device obtain the image at corresponding visual angle, and the first image got in the first interaction end includes second and interacts
When the image at end and/or image with the associated object of the second interaction end, by the image of second interaction end and/or with second
The image zooming-out of the associated object of interaction end comes out, and the virtual scene under the image update extracted to the first virtual perspective
In;The second image that the second interaction end is got include the image of the first interaction end and/or with the first interaction end it is associated
During the image of object, come out by the image of first interaction end and/or with the image zooming-out of the associated object of the first interaction end,
And by the virtual scene under the image update extracted to the second virtual perspective, the first interaction end and the equal energy of the second interaction end
Seen in virtual scene other side and/or with the associated object of other side so that the two can obtain more in virtual scene
Good interactive experience.
Specific embodiment
It is to better understand the objects, features and advantages of the present invention, below in conjunction with the accompanying drawings and specific real
Applying mode, the present invention will be described in detail.It should be noted that in the absence of conflict, presently filed embodiment and reality
Applying the feature in mode can be combined with each other.
Many details are elaborated in the following description to facilitate a thorough understanding of the present invention, described embodiment
The only embodiment of a part of embodiment of the invention rather than whole.Based on the embodiment in the present invention, this field
The every other embodiment that those of ordinary skill is obtained without making creative work, belongs to guarantor of the present invention
The range of shield.
Unless otherwise defined, all of technologies and scientific terms used here by the article is with belonging to technical field of the invention
The normally understood meaning of technical staff is identical.Term used in the description of the invention herein is intended merely to description tool
The purpose of the embodiment of body, it is not intended that in the limitation present invention.
Fig. 1 is the flow chart of the virtual scene interaction method of first embodiment of the invention, it should be noted that the present invention is real
The virtual scene interaction method for applying mode is not limited to step and sequence in flow chart shown in FIG. 1.According to different
Demand, the step in shown flow chart can increase, remove or change sequence.
As shown in Figure 1, the virtual scene interaction method of present embodiment, applied to the image including at least the first interaction end
With the virtual scene of the image of the second interaction end, may include steps of:
Step 101:The first image, first interaction end are obtained in real time using the image acquisition device of first interaction end
Image acquisition device acquisition described first image visual angle it is corresponding with the first virtual perspective in the virtual scene;And it utilizes
The image acquisition device of second interaction end obtains the second image in real time, the visual angle of second image in the virtual scene
The second virtual perspective it is corresponding;Wherein, it is consistent with the initial time of acquisition second image to obtain described first image.
In present embodiment, first interaction end and the second interaction end can be worn the people of relevant device or set
For itself.
It is understood that the equipment can be head-mounted display apparatus.
In present embodiment, described image collector can be the one or more in the first interaction end and the second interaction end
Camera.
In present embodiment, described first image and second image are a certain frame figure in the video for implementing to obtain
Picture or multiple image.
In present embodiment, the visual angle of the image acquisition device acquisition described first image of first interaction end and the void
The first virtual perspective intended in scene is corresponding, i.e., the image acquisition device acquisition described first image of described first interaction end regards
Angle has certain default incidence relation with first visual angle, and the default incidence relation can be that visual angle is consistent, also may be used
To be the visual angle difference with preset range.
It is understood that when the default incidence relation is that visual angle is consistent, the visual angle change of the first interaction end and
Amplitude of variation can be in virtual scene the first virtual perspective visual angle change and amplitude of variation embody, be suitable for user and exist
Visual experience in daily, conducive to feeling of immersion of the enhancing user in virtual scene.
It is understood that when the default incidence relation is the visual angle difference with preset range, the visual angle is utilized
Difference can provide more easily viewing experience to the user, as user's head rotates 60 degree, you can browse 120 degree in virtual scene
Visual angle change.
In present embodiment, the described first image that obtains is consistent with the initial time of acquisition second image,
It is identical in the time for obtaining corresponding specified image to limit the first interaction end and the second interaction end, and non-limiting first interaction end
Image acquisition device opening time it is identical with the opening time of the image acquisition device of the second interaction end.
It is understood that the specified image includes the second interaction end for image to be taken namely the first image
Image and/or the image with the associated object of the second interaction end, the second image include the first interaction end image and/or
With the image of the associated object of the first interaction end.
It is understood that first interaction end and the quantity of the second interaction end and non-limiting interaction end, visual specific
It needs to increase corresponding interaction end to realize the mutual interaction between multiple interaction ends.
It is understood that described can be according to the characteristic relation pre-established with the associated object of the first interaction end
Table in conjunction with image recognition technology in favor of realizing accurately stingy picture, has related stage property in the characteristic relation table such as pre-established
Characteristic, image acquisition device the image collected is identified using it, when including and the in the image collected
During the associated object of one interaction end (the related stage property), it can be taken out together, to be merged with virtual scene, so as to
It is advantageously implemented actual situation interaction more true to nature.
Step 102:Institute is updated to by the image of second interaction end and/or with the associated object of the second interaction end
It states in the virtual scene under the first virtual perspective;And by first interaction end and/or with first interaction end it is associated right
As being updated in the virtual scene under second virtual perspective.
In present embodiment, by the image of second interaction end and/or with the associated object of the second interaction end more
In the new virtual scene under first virtual perspective;And it is closed by first interaction end and/or with first interaction end
The object of connection is updated in the virtual scene under second virtual perspective, and corresponding user can see pair in virtual scene
Side, so that each interaction end can interact in virtual scene, promotes the interactive degree between each interaction end.Utilize void
Intend the image information expression of scene, good interactive experience can be brought to user, and be conducive to deepen the eye impressions of user, base
In this, the virtual scene interaction method that present embodiment is provided can be applied in video teaching, further deepen student's
Learn impression.Similarly, virtual scene interaction side present embodiment provided be applied to scene of game in, can reality in it is true
Real player carries out interaction more true to nature in virtual scene, promotes the Experience Degree of game.
It is understood that can be additionally used in living broadcast interactive, by the visual angle change in virtual scene can realize main broadcaster with
The interaction of spectators.
Fig. 2 is the flow chart of the virtual scene interaction method of second embodiment of the invention, and present embodiment is real with first
The main distinction for applying mode is, the extraction of picture material involved in second embodiment and etc..It should be noted that at this
In the range of the spirit or essential attributes of invention, each concrete scheme suitable for first embodiment can also be applicable in accordingly
In second embodiment, for the sake of saving space and avoiding repetition, details are not described herein again.
As shown in Fig. 2, the virtual scene interaction method may include steps of:
Step 201:The first image, first interaction end are obtained in real time using the image acquisition device of first interaction end
Image acquisition device acquisition described first image visual angle it is corresponding with the first virtual perspective in the virtual scene;And it utilizes
The image acquisition device of second interaction end obtains the second image in real time, the visual angle of second image in the virtual scene
The second virtual perspective it is corresponding.
Step 202:If described first image include second interaction end image and/or with second interaction end
The image of associated object then extracts second interaction end in described first image and/or with described the with predetermined manner
The associated object of two interaction ends;If second image includes first interaction end and/or is closed with first interaction end
The object of connection, then with predetermined manner extract first interaction end in second image and/or with first interaction end
Associated object.
In present embodiment, include the image of the second interaction end in the picture material of the first image and/or interacted with second
When holding the image of associated object, that is, show that there are the second friendships in the visual angle of the image acquisition device acquisition image of the first interaction end
Mutually end and/or with the associated object of the second interaction end, thus, will second interaction end or and/or with described second friendship
The image zooming-out corresponding to associated object is mutually held to come out, is prepared with the update for virtual scene.
In present embodiment, similarly, include the image and/or second of the first interaction end in the picture material of the second image
During the image of the associated object of interaction end, that is, show the second interaction end image acquisition device acquisition image visual angle in there are first
Interaction end and/or with the associated object of the first interaction end, thus, by first interaction end and/or with described first hand over
The image zooming-out corresponding to associated object is mutually held to come out, is prepared with the update for virtual scene.
In present embodiment, the predetermined manner may include following extracting mode:
The mode taken based on Chroma Key technology progress image;And/or
The mode that image takes is carried out to the image section where organism based on organism identification technology.
It is understood that the Chroma Key technology can carry out the target object image in blue or green background
What is taken is stingy as technology.
It is understood that the organism identification technology can utilize skeleton algorithm or face recognition algorithms to people
Or the stingy picture technology that the image of the privileged site of people is taken.
It is understood that the extraction step can be complete in the first interaction end and the respective processor of the second interaction end
Into the second image that the first image and second interaction end that can also obtain first interaction end obtain is sent to specified
Processor in complete extraction.
It is understood that after completing to obtain scratching the target image of picture, the edge of target image can be carried out at correlation
Reason, in favor of by target image it is more natural merged with virtual scene.
Step 203:Described first is updated to by second interaction end and/or with the associated object of the second interaction end
In virtual scene under virtual perspective;And first interaction end and/or object associated with first interaction end are updated
In virtual scene under to second virtual perspective.
In present embodiment, the image acquisition device being utilized respectively in the first interaction end and the second interaction end obtains corresponding visual angle
Image, and the first image got in the first interaction end include the second interaction end image and/or with the second interaction end
During the image of associated object, carried by the image of second interaction end and/or with the image of the associated object of the second interaction end
It takes out, and in the virtual scene under the image update extracted to the first virtual perspective;Got in the second interaction end
When two images include the image of the first interaction end and/or image with the associated object of the first interaction end, described first is handed over
It the image mutually held and/or is come out, and by the image update extracted extremely with the image zooming-out of the associated object of the first interaction end
In virtual scene under second virtual perspective, the first interaction end and the second interaction end can be seen in virtual scene other side and/
Or with the associated object of other side so that the two can obtain more preferably interactive experience in virtual scene.
In present embodiment, in addition to above the first interaction end and the second interaction end, the present invention may also include production end,
Obtain the third figure for including first interaction end and/or second interaction end in real time using the image acquisition device at production end
Picture, the visual angle of the image acquisition device acquisition third image at the production end are opposite with the third virtual perspective in virtual scene
Should, and first virtual perspective, second virtual perspective and the third virtual perspective are different.
It is understood that it can will produce the collected image zooming-out including the first interaction end and the second interaction end in end
It is worth in virtual scene, available for video display, can be conducive to carry out teaching demonstration, such as chemical experiment teaching and bioconversion medium, image
Vividly, increase the interest of teaching, student can also be avoided to do, and there are the danger that the experiment of certain security risk is brought.
It it is understood that can also be by the described first image acquired, second image and the third image
Predetermined server is output to, is respectively described first image, second image and described using the predetermined server thereafter
Third image distributes corresponding view identifier, image that can be according to corresponding to corresponding view identifier selects corresponding visual angle,
The demand watched with the image for meeting the selection certain viewing angles of spectators.
It is understood that while corresponding image is obtained using the first interaction end, the second interaction end and production end,
The first sound is also obtained in real time using the sound collector of first interaction end, is adopted using the sound of second interaction end
Storage obtains second sound in real time.
Thereafter, first sound and the second sound are exported to predetermined server, and first sound with more
The virtual scene under first virtual perspective after new matches, and the second sound is virtually regarded with updated described second
Virtual scene under angle matches.More preferably interactive experience and sensory experience can be provided to user or spectators as a result,.
It is understood that in the first interaction end of the present invention, the second interaction end and in producing the concrete application at end,
Can also corresponding landing program be set to each equipment, to verify the user using above equipment, promote the safety of program operation
Property.
Fig. 3 is the illustrative functional block diagram of the virtual scene interaction device of an embodiment of the present invention.Such as Fig. 3 institutes
Show, virtual scene interaction device 100 can by the image of second interaction end and/or with the associated object of the second interaction end
It is updated in the virtual scene under first virtual perspective;And by first interaction end and/or with first interaction end
Associated object is updated in the virtual scene under second virtual perspective, and corresponding user can see pair in virtual scene
Side, so that each interaction end can interact in virtual scene, promotes the interactive degree between each interaction end.Utilize void
Intend the image information expression of scene, good interactive experience can be brought to user, and be conducive to deepen the eye impressions of user, base
In this, the virtual scene interaction device that present embodiment is provided can be applied in video teaching.
The virtual scene interaction device 100 of the present invention can include one or more modules, one or more of modules
Can be stored in the memory of terminal and may be configured to by one or more processors (present embodiment be one
Manage device) it performs, to complete the present invention.For example, as shown in figure 3, the virtual scene interaction device 100 can include acquisition module
11st, update module 12, extraction module 13, output module 14 and distribution module 15.The so-called module of the present invention can be completion one
The program segment of specific function, than implementation procedure of the program more suitable for description software in the processor.
It should be noted that each embodiment of corresponding above-mentioned virtual scene interaction method, virtual scene interaction device 100
It can include part or all in each function module shown in Fig. 3, the function of each module will introduced in detail below.With
Identical noun related terms and its specific illustrate can also fit in each embodiment of upper virtual scene interaction method
For below to the function introduction of each module.For the sake of saving space and avoiding repetition, details are not described herein again.
Fig. 4 is the illustrative structure diagram of the computer installation of an embodiment of the present invention.It is provided in this embodiment
Computer installation 1 includes:It processor 10, memory 20, image acquisition device 30 and is stored in the memory 20 and can be
The computer program run on the processor 10, such as virtual scene interaction program.The processor 10 performs the computer
During program, the step in above-mentioned each virtual scene interaction method embodiment is realized, such as step 101 shown in FIG. 1 is to step
Rapid 102.Alternatively, the processor 10 realizes the function of each module in above device embodiment when performing the computer program,
Such as it is realized such as the acquisition module 11 in Fig. 3 and obtains the first image, institute in real time using the image acquisition device of first interaction end
The visual angle for stating the image acquisition device acquisition described first image of the first interaction end and the first virtual perspective in the virtual scene
It is corresponding;And using second interaction end image acquisition device in real time obtain the second image, the visual angle of second image with
The corresponding function of the second virtual perspective in the virtual scene.
The computer installation 1 can be that the calculating such as desktop PC, notebook, palm PC and cloud server are set
It is standby.The computer installation 1 may include, but be not limited to, processor 10, memory 20 and image acquisition device 30.Art technology
Personnel are appreciated that the schematic diagram is only showing for the computer installation 1 that the present invention is used to implement virtual scene interaction method
Example, does not form the restriction to computer installation 1, can include than illustrating more or fewer components or combining certain portions
Part or different components, such as the computer installation 1 can also include input-output equipment, network access equipment, bus
Deng.
Alleged processor 10 can be central processing unit (Central Processing Unit, CPU), can also be
Other general processors, digital signal processor (Digital Signal Processor, DSP), application-specific integrated circuit
(Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field-
Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic,
Discrete hardware components etc..General processor can be microprocessor or the processor can also be any conventional processor
Deng the processor 10 is the control centre of the computer installation 1, utilizes various interfaces and connection entire computer dress
Put 1 various pieces.
The memory 20 can be used for storing the computer program and/or module, the processor 10 by operation or
It performs the computer program being stored in the memory 20 and/or module and calls the data being stored in memory 20,
Realize the various functions of the computer installation 1.The memory 20 can mainly include storing program area and storage data field,
In, storing program area can storage program area, application program (such as sound-playing function, image needed at least one function
Playing function etc.) etc..In addition, memory 20 can include high-speed random access memory, non-volatile memories can also be included
Device, such as hard disk, memory, plug-in type hard disk, intelligent memory card (Smart Media Card, SMC), secure digital (Secure
Digital, SD) card, flash card (Flash Card), at least one disk memory, flush memory device or other volatibility are consolidated
State memory device.
The computer installation 1 may also include virtual scene interaction device 100 as shown in Figure 3, and the virtual scene is handed over
Mutual device 100 can be stored in the memory 20.
Illustratively, the computer program can be divided into one or more modules, one or more of moulds
Block is stored in the memory 20, and is performed by the processor 10, to complete the present invention.One or more of modules
Can be the series of computation machine program instruction section that can complete specific function, which is used to describe the computer program
Implementation procedure in the computer installation 1.For example, the computer program can be divided into it is as shown in Figure 3 virtual
Scene interactivity device 100, including acquisition module 11, update module 12, extraction module 13, output module 14 and distribution module 15,
Each module concrete function is as follows:
Acquisition module 11 obtains the first image in real time available for the image acquisition device using first interaction end, described
The visual angle of the image acquisition device acquisition described first image of first interaction end and the first virtual perspective phase in the virtual scene
It is corresponding;And the second image, the visual angle of second image and institute are obtained in real time using the image acquisition device of second interaction end
The second virtual perspective stated in virtual scene is corresponding;Wherein, described first image is obtained with obtaining rising for second image
Time beginning is consistent.
Update module 12, available for second interaction end and/or object associated with second interaction end are updated
In virtual scene under to first virtual perspective;And it is associated with by first interaction end and/or with first interaction end
Object be updated in the virtual scene under second virtual perspective.
Extraction module 13, available for include in described first image second interaction end image and/or with it is described
During the image of the associated object of the second interaction end, with predetermined manner extract described first image in second interaction end and/
Or with the associated object of the second interaction end;Include first interaction end and/or with described in second image
During the associated object of one interaction end, with predetermined manner extract first interaction end in second image and/or with it is described
The associated object of first interaction end.
Output module 14, it is default available for described first image, second image and the third image are output to
Server.
Distribution module 15, available for using the predetermined server be respectively described first image, second image and
The third image distributes corresponding view identifier.
If the integrated module of computer installation 1 of the present invention is realized in the form of SFU software functional unit and as independently
Product sale or in use, can be stored in a computer read/write memory medium.Based on such understanding, the present invention
It realizes all or part of flow in above-described embodiment method, relevant hardware can also be instructed by computer program come complete
Into the computer program can be stored in a computer readable storage medium, which is being executed by processor
When, it can be achieved that the step of above-mentioned each embodiment of the method.Wherein, the computer program includes computer program code, described
Computer program code can be source code form, object identification code form, executable file or certain intermediate forms etc..The meter
Calculation machine readable medium can include:Can carry the computer program code any entity or device, recording medium, USB flash disk,
Mobile hard disk, magnetic disc, CD, computer storage, read-only memory (ROM, Read-Only Memory), random access memory
Device (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium etc..Need what is illustrated
It is that the content that the computer-readable medium includes can be fitted according to legislation in jurisdiction and the requirement of patent practice
When increase and decrease, such as in certain jurisdictions, according to legislation and patent practice, computer-readable medium, which does not include electric carrier wave, to be believed
Number and telecommunication signal.
It is obvious to a person skilled in the art that the present invention is not limited to the details of above-mentioned exemplary embodiment, Er Qie
In the case of without departing substantially from spirit or essential attributes of the invention, the present invention can be realized in other specific forms.Therefore, no matter
From the point of view of which point, the present embodiments are to be considered as illustrative and not restrictive, and the scope of the present invention is by appended power
Profit requirement rather than above description limit, it is intended that all by what is fallen within the meaning and scope of the equivalent requirements of the claims
Variation includes within the present invention.Any reference numeral in claim should not be considered as to the involved claim of limitation.This
Outside, it is clear that one word of " comprising " is not excluded for other units or step, and odd number is not excluded for plural number.System, device or terminal installation right
Multiple units, module or the device stated in it is required that can also pass through software or hardware by same unit, module or device
To realize.The first, the second grade words are used to indicate names, and are not represented any particular order.
Embodiment of above is merely illustrative of the technical solution of the present invention and unrestricted, although with reference to above preferable embodiment party
The present invention is described in detail in formula, it will be understood by those of ordinary skill in the art that, it can be to technical scheme of the present invention
It modifies or equivalent replacement should not all be detached from the spirit and scope of technical solution of the present invention.