LoginSignup
0
0

More than 5 years have passed since last update.

Vuforia の File Driver Sample をビルドする

Last updated at Posted at 2018-10-06

概要

Vuforia の External Camera の例として紹介されている File Driver のビルドにちょっと手間取ったのでビルドするために必要な作業のログです。

手順

環境は Windows 10, Visual Studio 2017 です. mac だとうまくいきませんでした.

  1. https://developer.vuforia.com/downloads/samples の Advanced Topics の Download File Driver からコードをダウンロード
  2. ↑と同じページの Core Features の Download for UWP をダウンロード
  3. ダウンロードした zip を適当に解凍
  4. cmake をダウンロード & インストール (3.9.6 を使ったけどおそらくほかのバージョンでも大丈夫だと思います)
  5. 解凍した 1 のディレクトリにコマンドプロンプトで入ります
    • ex) cd C:\Users\miro\Downloads\vuforia-driver-sample-filedriver-android_uwp-7-5-20
  6. この後の作業を少し楽にするためにこのディレクトリの中に lib というディレクトリを作って解凍した 2 の中にある build/ の中の includelib をコピーします.
    • 下の画像のようなディレクトリ構造になっていれば大丈夫です.
  7. 次に build.py を編集します. build.py では cmake の generator に Visual Studio 14 2015 を使っているので Visual Studio 2017 でビルドできません. そこで下のソースコードのように Visual Studio 15 2017 を使うようにコードを変更します(84行目付近です).
  8. そしたら5のコマンドプロンプトで python build.py -a x64 -vh lib\include uwp と実行すればビルドが開始されます.

ディレクトリ構造

ディレクトリ構造

build.py (一部)

        elif platform == PLATFORM_UWP:
            toolchain_file = os.path.join(android_toolchain_dir, "uwp.toolchain.{0}.cmake".format(arch))
            if arch == "x86":
                generator = "Visual Studio 15 2017"
            elif arch == "x64":
                generator = "Visual Studio 15 2017 Win64"

以上です.

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0