CN106445517A - Naked eye 3D interactive method based on Android device - Google Patents
Naked eye 3D interactive method based on Android device Download PDFInfo
- Publication number
- CN106445517A CN106445517A CN201610841052.0A CN201610841052A CN106445517A CN 106445517 A CN106445517 A CN 106445517A CN 201610841052 A CN201610841052 A CN 201610841052A CN 106445517 A CN106445517 A CN 106445517A
- Authority
- CN
- China
- Prior art keywords
- scene
- bore hole
- interactive
- display
- android device
- 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.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/30—Creation or generation of source code
- G06F8/38—Creation or generation of source code for implementing user interfaces
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T15/00—3D [Three Dimensional] image rendering
- G06T15/005—General purpose rendering architectures
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N13/00—Stereoscopic video systems; Multi-view video systems; Details thereof
- H04N13/30—Image reproducers
- H04N13/302—Image reproducers for viewing without the aid of special glasses, i.e. using autostereoscopic displays
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Computer Graphics (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Processing Or Creating Images (AREA)
Abstract
The invention discloses a naked eye 3D interactive method based on an Android device. The method comprises the following steps that 1, importing a TNet plug-in into a development engine; 2, calling relative interfaces of the TNet plug-in to achieve network communication; 3, creating an interactive naked eye 3D displaying scene; 4, assigning different ID values to different interactive objects utilizing the TNet plug-in; 5, compiling the scene content and releasing an executable file of a PC port; 6, modifying the interactive 3D displaying scene to an interactive 2D displaying scene; 7, compiling the interactive 2D displaying scene to release an APK file, and installing the file to the Android device; 8, connecting the PC port to a naked eye 3D display terminal, and at the same time connecting the PC port and the Android device to the same local area network; 9, operating the executable file, creating a new IP address on the Android device and connecting the PC port to the same IP address respectively; 10, performing interactive operation of the 2D scene on the Android device, responding to the same naked eye 3D interactive operation on the naked eye 3D display terminal. The naked eye 3D interactive method fills in the blank of the interactive naked eye 3D display control field.
Description
Technical field
The present invention relates to bore hole 3D interacts field, more particularly, to a kind of bore hole 3D exchange method based on Android device.
Background technology
The development of science and technology is never halted, and the renewal speed of electronic product is also to make people too plenty for the eye to take it all in.2010 with
Film《A Fanda》Show the sensational effect causing, 3D Display Technique is known and pursues, and has led the new of film industry
Trend.Meanwhile, be also unwilling to be outshone in consumption appliance field, numerous brands released one after another oneself 3D computer monitor, throwing
Shadow machine or LCD TV.The application of current 3D technology is seen, either cinematographic work or household appliances have one common
Feature exactly must be worn professional glasses and could be used.However, wearing eyes viewing for a long time easily cause dizziness, nausea etc. no
Good symptom, severe patient also can deteriorated vision, meanwhile, have bathomorphic spectators to be even more because wearing the inconvenience that " dual " glasses are brought
Suffer untold misery.Therefore, current spectacle 3D technology only as the developing transitional product of 3D technology, and the most at last by bore hole
3D Display Technique is replaced.
Chinese patent CN105263015A (number of patent application:201510704456.0, denomination of invention:A kind of Android sets
The standby method controlling bore hole 3D video to show) disclose a kind of method that Android device controls bore hole 3D video to show;The party
Method relevant interface of calling communication plug-in unit first in exploitation engine realizes the real-time Communication for Power at Android device end and PC end, so
Realize bore hole 3D afterwards in the scene to show, and create different response buttons for responding the display of different bore hole 3D videos,
Android device end points hit different response buttons realize bore hole 3D display terminal difference bore hole 3D video content show, realization
Android device controls the method that bore hole 3D video shows.Although it is difficult that the method can effectively solve bore hole 3D video content
To regulate and control, based on different hardware condition, fabrication cycle is long again, and the problems such as high cost, but it is difficult still to there is interactive bore hole 3D display
Problem with regulation and control.Chinese patent CN104702936A (number of patent application:201510144851.8, denomination of invention:One kind is based on
The virtual reality exchange method that bore hole 3D shows) disclose and create multiple stage stereoscopic camera carrying out in virtual reality interaction scenarios
Arrangement;What the rendering pinup picture with the viewpoint sub-pixel mapping matrix calculating and be programmed in of every stereoscopic camera output was run on GPU
Color device Shader is sampled and fusion treatment, obtains composograph, is then output to new display floater in scene, afterwards will
PC end connects bore hole 3D display terminal, and bore hole 3D display terminal shows stereo-picture;Finally carry out virtual reality interaction at PC end
The interactive operation of scene, completes the synchronous stereo display of interactive operation in bore hole 3D display terminal.Still there is interaction in the method
Formula bore hole 3D shows the problem being difficult to regulate and control.
Bore hole 3D Display Technique be need not wear any auxiliary equipment (as 3D glasses, helmet etc.) in the case of, by light
The advanced optical technology such as post lens can allow spectators' acquisition unprecedented " high true with the video film source of particular algorithm customization
Degree " visual experience, is a kind of new image display technology.Bore hole 3D Display Technique is propulsion industrialization and informationization simultaneously
One of electromotor that " two changes " merges, is also industrial quarters simultaneously and industrial creative industry is wide variety of basic, strategic
Tool technique.By bore hole 3D science and technology intention, some traditional industries are expected to accelerate industrial upgrading and innovation paces, and such as advertisement passes
Matchmaker, display and demonstration, research and teaching, Entertainment, industrial design, geological mapping, medical consultations, military affairs, scene rebuilding etc. are multiple
Industry.
However, the final developing direction of bore hole 3D Display Technique is interactive bore hole 3D showing, interactive bore hole at this stage
3D Display Technique immaturity, market a kind of good mode do not occur to debug, and control interactive bore hole 3D to show, sternly
The development hindering bore hole 3D Display Technique of weight, if be capable of a kind of bore hole 3D interaction side based on Android device
Method, just can efficiently debug, and control interactive bore hole 3D to show, filled up the blank in interactive bore hole 3D display control field,
Greatly extend the application of bore hole 3D Display Technique, the development of promotion bore hole 3D Display Technique that can be good.
Content of the invention
Part in view of the shortcomings of the prior art, it is an object of the invention to provide a kind of based on Android device
Bore hole 3D exchange method, the method can efficiently solve interactive bore hole 3D and show the problem being difficult to regulate and control, and filled up interaction
The blank in formula bore hole 3D display control field, greatly extends the application of bore hole 3D Display Technique, notable promotion bore hole 3D
The development of Display Technique.
The purpose of the present invention is achieved through the following technical solutions:
A kind of bore hole 3D exchange method based on Android device, its method and step is as follows:
A, by TNet plug-in unit import exploitation engine;
B, the relevant interface of TNet plug-in unit is called to realize network service;
C, establishment interactive bore hole 3D display scene;
D, with TNet plug-in unit give distinct interaction object difference ID value;
E, compile scene content and issue the executable file at PC end;
F, modification interactive bore hole 3D display scene are interactive 2D display scene, keep ID value not change;
G, compiling interactive 2D display scene are issued APK file, and are installed to Android device end;
H, PC end is connected to bore hole 3D display terminal, is simultaneously connected with PC end, Android device end to same LAN;
I, it is separately operable executable file, the newly-built IP address in Android device end, PC end is connected to identical ip addresses;
J, carry out the interactive operation of 2D scene at Android device end, bore hole 3D display terminal responds identical bore hole 3D
Interactive action.
In order to the present invention is better achieved, the preferred technology of bore hole 3D exchange method based on Android device for the present invention
Method is as follows, and its method and step is as follows:
A, by TNet plug-in unit import exploitation engine;TNet plug-in unit, as the plug-in unit encapsulating TCP or http network agreement, makes
Realize network communicating function with this plug-in unit and without too many workload, its function fully meets Android device end and PC
Network communicating function between end;
The relevant interface of the TNet plug-in unit in B, invocation step A realizes network service;Create new field in exploitation engine
Scape, creates video camera in new scene, the code file calling the relevant interface of TNet plug-in unit is hung on virtual camera, preserves
Scene is Communication;
C, establishment interactive bore hole 3D display scene;Create interactive bore hole 3D display scene mainly to divide in exploitation engine
For following two modules:Scene module and display module;Scene module mainly includes bore hole function and interactive function, and shows mould
Block mainly comprises display function;
The implementation of scene module bore hole function is as follows:In eight virtual cameras of Scene window creation of exploitation engine,
And the coordinate Position of all virtual cameras is set to (0,0,0), anglec of rotation Rotation is set to (0,0,0), chi
Very little size Scale is set to (1,1,1);Then adjust the distance between every camera and be spaced apart 0.017, belong in Layer simultaneously
Property in add new layer PlaySence, the rejecting shade Culling Mask attribute of eight video cameras of modification is PlaySence,
The dead ahead of eight virtual cameras creates zero plane ZeroPlane, and arranges its coordinate Position and be set to (0,0,10), rotation
Gyration Rotation is set to (270,0,0), and size Scale is set to (1,1,1), changes its attribute and is hidden,
Write associated script and realize the central point that eight video cameras focus on zero plane;Then create 8 in Project and render pinup picture
RenderTexture, the Size rendering pinup picture is revised as 1920 × 1080, in the Target Texture of every virtual camera
Give in attribute and different render pinup picture so that corresponding one of every video camera renders pinup picture;Then calculate viewpoint sub-pixel
Mapping matrix, and write corresponding Shader, sampling processing is carried out to the pinup picture that every camera renders, specific calculation is such as
Under:First, determine on 2D display screen that given RGB sub-pixel should take from the RGB component of which viewpoint, given below regard more
The computing formula of idea pixel-map matrix:
Wherein, X is the number that screen periods cover RGB sub-pixel in the horizontal direction, and (k, 1) is RGB sub-pixel
Coordinate position, a be grating axle with respect to LCD display vertical axises slanted angle, koffRepresent 2D display screen left edge with
The horizontal displacement of raster unit marginal point, NtotRepresent total viewpoint number, that is, participate in the anaglyph quantity synthesizing;
Which width anaglyph should be taken from according to the gray value that above formula can calculate each sub-pixel on 2D display screen
Corresponding coordinate position gray value;Then viewpoint mapping matrix is programmed in Shader, using Shader, camera is rendered
Multiple render the sampling processing that pinup picture carries out sub-pixel, and multiple anaglyphs through sampling processing are overlapped mutually, obtain
To final composograph;
The implementation of scene module interactive function is as follows:Add various interactive objects in the scene, and its Layer is belonged to
Property in be all modified to PlaySence, then in Project create CS script, modification script name be Play, write script
Realize different interactive actions, interactive action includes rotation, mobile or scaling, and script is hung over the friendship corresponding action
Mutually on object, then create CS script again, modification script name is TouchHandle, writes script and realizes ray detection work(
Can, and script is hung over one of virtual video camera, the attribute of modification virtual video camera is Main Camera;
The implementation of display module display function is as follows:Create new virtual camera and display floater, adjust virtualphase
The coordinate Position of machine is set to (- 5,0,100), and anglec of rotation Rotation is set to (0,90,0), size Scale
It is set to (1,1,1), Layer attribute adds new layer ShowSence, the rejecting shade Culling of eight video cameras of modification
Mask attribute is ShowSence, and changed shooting mode is orthogonal formula simultaneously, and camera angle is adjusted to 27, has changed depth
Depth is 1, and newly-built camera is defaulted as 0;Then the coordinate Position of adjustment display floater is set to (0,0,100), the anglec of rotation
Degree Rotation is set to (90, -90,0), and size Scale is set to (9.6,1,5.4), mates the aobvious of 1080P resolution
Show terminal;Its Layer attribute modification is ShowSence, creates material ball Material in display floater, by material simultaneously
The custom option of ball calls shader to obtain composograph, and composograph is presented on display floater;Finally, preserve to enter the court
Scape is Play;
D, with TNet plug-in unit give distinct interaction object difference ID value;Call the relevant interface of TNet plug-in unit, change it
Telescript, ID value is set to public ownership variable, and Telescript is hung on distinct interaction object, and gives different ID
Value;The ID value giving the first interaction object is 1, and the ID value of the second interaction object is 2, by that analogy;
E, compile scene content and issue the executable file at PC end;Click on the Build under exploitation engine File menu
Settings, and two above scene is put into Scenes In Build option hurdle, and select Platform to be PC and Mac
Standalone, clicks on the executable file that Build issues out PC end afterwards;
F, modification interactive bore hole 3D display scene are interactive 2D display scene, keep ID value not change;Modification
Concrete mode be:Retain the virtual camera hanging with TouchHandle in the scene, delete remaining seven virtual camera, simultaneously
Delete the new camera in display module and display floater;
G, compiling interactive 2D display scene are issued APK file, and are installed to Android device end;Literary composition such as PC end
Part is issued, and the PC selecting before and Mac Standalone is revised as Android, clicks on Build afterwards and issues out APK
File;
H, PC end is connected to bore hole 3D display terminal, is simultaneously connected with PC end, Android device end to same LAN;
By HDMI data line, PC end is coupled together with bore hole 3D display terminal, the image transmitting at PC end is shown to bore hole 3D
Terminal, creates LAN by router simultaneously, PC end, Android device is simultaneously connected to the LAN creating;
I, it is separately operable executable file, the newly-built IP address in Android device end, PC end is connected to identical ip addresses;Fortune
The executable file at row PC end, select file resolution is 1920 × 1080, keeps and bore hole 3D display terminal equal resolution;
In the newly-built IP address in Android device end, bore hole 3D display terminal ejects identical ip addresses, clicks on IP address, and display connects into
Work(;
J, carry out the interactive operation of 2D scene at Android device end, bore hole 3D display terminal responds identical bore hole 3D
Interactive action;Carry out the interactive operation of 2D scene at Android device end, its interactive operation includes rotation, mobile, scaling;Logical
Cross the communication interface of TNet plug-in unit, identical ID value responds identical action, and bore hole 3D display terminal responds corresponding bore hole
3D interactive action, realizes the bore hole 3D exchange method based on Android device.
The technical scheme of currently preferred step B is as follows:Described step B calls the relevant interface of TNet plug-in unit to realize net
Network communicates;Create new scene in exploitation engine, create video camera in new scene, the relevant interface of TNet plug-in unit will be called
Code file hang over virtual camera.
The technical scheme of currently preferred step B is as follows:Described step C creates interactive bore hole 3D display scene;Hand over
Mutually formula bore hole 3D display scene is broadly divided into two modules:Scene module and display module.
The technical scheme of currently preferred step B is as follows:Described step F modification interactive mode bore hole 3D display scene is to hand over
Mutually formula 2D display scene, keeps ID value not change;Modification concrete mode be:Retain in the scene and hang with
The virtual camera of TouchHandle, deletes remaining seven virtual camera, deletes new camera and display surface in display module simultaneously
Plate.
The technical scheme of currently preferred step B is as follows:Described step J carries out 2D scene at Android device end
Interactive operation, bore hole 3D display terminal responds identical bore hole 3D interactive action;Specifically the process of realizing of response is:Pass through
The communication interface of TNet plug-in unit, identical ID value responds identical action.
The present invention compared with the prior art, has advantages below and beneficial effect:
The present invention can efficiently solve interactive bore hole 3D and show the problem being difficult to regulate and control, and filled up interactive bore hole 3D
The blank in display control field, greatly extends the application of bore hole 3D Display Technique, notable promotion bore hole 3D Display Technique
Development.
Brief description
Fig. 1 is the structural representation of the present invention.
Specific embodiment
With reference to embodiment, the present invention is described in further detail:
Embodiment
As shown in figure 1, a kind of bore hole 3D exchange method based on Android device, its method and step is as follows:
A, by TNet plug-in unit import exploitation engine;
B, the relevant interface of TNet plug-in unit is called to realize network service.Preferably, described step B calls TNet plug-in unit
Relevant interface realizes network service;Create new scene in exploitation engine, create video camera in new scene, TNet will be called
The code file of the relevant interface of plug-in unit hangs over virtual camera.
C, establishment interactive bore hole 3D display scene.Preferably, described step C creates interactive bore hole 3D display field
Scape;Interactive bore hole 3D display scene is broadly divided into two modules:Scene module and display module.
D, with TNet plug-in unit give distinct interaction object difference ID value;
E, compile scene content and issue the executable file at PC end;
F, modification interactive bore hole 3D display scene are interactive 2D display scene, keep ID value not change.As
Preferably, described step F modification interactive mode bore hole 3D display scene is interactive 2D display scene, and holding ID value does not change;
Modification concrete mode be:Retain the virtual camera hanging with TouchHandle in the scene, delete remaining seven virtual camera,
Delete new camera and the display floater in display module simultaneously.
G, compiling interactive 2D display scene are issued APK file, and are installed to Android device end;
H, PC end is connected to bore hole 3D display terminal, is simultaneously connected with PC end, Android device end to same LAN;
I, it is separately operable executable file, the newly-built IP address in Android device end, PC end is connected to identical ip addresses;
J, carry out the interactive operation of 2D scene at Android device end, bore hole 3D display terminal responds identical bore hole 3D
Interactive action.Preferably, described step J carries out the interactive operation of 2D scene, bore hole 3D display terminal at Android device end
Response identical bore hole 3D interactive action;Specifically the process of realizing of response is:By the communication interface of TNet plug-in unit, identical ID
Value response identical action.
The preferred technical method of bore hole 3D exchange method based on Android device for the present invention is as follows, and its method and step is such as
Under:
A, by TNet plug-in unit import exploitation engine;TNet plug-in unit, as the plug-in unit encapsulating TCP or http network agreement, makes
Realize network communicating function with this plug-in unit and without too many workload, its function fully meets Android device end and PC
Network communicating function between end;
The relevant interface of the TNet plug-in unit in B, invocation step A realizes network service;Create new field in exploitation engine
Scape, creates video camera in new scene, the code file calling the relevant interface of TNet plug-in unit is hung on virtual camera, preserves
Scene is Communication;
C, establishment interactive bore hole 3D display scene;Create interactive bore hole 3D display scene mainly to divide in exploitation engine
For following two modules:Scene module and display module;Scene module mainly includes bore hole function and interactive function, and shows mould
Block mainly comprises display function;
The implementation of scene module bore hole function is as follows:In eight virtual cameras of Scene window creation of exploitation engine,
And the coordinate Position of all virtual cameras is set to (0,0,0), anglec of rotation Rotation is set to (0,0,0), chi
Very little size Scale is set to (1,1,1);Then adjust the distance between every camera and be spaced apart 0.017, belong in Layer simultaneously
Property in add new layer PlaySence, the rejecting shade Culling Mask attribute of eight video cameras of modification is PlaySence,
The dead ahead of eight virtual cameras creates zero plane ZeroPlane, and arranges its coordinate Position and be set to (0,0,10), rotation
Gyration Rotation is set to (270,0,0), and size Scale is set to (1,1,1), changes its attribute and is hidden,
Write associated script and realize the central point that eight video cameras focus on zero plane;Then create 8 in Project and render pinup picture
RenderTexture, the Size rendering pinup picture is revised as 1920 × 1080, in the Target Texture of every virtual camera
Give in attribute and different render pinup picture so that corresponding one of every video camera renders pinup picture;Then calculate viewpoint sub-pixel
Mapping matrix, and write corresponding Shader, sampling processing is carried out to the pinup picture that every camera renders, specific calculation is such as
Under:First, determine on 2D display screen that given RGB sub-pixel should take from the RGB component of which viewpoint, given below regard more
The computing formula of idea pixel-map matrix:
Wherein, X is the number that screen periods cover RGB sub-pixel in the horizontal direction, and (k, 1) is RGB sub-pixel
Coordinate position, a be grating axle with respect to LCD display vertical axises slanted angle, koffRepresent 2D display screen left edge with
The horizontal displacement of raster unit marginal point, NtotRepresent total viewpoint number, that is, participate in the anaglyph quantity synthesizing;
Which width anaglyph should be taken from according to the gray value that above formula can calculate each sub-pixel on 2D display screen
Corresponding coordinate position gray value;Then viewpoint mapping matrix is programmed in Shader, using Shader, camera is rendered
Multiple render the sampling processing that pinup picture carries out sub-pixel, and multiple anaglyphs through sampling processing are overlapped mutually, obtain
To final composograph;
The implementation of scene module interactive function is as follows:Add various interactive objects in the scene, and its Layer is belonged to
Property in be all modified to PlaySence, then in Project create CS script, modification script name be Play, write script
Realize different interactive actions, interactive action includes rotation, mobile or scaling, and script is hung over the friendship corresponding action
Mutually on object, then create CS script again, modification script name is TouchHandle, writes script and realizes ray detection work(
Can, and script is hung over one of virtual video camera, the attribute of modification virtual video camera is Main Camera;
The implementation of display module display function is as follows:Create new virtual camera and display floater, adjust virtualphase
The coordinate Position of machine is set to (- 5,0,100), and anglec of rotation Rotation is set to (0,90,0), size Scale
It is set to (1,1,1), Layer attribute adds new layer ShowSence, the rejecting shade Culling of eight video cameras of modification
Mask attribute is ShowSence, and changed shooting mode is orthogonal formula simultaneously, and camera angle is adjusted to 27, has changed depth
Depth is 1, and newly-built camera is defaulted as 0;Then the coordinate Position of adjustment display floater is set to (0,0,100), the anglec of rotation
Degree Rotation is set to (90, -90,0), and size Scale is set to (9.6,1,5.4), mates the aobvious of 1080P resolution
Show terminal;Its Layer attribute modification is ShowSence, creates material ball Material in display floater, by material simultaneously
The custom option of ball calls shader to obtain composograph, and composograph is presented on display floater;Finally, preserve to enter the court
Scape is Play;
D, with TNet plug-in unit give distinct interaction object difference ID value;Call the relevant interface of TNet plug-in unit, change it
Telescript, ID value is set to public ownership variable, and Telescript is hung on distinct interaction object, and gives different ID
Value;The ID value giving the first interaction object is 1, and the ID value of the second interaction object is 2, by that analogy;
E, compile scene content and issue the executable file at PC end;Click on the Build under exploitation engine File menu
Settings, and two above scene is put into Scenes In Build option hurdle, and select Platform to be PC and Mac
Standalone, clicks on the executable file that Build issues out PC end afterwards;
F, modification interactive bore hole 3D display scene are interactive 2D display scene, keep ID value not change;Modification
Concrete mode be:Retain the virtual camera hanging with TouchHandle in the scene, delete remaining seven virtual camera, simultaneously
Delete the new camera in display module and display floater;
G, compiling interactive 2D display scene are issued APK file, and are installed to Android device end;Literary composition such as PC end
Part is issued, and the PC selecting before and Mac Standalone is revised as Android, clicks on Build afterwards and issues out APK
File;
H, PC end is connected to bore hole 3D display terminal, is simultaneously connected with PC end, Android device end to same LAN;
By HDMI data line, PC end is coupled together with bore hole 3D display terminal, the image transmitting at PC end is shown to bore hole 3D
Terminal, creates LAN by router simultaneously, PC end, Android device is simultaneously connected to the LAN creating;
I, it is separately operable executable file, the newly-built IP address in Android device end, PC end is connected to identical ip addresses;Fortune
The executable file at row PC end, select file resolution is 1920 × 1080, keeps and bore hole 3D display terminal equal resolution;
In the newly-built IP address in Android device end, bore hole 3D display terminal ejects identical ip addresses, clicks on IP address, and display connects into
Work(;
J, carry out the interactive operation of 2D scene at Android device end, bore hole 3D display terminal responds identical bore hole 3D
Interactive action;Carry out the interactive operation of 2D scene at Android device end, its interactive operation includes rotation, mobile, scaling;Logical
Cross the communication interface of TNet plug-in unit, identical ID value responds identical action, and bore hole 3D display terminal responds corresponding bore hole
3D interactive action, realizes the bore hole 3D exchange method based on Android device.
The foregoing is only presently preferred embodiments of the present invention, not in order to limit the present invention, all essences in the present invention
Any modification, equivalent and improvement made within god and principle etc., should be included within the scope of the present invention.
Claims (6)
1. a kind of bore hole 3D exchange method based on Android device it is characterised in that:Its method and step is as follows:
A, by TNet plug-in unit import exploitation engine;
B, the relevant interface of TNet plug-in unit is called to realize network service;
C, establishment interactive bore hole 3D display scene;
D, with TNet plug-in unit give distinct interaction object difference ID value;
E, compile scene content and issue the executable file at PC end;
F, modification interactive bore hole 3D display scene are interactive 2D display scene, keep ID value not change;
G, compiling interactive 2D display scene are issued APK file, and are installed to Android device end;
H, PC end is connected to bore hole 3D display terminal, is simultaneously connected with PC end, Android device end to same LAN;
I, it is separately operable executable file, the newly-built IP address in Android device end, PC end is connected to identical ip addresses;
J, carry out the interactive operation of 2D scene at Android device end, the response identical bore hole 3D interaction of bore hole 3D display terminal
Action.
2. according to a kind of bore hole 3D exchange method based on Android device described in claim 1 it is characterised in that:Its side
Method step is as follows:
A, by TNet plug-in unit import exploitation engine;TNet plug-in unit as the plug-in unit encapsulating TCP or http network agreement, using this
Plug-in unit realizing network communicating function and without too many workload, its function fully meet Android device end and PC end it
Between network communicating function;
The relevant interface of the TNet plug-in unit in B, invocation step A realizes network service;Create new scene in exploitation engine,
Create video camera in new scene, the code file calling the relevant interface of TNet plug-in unit is hung on virtual camera, saving scenario
For Communication;
C, establishment interactive bore hole 3D display scene;Exploitation engine creates interactive bore hole 3D display scene be broadly divided into
Lower two modules:Scene module and display module;Scene module mainly includes bore hole function and interactive function, and display module master
Display function to be comprised;
The implementation of scene module bore hole function is as follows:In eight virtual cameras of Scene window creation of exploitation engine, and will
The coordinate Position of all virtual cameras is set to (0,0,0), and anglec of rotation Rotation is set to (0,0,0), and size is big
Little Scale is set to (1,1,1);Then adjust the distance between every camera and be spaced apart 0.017, simultaneously in Layer attribute
Add new layer PlaySence, the rejecting shade Culling Mask attribute of eight video cameras of modification is PlaySence, at eight
The dead ahead of virtual camera creates zero plane ZeroPlane, and arranges its coordinate Position and be set to (0,0,10), the anglec of rotation
Degree Rotation is set to (270,0,0), and size Scale is set to (1,1,1), changes its attribute and is hidden, writes
Associated script realizes the central point that eight video cameras focus on zero plane;Then create 8 in Project and render pinup picture
RenderTexture, the Size rendering pinup picture is revised as 1920 × 1080, in the Target Texture of every virtual camera
Give in attribute and different render pinup picture so that corresponding one of every video camera renders pinup picture;Then calculate viewpoint sub-pixel
Mapping matrix, and write corresponding Shader, sampling processing is carried out to the pinup picture that every camera renders, specific calculation is such as
Under:First, determine on 2D display screen that given RGB sub-pixel should take from the RGB component of which viewpoint, given below regard more
The computing formula of idea pixel-map matrix:
Wherein, X is the number that screen periods cover RGB sub-pixel in the horizontal direction, and (k, 1) is the seat of RGB sub-pixel
Cursor position, α is the slanted angle that grating axle is with respect to LCD display vertical axises, koffRepresent 2D display screen left edge and grating
The horizontal displacement of cell edges point, NtotRepresent total viewpoint number, that is, participate in the anaglyph quantity synthesizing;
The phase of any width anaglyph should be taken from according to the gray value that above formula can calculate each sub-pixel on 2D display screen
Answer the gray value of coordinate position;Then viewpoint mapping matrix is programmed in Shader, using Shader camera is rendered many
Open and render the sampling processing that pinup picture carries out sub-pixel, and multiple anaglyphs through sampling processing are overlapped mutually, obtain
Whole composograph;
The implementation of scene module interactive function is as follows:Add various interactive objects in the scene, and by its Layer attribute
It is all modified to PlaySence, in Project, then create CS script, modification script name is Play, write script and realize
Different interactive actions, interactive action includes rotation, mobile or scaling, and script is hung over the interactive thing corresponding action
On body, then create CS script again, modification script name is TouchHandle, writes script and realizes ray detection function, and
Script is hung over one of virtual video camera, the attribute of modification virtual video camera is Main Camera;
The implementation of display module display function is as follows:Create new virtual camera and display floater, adjustment virtual camera
Coordinate Position is set to (- 5,0,100), and anglec of rotation Rotation is set to (0,90,0), and size Scale is arranged
For (1,1,1), Layer attribute adds new layer ShowSence, the rejecting shade Culling Mask of eight video cameras of modification
Attribute is ShowSence, and changed shooting mode is orthogonal formula simultaneously, and camera angle is adjusted to 27, and having changed depth Depth is
1, newly-built camera is defaulted as 0;Then the coordinate Position of adjustment display floater is set to (0,0,100), the anglec of rotation
Rotation is set to (90, -90,0), and size Scale is set to (9.6,1,5.4), the display of coupling 1080P resolution
Terminal;Its Layer attribute modification is ShowSence, creates material ball Material in display floater, by material ball simultaneously
Custom option call shader obtain composograph, composograph is presented on display floater;Finally, preserve above scene
For Play;
D, with TNet plug-in unit give distinct interaction object difference ID value;Call the relevant interface of TNet plug-in unit, change its communication
Script, ID value is set to public ownership variable, and Telescript is hung on distinct interaction object, and gives different ID values;Assign
The ID value giving the first interaction object is 1, and the ID value of the second interaction object is 2, by that analogy;
E, compile scene content and issue the executable file at PC end;Click on the Build under exploitation engine File menu
Settings, and two above scene is put into Scenes In Build option hurdle, and select Platform to be PC and Mac
Standalone, clicks on the executable file that Build issues out PC end afterwards;
F, modification interactive bore hole 3D display scene are interactive 2D display scene, keep ID value not change;The tool of modification
Body mode is:Retain the virtual camera hanging with TouchHandle in the scene, delete remaining seven virtual camera, delete simultaneously
New camera in display module and display floater;
G, compiling interactive 2D display scene are issued APK file, and are installed to Android device end;File such as PC end is sent out
Cloth, the PC selecting before and Mac Standalone is revised as Android, clicks on Build afterwards and issues out APK file;
H, PC end is connected to bore hole 3D display terminal, is simultaneously connected with PC end, Android device end to same LAN;Pass through
PC end is coupled together by HDMI data line with bore hole 3D display terminal, and the image transmitting at PC end to bore hole 3D is shown eventually
End, creates LAN by router simultaneously, PC end, Android device is simultaneously connected to the LAN of establishment;
I, it is separately operable executable file, the newly-built IP address in Android device end, PC end is connected to identical ip addresses;Run PC
The executable file at end, select file resolution is 1920 × 1080, keeps and bore hole 3D display terminal equal resolution;?
The newly-built IP address in Android device end, bore hole 3D display terminal ejects identical ip addresses, clicks on IP address, shows successful connection;
J, carry out the interactive operation of 2D scene at Android device end, the response identical bore hole 3D interaction of bore hole 3D display terminal
Action;Carry out the interactive operation of 2D scene at Android device end, its interactive operation includes rotation, mobile, scaling;Pass through
The communication interface of TNet plug-in unit, identical ID value responds identical action, and bore hole 3D display terminal responds corresponding bore hole 3D
Interactive action, realizes the bore hole 3D exchange method based on Android device.
3. according to a kind of bore hole 3D exchange method based on Android device described in claim 1 it is characterised in that:Described
Step B calls the relevant interface of TNet plug-in unit to realize network service;Create new scene in exploitation engine, create in new scene
Build video camera, the code file calling the relevant interface of TNet plug-in unit is hung over virtual camera.
4. according to a kind of bore hole 3D exchange method based on Android device described in claim 1 it is characterised in that:Described
Step C creates interactive bore hole 3D display scene;Interactive bore hole 3D display scene is broadly divided into two modules:Scene module and
Display module.
5. according to a kind of bore hole 3D exchange method based on Android device described in claim 1 it is characterised in that:Described
Step F modification interactive bore hole 3D display scene is interactive 2D display scene, keeps ID value not change;That changes is concrete
Mode is:Retain the virtual camera hanging with TouchHandle in the scene, delete remaining seven virtual camera, delete aobvious simultaneously
Show new camera and the display floater in module.
6. according to a kind of bore hole 3D exchange method based on Android device described in claim 1 it is characterised in that:Described
Step J carries out the interactive operation of 2D scene at Android device end, and the response identical bore hole 3D interaction of bore hole 3D display terminal is dynamic
Make;Specifically the process of realizing of response is:By the communication interface of TNet plug-in unit, identical ID value responds identical action.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610841052.0A CN106445517A (en) | 2016-09-22 | 2016-09-22 | Naked eye 3D interactive method based on Android device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610841052.0A CN106445517A (en) | 2016-09-22 | 2016-09-22 | Naked eye 3D interactive method based on Android device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106445517A true CN106445517A (en) | 2017-02-22 |
Family
ID=58166187
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610841052.0A Pending CN106445517A (en) | 2016-09-22 | 2016-09-22 | Naked eye 3D interactive method based on Android device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106445517A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110620917A (en) * | 2019-10-22 | 2019-12-27 | 上海第二工业大学 | Virtual reality cross-screen stereoscopic display method |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104702936A (en) * | 2015-03-31 | 2015-06-10 | 王子强 | Virtual reality interaction method based on glasses-free 3D display |
CN105263015A (en) * | 2015-10-27 | 2016-01-20 | 成都斯斐德科技有限公司 | Method for controlling glasses-free 3D video display based on Android device |
CN105959677A (en) * | 2016-07-12 | 2016-09-21 | 四川长虹电器股份有限公司 | Naked eye 3D interaction method based on Android equipment |
-
2016
- 2016-09-22 CN CN201610841052.0A patent/CN106445517A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104702936A (en) * | 2015-03-31 | 2015-06-10 | 王子强 | Virtual reality interaction method based on glasses-free 3D display |
CN105263015A (en) * | 2015-10-27 | 2016-01-20 | 成都斯斐德科技有限公司 | Method for controlling glasses-free 3D video display based on Android device |
CN105959677A (en) * | 2016-07-12 | 2016-09-21 | 四川长虹电器股份有限公司 | Naked eye 3D interaction method based on Android equipment |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110620917A (en) * | 2019-10-22 | 2019-12-27 | 上海第二工业大学 | Virtual reality cross-screen stereoscopic display method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Raskar et al. | Table-top spatially-augmented realty: bringing physical models to life with projected imagery | |
CN108830939B (en) | Scene roaming experience method and experience system based on mixed reality | |
KR101732836B1 (en) | Stereoscopic conversion with viewing orientation for shader based graphics content | |
CN106504339A (en) | Historical relic 3D methods of exhibiting based on virtual reality | |
US10366642B2 (en) | Interactive multiplane display system with transparent transmissive layers | |
CN106527857A (en) | Virtual reality-based panoramic video interaction method | |
CN101477700B (en) | Real tri-dimension display method oriented to Google Earth and Sketch Up | |
US9681122B2 (en) | Modifying displayed images in the coupled zone of a stereoscopic display based on user comfort | |
WO2022063260A1 (en) | Rendering method and apparatus, and device | |
CN101477701A (en) | Built-in real tri-dimension rendering process oriented to AutoCAD and 3DS MAX | |
CN106210856A (en) | Internet video live broadcasting platform is watched the method and system of 3D panoramic video | |
CN114616035A (en) | Hybrid streaming | |
CN107562185B (en) | Light field display system based on head-mounted VR equipment and implementation method | |
CN105959677A (en) | Naked eye 3D interaction method based on Android equipment | |
WO2021139456A1 (en) | Calculation method and system for dynamic rendering of image having infinite visual boundary | |
CN106547557A (en) | A kind of multi-screen interactive exchange method based on virtual reality and bore hole 3D | |
CN101521828B (en) | Implanted type true three-dimensional rendering method oriented to ESRI three-dimensional GIS module | |
JP7426413B2 (en) | Blended mode three-dimensional display system and method | |
JP2009147508A (en) | Stereoscopic image generating method, apparatus thereof, and stereoscopic image display | |
CN101511034A (en) | Truly three-dimensional stereo display method facing Skyline | |
CN106445517A (en) | Naked eye 3D interactive method based on Android device | |
CN101540056A (en) | Implanted true-three-dimensional stereo rendering method facing to ERDAS Virtual GIS | |
Luo et al. | GPU rendering for tiled multi-projector autostereoscopic display based on chromium | |
Santos et al. | Improve: An innovative application for collaborative mobile mixed reality design review | |
CN101488229A (en) | PCI three-dimensional analysis module oriented implantation type ture three-dimensional stereo rendering method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170222 |