Game Manager API
https://developers.google.com/cast/docs/gaming?hl=ko
Google Cast SDK Get Started
https://developers.google.com/cast/docs/developers?hl=ko#libraries
지원 라이브러리 설정
https://developer.android.com/topic/libraries/support-library/setup.html?hl=ko
v7 mediarouter 라이브러리
https://developer.android.com/topic/libraries/support-library/features.html?hl=ko#v7-mediarouter
Set Up Google Play Services
https://developers.google.com/android/guides/setup?hl=ko
게임 매니저 API에서 시작하세요 Google Cast로 보내준다
시작하세요 Google Cast에서는 구글 플레이 서비스 까는 법 페이지로 보내준다.
그래서 구글 플레이 서비스 까는 것부터 시작한다.
Google Play Services 설치
1. 안드로이드 스튜디오를 킨다
2. Tool 메뉴를 열고 Android > SDK Manager를 클릭한다.
3. 안드로이드 SDK 매니저 업데이트
SDK tools를 클릭한다.
스크롤을 내리다보면 보이는 Support Repository를 클릭해서 확장시켜준다.
Support Repository 하위 속성으로 있는 Google Repository를 찾아 체크해준다
OK를 눌러준다.
내 프로젝트에 Google Play Services 추가하기
왼쪽 프로젝트 익스플로어 설정을 일단 Android로 해준다.
app 폴더 밑에 있는
Gradle Scripts를 눌러서
build.gradle (Module: app)을 찾아서 열어줘야한다.
apply plugin: 'com.android.application'
...
dependencies {
compile 'com.google.android.gms:play-services:10.2.0'
}
이 코드 추가해주라고 가이드에서 알려준다.
내 프로젝트에 Google Cast API만 추가하기
apply plugin: 'com.android.application'
...
dependencies {
compile 'com.google.android.gms:play-services-cast:10.2.0'}
Play-service 전체를 넣는 게 아니고 원하는 것만 추가할 수 있다.
나는 google cast 니까 그것만 추가한다.
API 추가하는 코드는 맨 위에 걸어둔 Set Up Google Play Services 링크 속 Add Google Play Services to Your Project에서 찾을 수 있다.
Ensure Devices Have the Google Play services APK
이 항목에 있는건 뭔 말인지 아직 모르겠다.
구글 플레이스토어가 버전업 되면 유저들 버전도 올라가니까 내 버전도 올려야하고
내 프로젝트에 설정된 플레이 서비스 버전도 올려야한다는 건가?