SlideShare a Scribd company logo
1 of 49
Augmented Reality (AR)簡介與
製作
報告者 : 張偉倫
協助夥伴 : 年興老師、怡玲姐、秀珍姐、逸群學長、Sylvia 、雅文和
冠穎(Aintis)
目錄
• AR的簡介
• 定義
• 虛擬顯示技術
• 目標辨識類型
• Unity + Vuforia的AR實作
• 虛擬物件的互動
• AR建置軟體的比較
• Unity + Vuforia
• Blippar
Definition
1990 The term augmented reality (AR) was originated
by scientists at the aircraft manufacturer Boeing.
1994
Milgram and Kishino presented the concept of a
virtuality continuum.
1997
Azuma identified three characteristics of AR .
1. Combines real and virtual
2. Interactive in real time
3. Registered in three dimensions
TIMELINE
Image Recognition and Location
• The two types of AR application
reported in Pence’s (2011) study,
namely:
• Kun-Hung Cheng and Chin-Chung
Tsai attempts to re-coin the two types
of AR as :
(1) image-based
(1) marker-based
(2) markerless
(2) location-based
classified as
Display Technologies
• There are two ways to accomplish the combining of real and virtual
: video or optical technologies.
Video Optical
The video cameras provide the user's
view of the real world.
The user can look directly through
optical combiners to see the real world.
先註冊帳號
註冊完成後登入
1
2
1
2
1
2
3
*登入後畫面
1
2
3
選擇Develop
選擇Target Manager
按Add Database
1
2
3
1
2
3
取名
選擇Device
按Create
*按Add Database之後顯示的畫面
資料庫新增完成 1
1 點擊資料庫名稱(此範例為test2)
1
1 按Add Target
1
2
3
4
1
2
*按Add Target之後顯示的畫面
3
4
選擇要被辨識的物件類型
上傳被辨識物件的檔案
此範例被辨識的物件類型是Single
Image所以要設定Image的寬度
按Add
1
1 按Download Database (All)
被辨識的物件新增完成
*按Download Database (All) 之後顯示的畫面
1
2
1
2
選擇Unity Editor開發平台
按Download
下載完成會看到一個副檔名是.unitypackage的檔案
*到此頁步驟已完成被辨識物件的建立,接下來進行unity的環境設定
1
2
3
1
2
3
選擇Downloads
選擇SDK
點Download for Unity下載Vuforia的套件
下載完成會看到一個副檔名是.unitypackage的檔案
*執行Unity
1
1 按NEW新增專案
1
2
*按NEW之後的畫面
1
2
輸入專案名稱
按Create project 3
3 選擇3D或2D都可以
1
Main Camera在此範例不會用到可以先刪掉
1
1
1 選擇Assets > Import Package > Custom Package…
2
1
2
將之前下載的兩個副檔名為.unitypackage,一次一個載入到專案中
按開啟
1
 按Custom Package後,會出現此視窗
1 2
1
2
按All
按Import
*按開啟後,會跳出新視窗
1
2
3
1
2
3
4
4
在左下角可以看到載入的資料夾,將路徑換
到Prefabs底下,然後把ARCamera移到Scene裡
*按Import後
將在Vuforia申請的License Key貼到App License Key欄位
因為此範例要同時辨識兩圖片所以Max Simultaneous
Tracked Imges欄位設定為2
打勾Database Load Behaviour (Script)、Load
magnet(名稱各有不同) Database和Activate
1
2
3
1
2
3
點Develop
點License Manager
按Add License Key
1
2
3
4
1
2
3
4
*按Add License Key之後的畫面
選擇Development為Project Type
輸入App Name
選擇Mobile作為Device
按Next
1
2
1
2
*按Next之後的畫面
打勾
按Confirm
License Key新增成功
點License Key名稱,
此範例為test2
*按License Key名稱之後的畫面
1
1
複製License Key
*到此頁已完成AR Camera的License Key的申請,
接著回到unity將License Key貼到AR Camera
1
2
3
1
2
3
4
4
在左下角可以看到載入的資料夾,將路徑換
到Prefabs底下,然後把ARCamera移到Scene裡
*按Import後
將在Vuforia申請的License Key貼到App License Key欄位
因為此範例要同時辨識兩圖片所以Max Simultaneous
Tracked Imges欄位設定為2
打勾Database Load Behaviour (Script)、Load
magnet(名稱各有不同) Database和Activate
1
1
按滑鼠右鍵,選擇Create Empty,然後重新命名,
此範例為MultiTarget
1
1
將兩個ImageTarget物件拉到Scene裡,這裡重新命名為
Cola和Magnet
2
設定ImageTarget的Database和ImageTarget ,此範例
Database為magnet,ImageTarget為Cola和magnet
2
按Ctrl+Shift+f讓Camera鏡頭移到圖片的正面
1
2
*此頁步驟讓ARCamera鏡頭正對辨識目標
1
2
按2D將場景切換成3D模式
1
1 功能由左至右分別表示:
• 移動場景
• 移動物件方位
• 旋轉物件
• 調整物件大小
• 改變物件外型
*上一頁因為Cola圖片重疊在磁鐵的圖片上面,所以要將Cola
圖片移到其他位置
1
1
因為要辨識Cola和Magnet目標的距離,所以兩個
目標各新增1個Sphere(可換其他物件)的3D Object
*Alt+移動滑鼠改變使用者觀看場景的視角
1
2
1
2
到Asset Store搜尋magnet
選第二個
*下載模型
1
2
1
2
Import
Import
1
切換路徑到Assets > PowerUps Vol 1 Free > Prefabs,
把磁鐵的模型和可樂罐模型(以電池代替)放到場景中
1
1
*為了讓磁鐵和電池有物理現象,此頁設定讓它們有實體
,目前看到的只是它們的外表,裡面是空的
1 按Add Component,選Physics
1 選Mesh Collider
1
1
1 Convex打勾
1 按Add Component,選Physics > Rigidbody
1
1
1 Mess設為0,否則一執行電池就往下掉
1
1
建立C#語言的腳本,讓磁鐵和電池
在一定的距離內,電池就會被磁鐵
吸過去
*存取權限設定為public
1
1
將左邊的物件拉到剛程式碼設定的變數
欄位(因為變數權限設為public所以才會
出現在此畫面)
*兩個物件拉開一點,否則距離太近一執行電池就被吸過去了
*成果
1
1 選擇File > Build Settings…
1
2 3
4
1
2
3
4
選擇Android
點Player Settings…
*按Build Settings後出現的視窗
輸入Bundle Identifier欄位(隨便取字母+數字)
選擇Minimum API Level,建議不要選太低或
太高的版本,此範例是選Android 4.0.3
按Build
*按Build後出現的視窗
1
2
1 輸入app名稱
2
按存檔
*將.apk檔放到手機安裝,然後執行,即可測試AR程式

More Related Content

More from AkashaC1

2018 Week 15 Speech Recognition
2018 Week 15 Speech Recognition2018 Week 15 Speech Recognition
2018 Week 15 Speech RecognitionAkashaC1
 
2018 Week 15 Speaker
2018 Week 15 Speaker2018 Week 15 Speaker
2018 Week 15 SpeakerAkashaC1
 
2018 Week 14 HC-SR04
2018 Week 14 HC-SR042018 Week 14 HC-SR04
2018 Week 14 HC-SR04AkashaC1
 
2018 Week 13 Servo Motor
2018 Week 13 Servo Motor2018 Week 13 Servo Motor
2018 Week 13 Servo MotorAkashaC1
 
2018 Week 12 Data Storage and Visualization
2018 Week 12 Data Storage and Visualization2018 Week 12 Data Storage and Visualization
2018 Week 12 Data Storage and VisualizationAkashaC1
 
2018 Week 11 Bluetooth and Wi-Fi
2018 Week 11 Bluetooth and Wi-Fi2018 Week 11 Bluetooth and Wi-Fi
2018 Week 11 Bluetooth and Wi-FiAkashaC1
 
2018 Week 10 Read Time Data Sending
2018 Week 10 Read Time Data Sending2018 Week 10 Read Time Data Sending
2018 Week 10 Read Time Data SendingAkashaC1
 
2018 Week 10 IoT and Robot
2018 Week 10 IoT and Robot2018 Week 10 IoT and Robot
2018 Week 10 IoT and RobotAkashaC1
 
2018 Week 8 Relay
2018 Week 8 Relay2018 Week 8 Relay
2018 Week 8 RelayAkashaC1
 
2018 Week 8 IoT and Wearable Devices
2018 Week 8 IoT and Wearable Devices2018 Week 8 IoT and Wearable Devices
2018 Week 8 IoT and Wearable DevicesAkashaC1
 
2018 Week 7 Photoresistor
2018 Week 7 Photoresistor2018 Week 7 Photoresistor
2018 Week 7 PhotoresistorAkashaC1
 
2018 Week 16 Computer Vision
2018 Week 16 Computer Vision2018 Week 16 Computer Vision
2018 Week 16 Computer VisionAkashaC1
 
2018 Week 4 Data Storage
2018 Week 4 Data Storage2018 Week 4 Data Storage
2018 Week 4 Data StorageAkashaC1
 
2018 Week 3 Sending and Processing Data
2018 Week 3 Sending and Processing Data2018 Week 3 Sending and Processing Data
2018 Week 3 Sending and Processing DataAkashaC1
 
2018 Week 3 GPIO-LED
2018 Week 3 GPIO-LED2018 Week 3 GPIO-LED
2018 Week 3 GPIO-LEDAkashaC1
 
2018 Week 2 Internet of Things Raspberry Pi 3
2018 Week 2 Internet of Things Raspberry Pi 32018 Week 2 Internet of Things Raspberry Pi 3
2018 Week 2 Internet of Things Raspberry Pi 3AkashaC1
 
2017 Week 15 Computer Vision 2
2017 Week 15 Computer Vision 22017 Week 15 Computer Vision 2
2017 Week 15 Computer Vision 2AkashaC1
 
2017 Week 3 GPIO-LED
2017 Week 3 GPIO-LED2017 Week 3 GPIO-LED
2017 Week 3 GPIO-LEDAkashaC1
 
2017 Week 4 GPIO-Seven Segment Display
2017 Week 4 GPIO-Seven Segment Display2017 Week 4 GPIO-Seven Segment Display
2017 Week 4 GPIO-Seven Segment DisplayAkashaC1
 
2017 Week 5 Passive Buzzer
2017 Week 5 Passive Buzzer2017 Week 5 Passive Buzzer
2017 Week 5 Passive BuzzerAkashaC1
 

More from AkashaC1 (20)

2018 Week 15 Speech Recognition
2018 Week 15 Speech Recognition2018 Week 15 Speech Recognition
2018 Week 15 Speech Recognition
 
2018 Week 15 Speaker
2018 Week 15 Speaker2018 Week 15 Speaker
2018 Week 15 Speaker
 
2018 Week 14 HC-SR04
2018 Week 14 HC-SR042018 Week 14 HC-SR04
2018 Week 14 HC-SR04
 
2018 Week 13 Servo Motor
2018 Week 13 Servo Motor2018 Week 13 Servo Motor
2018 Week 13 Servo Motor
 
2018 Week 12 Data Storage and Visualization
2018 Week 12 Data Storage and Visualization2018 Week 12 Data Storage and Visualization
2018 Week 12 Data Storage and Visualization
 
2018 Week 11 Bluetooth and Wi-Fi
2018 Week 11 Bluetooth and Wi-Fi2018 Week 11 Bluetooth and Wi-Fi
2018 Week 11 Bluetooth and Wi-Fi
 
2018 Week 10 Read Time Data Sending
2018 Week 10 Read Time Data Sending2018 Week 10 Read Time Data Sending
2018 Week 10 Read Time Data Sending
 
2018 Week 10 IoT and Robot
2018 Week 10 IoT and Robot2018 Week 10 IoT and Robot
2018 Week 10 IoT and Robot
 
2018 Week 8 Relay
2018 Week 8 Relay2018 Week 8 Relay
2018 Week 8 Relay
 
2018 Week 8 IoT and Wearable Devices
2018 Week 8 IoT and Wearable Devices2018 Week 8 IoT and Wearable Devices
2018 Week 8 IoT and Wearable Devices
 
2018 Week 7 Photoresistor
2018 Week 7 Photoresistor2018 Week 7 Photoresistor
2018 Week 7 Photoresistor
 
2018 Week 16 Computer Vision
2018 Week 16 Computer Vision2018 Week 16 Computer Vision
2018 Week 16 Computer Vision
 
2018 Week 4 Data Storage
2018 Week 4 Data Storage2018 Week 4 Data Storage
2018 Week 4 Data Storage
 
2018 Week 3 Sending and Processing Data
2018 Week 3 Sending and Processing Data2018 Week 3 Sending and Processing Data
2018 Week 3 Sending and Processing Data
 
2018 Week 3 GPIO-LED
2018 Week 3 GPIO-LED2018 Week 3 GPIO-LED
2018 Week 3 GPIO-LED
 
2018 Week 2 Internet of Things Raspberry Pi 3
2018 Week 2 Internet of Things Raspberry Pi 32018 Week 2 Internet of Things Raspberry Pi 3
2018 Week 2 Internet of Things Raspberry Pi 3
 
2017 Week 15 Computer Vision 2
2017 Week 15 Computer Vision 22017 Week 15 Computer Vision 2
2017 Week 15 Computer Vision 2
 
2017 Week 3 GPIO-LED
2017 Week 3 GPIO-LED2017 Week 3 GPIO-LED
2017 Week 3 GPIO-LED
 
2017 Week 4 GPIO-Seven Segment Display
2017 Week 4 GPIO-Seven Segment Display2017 Week 4 GPIO-Seven Segment Display
2017 Week 4 GPIO-Seven Segment Display
 
2017 Week 5 Passive Buzzer
2017 Week 5 Passive Buzzer2017 Week 5 Passive Buzzer
2017 Week 5 Passive Buzzer
 

AR Implementation 2

Editor's Notes

  1. 技術教學的報告方式: 可以跟大家講我們今天要學什麼工具,學完之後你們可以獲得什麼東西
  2. in the 1990s, the term augmented reality (AR) was originated by scientists at the aircraft manufacturer Boeing, who were developing an AR system that blended virtual graphics onto a real environment display to help aircraft electricians with cable assembly (Caudell and Mizell 1992). 波音公司研究與技術部門的工作人員表示,他們利用谷歌眼鏡製造出了飛機的電子線束。 波音公司表示, 他們使用谷歌眼鏡後安裝電子線束的時間縮短了25%, 同時錯誤率降低了一半。 由於飛機包含了連接到電力系統的凌亂、巨大及複雜的電線網絡,技術人員需要一邊觀看筆記本電腦上的PDF組裝說明,一邊手動安裝,用AR眼鏡代替電腦屏可以為工作人員帶來不少方面。 原文網址:https://kknews.cc/tech/axayog.html 原文網址:https://kknews.cc/tech/axayog.html 原文網址:https://kknews.cc/tech/axayog.html
  3. The two types of AR application reported in Pence’s (2011) study, namely :(1) marker-based (2) markerless AR 擴增實境技術以虛擬與現實結合、即時互動及虛擬三維物件等三項原則,並以追蹤、定位及顯示等三項技術建構擴增實境系統。 http://portal.stpi.narl.org.tw/index/article/10258 陳坤宏
  4. Optical(光學原理) :光學穿透式顯示技術是人的眼晴直接透過鏡片看到三維的空間中虛擬的圖像,並透過準確追蹤和精準定位技術在空間中抓取或觸摸虛擬的圖形產生反饋,與真實的世界同步和互動(Bimber & Ramesh, 2005)。Ex: hololens Video(影像合成技術) :影像穿透式顯示技術利用攝影機鏡頭呈現「影像疊加」的方式,將數位資訊或圖像疊加在真實世界的實像或實物上,透過手機和平板上相關的應用程式,在現實的狀態下可以看見增加的影像及資訊,是將虛擬的影像與現實的物體結合的顯示技術(Rolland & Fuchs,2000 ; Freddie, 2016)。Ex : smartphone
  5. Device databases provide Vuforia applications with a locally accessible database of image targets.  Cloud databases provide Vuforia applications with a large number of targets. Cloud databases are stored in the Internet and support over a million image targets.
  6. The width value can arbitrary. It is used to establish the unit scale of your Unity scene