Projector calibration using Unity3d Mike Jiang 1

Projector calibration using Unity3d
PROJECTOR CALIBRATIO N USING
UNITY3D
H OW
P R EP AR AT IO N
ST EP 1 : D OW NL O AD & IN ST AL L U NI T Y 3D
https://unity3d.com/unity/download
ST EP 2 : D OW NL O AD P R O J EC T F R O M T W IK I
URL [Upload ZipFile; Folder Projection-Mapping-in-Unity-3Dmaster is sufficient]
ST EP 3 : C R E AT E A N E X EC U T AB L E F IL E
 Start Unity3d
 File -> Open Project…
 Select downloaded Project
 File -> Build Settings
o Choose Plattform “PC, Mac & Linux Standalone”
o Specify Target Platform, Architecture [e.g. Linux]
o Press “Build”
P R O JEC T OR C AL IB R AT I O N O N W I N D OW S
C H AN G E D I SP L AY S ET T I NG S
 Connect projector to PC
 Right click on desktop
 Select “Screen resolution”
 Click on “Detect”
 Change “Display” to connected device. E.g. “2. Mitsubishi
XD490/XD460”
 Change “Orientation” to “Landscape”
 Change “Multiple displays” to “Extend these displays”
R U N E X EC U T AB L E F IL E V I A C M D
 Open Windows Command Processor (cmd)
 Let be the total screen width [Desktop + Projector]
 Let be the directory of the executable file of the project
 Type in following command line:
–popupwindow –screen–width
For example:
Users\MHJ\Desktop\UnityProjects\Projection-Mappingin-Unity-3D-master\Demo.exe –popwindow –screen–
width 2624
More CommandLineArguments for Unity:
http://docs.unity3d.com/Manual/CommandLineArgumen
ts.html
Mike Jiang
P R O JEC T OR C A L IB R A T I O N O N L I N U X
.X 8 6_ 6 4 [ R U NS O N L U N C H ]
 Folder Mono: Delete all folders but keep the libmono.so
file directly under folder Mono
 Folder Plugins: Do the same with ScreenSelector.so
 Make the .x86_64 file executable via:
o Left click on file -> Properties -> Permissions -> Mark
the checkbox stating “Allow executing file as program”
 Run program via cmd
 Use
http://docs.unity3d.com/Manual/CommandLineArgumen
ts.html for adjusting the screen-width
 Lunch has 1920x1280 resolution
L EAR N IN G U N IT Y
T U T OR I A L S
 Recommended: Project “Roll-a-Ball”
o This tutorial will give you an overview about unity
o Recommended: Take notes and compare it with my
notes [UnityNotes.docx]
 Understanding shaders/textures/materials
o http://www.youtube.com/watch?v=Op10dBJ69dU
o Filter forge for texture design
 Shader tutorial [Needed to modify homography shader]
o http://unitygems.com/noobshader1/
o Kenneth Lammers has lots of useful shader tutorials on
his channel: http://www.youtube.com/channel/UCqD7LgucDtIRlazj9UzMwA
 Serializer tutorial [Save/Load Game]
o http://www.youtube.com/watch?v=K_z4qUX7wE8
o Get Asset on:
https://www.assetstore.unity3d.com/en/#!/content/3
675
 Homography Shader
o https://github.com/chiragraman/Projection-Mappingin-Unity3D/blob/master/Assets/Scripts/Homography.cs
1