mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-07-07 13:04:18 +02:00
Merge remote-tracking branch 'hifi/master' into merge-hifi-master
# Conflicts: # CMakeLists.txt # README.md # cmake/externals/glad32es/CMakeLists.txt # cmake/externals/glad41/CMakeLists.txt # cmake/externals/glad45/CMakeLists.txt # cmake/externals/polyvox/CMakeLists.txt # cmake/externals/quazip/CMakeLists.txt # cmake/externals/vhacd/CMakeLists.txt # cmake/init.cmake # cmake/ports/hifi-deps/CONTROL # cmake/ports/sdl2/CONTROL # cmake/ports/sdl2/disable-hidapi-for-uwp.patch # cmake/ports/sdl2/enable-winrt-cmake.patch # cmake/ports/sdl2/fix-arm64-headers.patch # cmake/ports/sdl2/fix-x86-windows.patch # cmake/ports/sdl2/portfile.cmake # cmake/ports/sdl2/vcpkg-cmake-wrapper.cmake # cmake/ports/tbb/portfile.cmake # hifi_vcpkg.py # interface/src/avatar/MyAvatar.h # libraries/avatars-renderer/src/avatars-renderer/Avatar.h # libraries/avatars/src/AvatarData.h # libraries/entities-renderer/src/RenderableEntityItem.h # libraries/entities/src/EntityItem.cpp # libraries/entities/src/EntityItem.h # libraries/fbx/src/GLTFSerializer.cpp # libraries/graphics-scripting/src/graphics-scripting/Forward.h # libraries/networking/src/AddressManager.cpp # libraries/networking/src/DomainHandler.h # libraries/procedural/src/procedural/ProceduralMaterialCache.cpp # libraries/render-utils/src/HighlightEffect.cpp # libraries/render-utils/src/MeshPartPayload.cpp # libraries/render-utils/src/Model.cpp # libraries/render-utils/src/RenderShadowTask.cpp # libraries/script-engine/src/WebSocketClass.cpp
This commit is contained in:
commit
ffeb37e7aa
403 changed files with 27029 additions and 7470 deletions
46
.github/workflows/dump.yml
vendored
Normal file
46
.github/workflows/dump.yml
vendored
Normal file
|
@ -0,0 +1,46 @@
|
|||
name: Dump Contexts
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
|
||||
jobs:
|
||||
one:
|
||||
strategy:
|
||||
matrix:
|
||||
os: [[self-hosted, windows], macOS-latest]
|
||||
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- name: Dump GitHub context
|
||||
shell: bash
|
||||
env:
|
||||
GITHUB_CONTEXT: ${{ toJson(github) }}
|
||||
run: echo "$GITHUB_CONTEXT"
|
||||
- name: Dump job context
|
||||
shell: bash
|
||||
env:
|
||||
JOB_CONTEXT: ${{ toJson(job) }}
|
||||
run: echo "$JOB_CONTEXT"
|
||||
- name: Dump steps context
|
||||
shell: bash
|
||||
env:
|
||||
STEPS_CONTEXT: ${{ toJson(steps) }}
|
||||
run: echo "$STEPS_CONTEXT"
|
||||
- name: Dump runner context
|
||||
shell: bash
|
||||
env:
|
||||
RUNNER_CONTEXT: ${{ toJson(runner) }}
|
||||
run: echo "$RUNNER_CONTEXT"
|
||||
- name: Dump strategy context
|
||||
shell: bash
|
||||
env:
|
||||
STRATEGY_CONTEXT: ${{ toJson(strategy) }}
|
||||
run: echo "$STRATEGY_CONTEXT"
|
||||
- name: Dump matrix context
|
||||
shell: bash
|
||||
env:
|
||||
MATRIX_CONTEXT: ${{ toJson(matrix) }}
|
||||
run: echo "$MATRIX_CONTEXT"
|
256
.github/workflows/master_build.yml
vendored
Normal file
256
.github/workflows/master_build.yml
vendored
Normal file
|
@ -0,0 +1,256 @@
|
|||
name: Master CI Build
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
env:
|
||||
#APP_NAME: gpu-frame-player
|
||||
APP_NAME: interface
|
||||
BUILD_TYPE: Release
|
||||
BUCKET_NAME: hifi-gh-builds
|
||||
CI_BUILD: Github
|
||||
CMAKE_BACKTRACE_URL: https://highfidelity.sp.backtrace.io:6098
|
||||
CMAKE_BACKTRACE_TOKEN: ${{ secrets.backtrace_token }}
|
||||
CMAKE_BACKTRACE_SYMBOLS_TOKEN: ${{ secrets.backtrace_symbols_token }}
|
||||
GIT_COMMIT: ${{ github.sha }}
|
||||
HIFI_VCPKG_BOOTSTRAP: true
|
||||
LAUNCHER_HMAC_SECRET: ${{ secrets.launcher_hmac_secret }}
|
||||
OCULUS_APP_ID: '${{ secrets.oculus_app_id }}'
|
||||
RELEASE_TYPE: PRODUCTION
|
||||
RELEASE_DYNAMODB_V2: ReleaseManager2-ReleaseQueue-prod
|
||||
STABLE_BUILD: 0
|
||||
|
||||
|
||||
# OSX specific variables
|
||||
DEVELOPER_DIR: /Applications/Xcode_11.2.app/Contents/Developer
|
||||
MACOSX_DEPLOYMENT_TARGET: '10.11'
|
||||
|
||||
# WIN32 specific variables
|
||||
PreferredToolArchitecture: X64
|
||||
|
||||
# Mac OS
|
||||
#PLATFORM_CMAKE_GENERATOR=Xcode
|
||||
#PLATFORM_BUILD_ARGUMENTS=--config Release --target package
|
||||
#ARTIFACT_EXPRESSION=build/*.dmg,build/*.zip
|
||||
|
||||
# Windows
|
||||
#PLATFORM_CMAKE_GENERATOR=Visual Studio 15 2017 Win64
|
||||
#PLATFORM_BUILD_ARGUMENTS=--target package --config release
|
||||
#ARTIFACT_EXPRESSION=build/*.exe,build/*.zip,*-symbols.zip
|
||||
|
||||
# Ubuntu
|
||||
#PLATFORM_CMAKE_GENERATOR=Unix Makefiles
|
||||
#PLATFORM_BUILD_ARGUMENTS=--target all -- -j4
|
||||
#ARTIFACT_EXPRESSION=build/assignment-client/**,build/domain-server/**,build/ice-server/ice-server,build/tools/ice-client/ice-client,build/tools/ac-client/ac-client,build/tools/oven,build/ext/makefiles/nvtt/project/lib/**,build/ext/makefiles/quazip/project/lib/**
|
||||
|
||||
# Android
|
||||
# branch: master
|
||||
# GA_TRACKING_ID: ${{ secrets.ga_tracking_id }}
|
||||
# ANDROID_OAUTH_CLIENT_SECRET=${MASKED_ANDROID_OAUTH_CLIENT_SECRET_NIGHTLY}
|
||||
# ANDROID_OAUTH_CLIENT_ID=6c7d2349c0614640150db37457a1f75dce98a28ffe8f14d47f6cfae4de5b262a
|
||||
# ANDROID_OAUTH_REDIRECT_URI=https://dev-android-interface.highfidelity.com/auth
|
||||
# branch: !master
|
||||
# GA_TRACKING_ID=UA-39558647-11
|
||||
# ANDROID_OAUTH_CLIENT_SECRET=${MASKED_ANDROID_OAUTH_CLIENT_SECRET_RELEASE}
|
||||
# ANDROID_OAUTH_CLIENT_ID= c1063ea5d0b0c405e0c9cd77351328e211a91496a3f25985a99e861f1661db1d
|
||||
# ANDROID_OAUTH_REDIRECT_URI=https://android-interface.highfidelity.com/auth
|
||||
# ARTIFACT_EXPRESSION=android/*.apk
|
||||
# ANDROID_APK_NAME=HighFidelity-Beta-PR${RELEASE_NUMBER}-${GIT_COMMIT_SHORT}.apk
|
||||
# ANDROID_BUILT_APK_NAME=interface-debug.apk
|
||||
# ANDROID_APP=interface
|
||||
# ANDROID_BUILD_DIR=debug
|
||||
# ANDROID_BUILD_TARGET=assembleDebug
|
||||
# STABLE_BUILD=0
|
||||
|
||||
|
||||
|
||||
jobs:
|
||||
generate_build_number:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Generate build number
|
||||
id: buildnumber
|
||||
uses: highfidelity/build-number@v3
|
||||
with:
|
||||
token: ${{secrets.github_token}}
|
||||
- name: Upload build number
|
||||
uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: BUILD_NUMBER
|
||||
path: BUILD_NUMBER
|
||||
|
||||
build:
|
||||
strategy:
|
||||
matrix:
|
||||
os: [[self-hosted, windows], macOS-latest]
|
||||
build_type: [full, client]
|
||||
#os: [[self-hosted, windows], macOS-latest, ubuntu-latest]
|
||||
# exclude:
|
||||
# - os: ubuntu-latest
|
||||
# build_type: client
|
||||
runs-on: ${{matrix.os}}
|
||||
needs: generate_build_number
|
||||
steps:
|
||||
- name: Download build number
|
||||
uses: actions/download-artifact@v1
|
||||
with:
|
||||
name: BUILD_NUMBER
|
||||
- name: Restore build number
|
||||
id: buildnumber
|
||||
uses: highfidelity/build-number@v3
|
||||
with:
|
||||
output_name: RELEASE_NUMBER
|
||||
- name: Configure Build Environment 1
|
||||
shell: bash
|
||||
id: buildenv1
|
||||
run: |
|
||||
echo ::set-env name=UPLOAD_PREFIX::master
|
||||
echo ::set-env name=GIT_COMMIT_SHORT::`echo $GIT_COMMIT | cut -c1-7`
|
||||
# Linux build variables
|
||||
if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then
|
||||
echo ::set-env name=INSTALLER_EXT::tgz
|
||||
fi
|
||||
# Mac build variables
|
||||
if [ "${{ matrix.os }}" = "macOS-latest" ]; then
|
||||
echo ::set-env name=PYTHON_EXEC::python3
|
||||
echo ::set-env name=ZIP_COMMAND::zip
|
||||
echo ::set-env name=ZIP_ARGS::-r
|
||||
echo ::set-env name=INSTALLER_EXT::dmg
|
||||
echo ::set-env name=SYMBOL_REGEX::dSYM
|
||||
echo "::set-output name=symbols_archive::${{ steps.buildnumber.outputs.build_number }}-${{ matrix.build_type }}-mac-symbols.zip"
|
||||
fi
|
||||
# Windows build variables
|
||||
if [ "${{ matrix.os[1] }}" = "windows" ]; then
|
||||
echo ::set-env name=PYTHON_EXEC::python
|
||||
echo ::set-env name=ZIP_COMMAND::7z
|
||||
echo ::set-env name=ZIP_ARGS::a
|
||||
echo ::set-env name=INSTALLER_EXT::exe
|
||||
echo "::set-env name=SYMBOL_REGEX::\(exe\|dll\|pdb\)"
|
||||
echo "::set-output name=symbols_archive::${{ steps.buildnumber.outputs.build_number }}-${{ matrix.build_type }}-win-symbols.zip"
|
||||
fi
|
||||
# Configuration is broken into two steps because you can't set an env var and also reference it in the same step
|
||||
- name: Configure Build Environment 2
|
||||
shell: bash
|
||||
run: |
|
||||
echo "${{ steps.buildenv1.outputs.symbols_archive }}"
|
||||
echo ::set-env name=ARTIFACT_PATTERN::HighFidelity-Beta-*.$INSTALLER_EXT
|
||||
# Build type variables
|
||||
if [ "${{ matrix.build_type }}" = "full" ]; then
|
||||
echo ::set-env name=CLIENT_ONLY::FALSE
|
||||
echo ::set-env name=INSTALLER::HighFidelity-Beta-$RELEASE_NUMBER-$GIT_COMMIT_SHORT.$INSTALLER_EXT
|
||||
else
|
||||
echo ::set-env name=CLIENT_ONLY::TRUE
|
||||
echo ::set-env name=INSTALLER::HighFidelity-Beta-Interface-$RELEASE_NUMBER-$GIT_COMMIT_SHORT.$INSTALLER_EXT
|
||||
fi
|
||||
# Linux build variables
|
||||
if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then
|
||||
echo ::set-env name=PYTHON_EXEC::python3
|
||||
echo ::set-env name=CMAKE_EXTRA::""
|
||||
fi
|
||||
# Mac build variables
|
||||
if [ "${{ matrix.os }}" = "macOS-latest" ]; then
|
||||
echo ::set-env name=CMAKE_EXTRA::"-DCMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED=OFF -DOPENSSL_ROOT_DIR=/usr/local/opt/openssl -G Xcode"
|
||||
fi
|
||||
# Windows build variables
|
||||
if [ "${{ matrix.os[1] }}" = "windows" ]; then
|
||||
echo ::set-env name=CMAKE_EXTRA::"-A x64"
|
||||
echo ::set-env name=HF_PFX_PASSPHRASE::${{secrets.pfx_key}}
|
||||
echo "::set-env name=HF_PFX_FILE::${{runner.workspace}}\build\codesign.pfx"
|
||||
fi
|
||||
- name: Clear Working Directory
|
||||
if: matrix.os[1] == 'windows'
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}
|
||||
run: rm -rf ./*
|
||||
- uses: actions/checkout@v1
|
||||
with:
|
||||
submodules: true
|
||||
fetch-depth: 1
|
||||
- name: Create Build Directory
|
||||
run: cmake -E make_directory ${{runner.workspace}}/build
|
||||
- name: Decrypt Signing Key (Windows)
|
||||
if: matrix.os[1] == 'windows'
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: gpg --batch --yes -o codesign.pfx --passphrase "${{secrets.gpg_symmetric_key}}" --decrypt $GITHUB_WORKSPACE/tools/ci-scripts/codesign.pfx.gpg
|
||||
- name: Import Signing Key (Windows)
|
||||
if: matrix.os[1] == 'windows'
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: powershell
|
||||
run: |
|
||||
$mypwd=ConvertTo-SecureString -String ${{ secrets.pfx_key }} -Force -AsPlainText
|
||||
Import-PfxCertificate -Password $mypwd -CertStoreLocation Cert:\CurrentUser\My -FilePath ${{runner.workspace}}\build\codesign.pfx
|
||||
Import-PfxCertificate -Password $mypwd -CertStoreLocation Cert:\LocalMachine\My -FilePath ${{runner.workspace}}\build\codesign.pfx
|
||||
- name: Install Python modules
|
||||
if: matrix.os != 'ubuntu-latest'
|
||||
shell: bash
|
||||
run: $PYTHON_EXEC -m pip install boto3 PyGithub
|
||||
- name: Configure CMake
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCLIENT_ONLY:BOOLEAN=$CLIENT_ONLY $CMAKE_EXTRA
|
||||
- name: Build Application
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target $APP_NAME
|
||||
- name: Build Console
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target packaged-server-console
|
||||
- name: Build Domain Server (FullBuild)
|
||||
if: matrix.build_type == 'full'
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
run: cmake --build . --config $BUILD_TYPE --target domain-server
|
||||
- name: Build Assignment Client (FullBuild)
|
||||
if: matrix.build_type == 'full'
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
run: cmake --build . --config $BUILD_TYPE --target assignment-client
|
||||
- name: Build Installer
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target package
|
||||
- name: Sign Installer (Windows)
|
||||
if: matrix.os[1] == 'windows'
|
||||
shell: powershell
|
||||
working-directory: C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x64
|
||||
run: .\signtool.exe sign /fd sha256 /f ${{runner.workspace}}\build\codesign.pfx /p ${{secrets.pfx_key}} /tr http://sha256timestamp.ws.symantec.com/sha256/timestamp /td SHA256 ${{runner.workspace}}\build\${env:INSTALLER}
|
||||
- name: Upload Artifact
|
||||
if: matrix.os != 'ubuntu-latest'
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
env:
|
||||
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
|
||||
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
|
||||
run: $PYTHON_EXEC $GITHUB_WORKSPACE/tools/ci-scripts/upload.py
|
||||
- name: Archive Symbols
|
||||
if: (matrix.os[1] == 'windows') || (matrix.os == 'macOS-latest')
|
||||
working-directory: ${{runner.workspace}}
|
||||
shell: bash
|
||||
run: |
|
||||
SYMBOLS_TEMP="symbols-temp"
|
||||
mkdir $SYMBOLS_TEMP
|
||||
find "./build" \( -path '*/tools/gpu-frame-player/*' -or -path '*/interface/*' -or -path '*/plugins/*' \) -regex ".*\.$SYMBOL_REGEX" -exec cp -r {} $SYMBOLS_TEMP \;
|
||||
cd $SYMBOLS_TEMP
|
||||
$ZIP_COMMAND $ZIP_ARGS ../${{ steps.buildenv1.outputs.symbols_archive }} .
|
||||
- name: Upload Symbols
|
||||
if: (matrix.os[1] == 'windows') || (matrix.os == 'macOS-latest')
|
||||
working-directory: ${{runner.workspace}}
|
||||
shell: bash
|
||||
run: |
|
||||
curl --data-binary @${{ steps.buildenv1.outputs.symbols_archive }} "$CMAKE_BACKTRACE_URL/post?format=symbols&token=$CMAKE_BACKTRACE_SYMBOLS_TOKEN&upload_file=${{steps.buildenv1.outputs.symbols_archive}}&tag=$RELEASE_NUMBER"
|
||||
# - name: Debug List Symbols
|
||||
# if: (matrix.os[1] == 'windows') || (matrix.os == 'macOS-latest')
|
||||
# working-directory: ${{runner.workspace}}
|
||||
# shell: bash
|
||||
# run: |
|
||||
# unzip -v "${{runner.workspace}}/${{ steps.buildenv1.outputs.symbols_archive }}"
|
||||
# - name: Debug Upload Symbols Artifact
|
||||
# if: (matrix.os[1] == 'windows') || (matrix.os == 'macOS-latest')
|
||||
# uses: actions/upload-artifact@v1
|
||||
# with:
|
||||
# name: symbols
|
||||
# path: ${{runner.workspace}}/${{ steps.buildenv1.outputs.symbols_archive }}
|
133
.github/workflows/pr_build.yml
vendored
Normal file
133
.github/workflows/pr_build.yml
vendored
Normal file
|
@ -0,0 +1,133 @@
|
|||
name: Pull Request CI Build
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types: [opened, synchronize, reopened, labeled]
|
||||
|
||||
env:
|
||||
APP_NAME: interface
|
||||
BUILD_TYPE: Release
|
||||
CI_BUILD: Github
|
||||
GIT_COMMIT: ${{ github.sha }}
|
||||
HIFI_VCPKG_BOOTSTRAP: true
|
||||
RELEASE_TYPE: PR
|
||||
RELEASE_NUMBER: ${{ github.event.number }}
|
||||
VERSION_CODE: ${{ github.event.number }}
|
||||
|
||||
|
||||
# OSX specific variables
|
||||
DEVELOPER_DIR: /Applications/Xcode_11.2.app/Contents/Developer
|
||||
MACOSX_DEPLOYMENT_TARGET: '10.11'
|
||||
|
||||
# WIN32 specific variables
|
||||
PreferredToolArchitecture: X64
|
||||
GIT_COMMIT_SHORT: ${{ github.sha }}
|
||||
|
||||
|
||||
jobs:
|
||||
build:
|
||||
strategy:
|
||||
matrix:
|
||||
os: [[self-hosted, windows], macOS-latest]
|
||||
build_type: [full]
|
||||
fail-fast: false
|
||||
runs-on: ${{matrix.os}}
|
||||
if: github.event.action != 'labeled' || github.event.label.name == 'rebuild'
|
||||
steps:
|
||||
- name: Configure Build Environment 1
|
||||
shell: bash
|
||||
id: buildenv1
|
||||
run: |
|
||||
echo ::set-env name=GIT_COMMIT_SHORT::`echo $GIT_COMMIT | cut -c1-7`
|
||||
# Linux build variables
|
||||
if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then
|
||||
echo ::set-env name=PYTHON_EXEC::python3
|
||||
echo ::set-env name=INSTALLER_EXT::tgz
|
||||
fi
|
||||
# Mac build variables
|
||||
if [ "${{ matrix.os }}" = "macOS-latest" ]; then
|
||||
echo ::set-env name=PYTHON_EXEC::python3
|
||||
echo ::set-env name=INSTALLER_EXT::dmg
|
||||
echo ::set-env name=CMAKE_EXTRA::"-DCMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED=OFF -DOPENSSL_ROOT_DIR=/usr/local/opt/openssl -G Xcode"
|
||||
fi
|
||||
# Windows build variables
|
||||
if [ "${{ matrix.os[1] }}" = "windows" ]; then
|
||||
echo ::set-env name=PYTHON_EXEC::python
|
||||
echo ::set-env name=INSTALLER_EXT::exe
|
||||
echo ::set-env name=CMAKE_EXTRA::"-A x64"
|
||||
fi
|
||||
# Configuration is broken into two steps because you can't set an env var and also reference it in the same step
|
||||
- name: Configure Build Environment 2
|
||||
shell: bash
|
||||
run: |
|
||||
echo "${{ steps.buildenv1.outputs.symbols_archive }}"
|
||||
echo ::set-env name=ARTIFACT_PATTERN::HighFidelity-Beta-*.$INSTALLER_EXT
|
||||
# Build type variables
|
||||
echo ::set-env name=INSTALLER::HighFidelity-Beta-$RELEASE_NUMBER-$GIT_COMMIT_SHORT.$INSTALLER_EXT
|
||||
- name: Clear Working Directory
|
||||
if: matrix.os[1] == 'windows'
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}
|
||||
run: rm -rf ./*
|
||||
- uses: actions/checkout@v1
|
||||
with:
|
||||
submodules: true
|
||||
fetch-depth: 1
|
||||
- name: Create Build Environment
|
||||
shell: bash
|
||||
run: cmake -E make_directory "${{runner.workspace}}/build"
|
||||
- name: Configure CMake
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE $CMAKE_EXTRA
|
||||
- name: Build Application
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target $APP_NAME
|
||||
- name: Build Domain Server
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target domain-server
|
||||
- name: Build Assignment Client
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target assignment-client
|
||||
- name: Build Console
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target packaged-server-console
|
||||
- name: Build Installer
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake --build . --config $BUILD_TYPE --target package
|
||||
- name: Output Installer Logs
|
||||
if: failure() && matrix.os[1] == 'windows'
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
run: cat ./_CPack_Packages/win64/NSIS/NSISOutput.log
|
||||
|
||||
build_full_linux:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.event.action != 'labeled' || github.event.label.name == 'rebuild'
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
with:
|
||||
submodules: true
|
||||
fetch-depth: 1
|
||||
- name: Update apt repository index
|
||||
run: sudo apt update
|
||||
- name: Install apt packages
|
||||
run: sudo apt install -y mesa-common-dev libegl1 libglvnd-dev libdouble-conversion1 libpulse0
|
||||
- name: Install python modules
|
||||
shell: bash
|
||||
run: pip install boto3 PyGithub
|
||||
- name: Create Build Environment
|
||||
run: cmake -E make_directory ${{runner.workspace}}/build
|
||||
- name: Configure CMake
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
shell: bash
|
||||
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DBUILD_TOOLS:BOOLEAN=FALSE
|
||||
- name:
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}/build
|
||||
run: cmake --build . -- -j3
|
2
BUILD.md
2
BUILD.md
|
@ -13,6 +13,8 @@
|
|||
- [git](https://git-scm.com/downloads): >= 1.6
|
||||
- [cmake](https://cmake.org/download/): 3.9
|
||||
- [Python](https://www.python.org/downloads/): 3.6 or higher
|
||||
- [Node.JS](https://nodejs.org/en/): >= 12.13.1 LTS
|
||||
- Used to build the Screen Sharing executable.
|
||||
|
||||
### CMake External Project Dependencies
|
||||
|
||||
|
|
|
@ -53,7 +53,7 @@ endif()
|
|||
# (needs to be set before first project() call and before prebuild.py)
|
||||
# Will affect VCPKG dependencies
|
||||
if (APPLE)
|
||||
set(ENV{MACOSX_DEPLOYMENT_TARGET} 10.9)
|
||||
set(ENV{MACOSX_DEPLOYMENT_TARGET} 10.11)
|
||||
endif()
|
||||
|
||||
set(RELEASE_TYPE "$ENV{RELEASE_TYPE}")
|
||||
|
@ -82,9 +82,21 @@ if(NOT EXISTS "${CMAKE_BINARY_DIR}/vcpkg.cmake")
|
|||
endif()
|
||||
include("${CMAKE_BINARY_DIR}/vcpkg.cmake")
|
||||
|
||||
if (HIFI_ANDROID)
|
||||
set(QT_CMAKE_PREFIX_PATH "$ENV{HIFI_ANDROID_PRECOMPILED}/qt/lib/cmake")
|
||||
else()
|
||||
if(NOT EXISTS "${CMAKE_BINARY_DIR}/qt.cmake")
|
||||
message(FATAL_ERROR "qt configuration missing.")
|
||||
endif()
|
||||
include("${CMAKE_BINARY_DIR}/qt.cmake")
|
||||
endif()
|
||||
|
||||
option(VCPKG_APPLOCAL_DEPS OFF)
|
||||
|
||||
project(athena)
|
||||
include("cmake/init.cmake")
|
||||
include("cmake/compiler.cmake")
|
||||
option(VCPKG_APPLOCAL_DEPS OFF)
|
||||
|
||||
add_paths_to_fixup_libs(${VCPKG_INSTALL_ROOT}/bin)
|
||||
add_paths_to_fixup_libs(${VCPKG_INSTALL_ROOT}/debug/bin)
|
||||
|
@ -254,6 +266,7 @@ find_package( Threads )
|
|||
add_definitions(-DGLM_FORCE_RADIANS)
|
||||
add_definitions(-DGLM_ENABLE_EXPERIMENTAL)
|
||||
add_definitions(-DGLM_FORCE_CTOR_INIT)
|
||||
add_definitions(-DGLM_LANG_STL11_FORCED) # Workaround for GLM not detecting support for C++11 templates on Android
|
||||
|
||||
if (WIN32)
|
||||
# Deal with fakakta Visual Studo 2017 bug
|
||||
|
@ -278,6 +291,11 @@ if (ANDROID)
|
|||
return()
|
||||
endif()
|
||||
|
||||
if (BUILD_GPU_FRAME_PLAYER_ONLY)
|
||||
# This is for CI build testing
|
||||
add_subdirectory(tools/gpu-frame-player)
|
||||
else()
|
||||
|
||||
# add subdirectories for all targets
|
||||
if (BUILD_SERVER)
|
||||
add_subdirectory(assignment-client)
|
||||
|
@ -290,6 +308,7 @@ endif()
|
|||
|
||||
if (BUILD_CLIENT)
|
||||
add_subdirectory(interface)
|
||||
add_subdirectory(screenshare)
|
||||
set_target_properties(interface PROPERTIES FOLDER "Apps")
|
||||
|
||||
option(USE_SIXENSE "Build Interface with sixense library/plugin" OFF)
|
||||
|
@ -303,6 +322,8 @@ endif()
|
|||
# BUILD_TOOLS option will be handled inside the tools's CMakeLists.txt because 'scribe' tool is required for build anyway
|
||||
add_subdirectory(tools)
|
||||
|
||||
endif()
|
||||
|
||||
if (BUILD_TESTS)
|
||||
# Turn on testing so that add_test works
|
||||
# MUST be in the root cmake file for ctest to work
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
<uses-feature android:name="android.hardware.sensor.gyroscope" android:required="true"/>
|
||||
<uses-feature android:name="android.software.vr.mode" android:required="true"/>
|
||||
<uses-feature android:name="android.hardware.vr.high_performance" android:required="true"/>
|
||||
<uses-feature android:name="android.hardware.vr.headtracking" android:version="1" android:required="true" />
|
||||
|
||||
<application
|
||||
android:name="org.qtproject.qt5.android.bindings.QtApplication"
|
||||
|
|
|
@ -29,6 +29,7 @@ docker run \
|
|||
-e CMAKE_BACKTRACE_TOKEN \
|
||||
-e CMAKE_BACKTRACE_SYMBOLS_TOKEN \
|
||||
-e GA_TRACKING_ID \
|
||||
-e GIT_COMMIT \
|
||||
-e OAUTH_CLIENT_SECRET \
|
||||
-e OAUTH_CLIENT_ID \
|
||||
-e OAUTH_REDIRECT_URI \
|
||||
|
|
|
@ -18,21 +18,23 @@ link_hifi_libraries(
|
|||
)
|
||||
include_hifi_library_headers(procedural)
|
||||
|
||||
add_dependencies(${TARGET_NAME} oven)
|
||||
if (BUILD_TOOLS)
|
||||
add_dependencies(${TARGET_NAME} oven)
|
||||
|
||||
if (WIN32)
|
||||
if (WIN32)
|
||||
add_custom_command(
|
||||
TARGET ${TARGET_NAME} POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||
$<TARGET_FILE_DIR:oven>
|
||||
$<TARGET_FILE_DIR:${TARGET_NAME}>)
|
||||
else()
|
||||
else()
|
||||
add_custom_command(
|
||||
TARGET ${TARGET_NAME} POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink
|
||||
$<TARGET_FILE:oven>
|
||||
$<TARGET_FILE_DIR:${TARGET_NAME}>/oven)
|
||||
endif()
|
||||
endif()
|
||||
endif (BUILD_TOOLS)
|
||||
|
||||
if (WIN32)
|
||||
package_libraries_for_deployment()
|
||||
|
|
|
@ -782,7 +782,7 @@ float computeGain(float masterAvatarGain,
|
|||
gain *= std::max(1.0f - d / (distanceLimit - ATTN_DISTANCE_REF), 0.0f);
|
||||
gain = std::min(gain, ATTN_GAIN_MAX);
|
||||
|
||||
} else {
|
||||
} else if (attenuationPerDoublingInDistance < 1.0f) {
|
||||
// translate a positive zone setting to gain per log2(distance)
|
||||
const float MIN_ATTENUATION_COEFFICIENT = 0.001f; // -60dB per log2(distance)
|
||||
float g = glm::clamp(1.0f - attenuationPerDoublingInDistance, MIN_ATTENUATION_COEFFICIENT, 1.0f);
|
||||
|
@ -792,6 +792,10 @@ float computeGain(float masterAvatarGain,
|
|||
float d = (1.0f / ATTN_DISTANCE_REF) * std::max(distance, HRTF_NEARFIELD_MIN);
|
||||
gain *= fastExp2f(fastLog2f(g) * fastLog2f(d));
|
||||
gain = std::min(gain, ATTN_GAIN_MAX);
|
||||
|
||||
} else {
|
||||
// translate a zone setting of 1.0 be silent at any distance
|
||||
gain = 0.0f;
|
||||
}
|
||||
|
||||
return gain;
|
||||
|
|
|
@ -1081,6 +1081,12 @@ void AvatarMixer::setupEntityQuery() {
|
|||
priorityZoneQuery["avatarPriority"] = true;
|
||||
priorityZoneQuery["type"] = "Zone";
|
||||
|
||||
QJsonObject queryFlags;
|
||||
queryFlags["includeAncestors"] = true;
|
||||
queryFlags["includeDescendants"] = true;
|
||||
priorityZoneQuery["flags"] = queryFlags;
|
||||
priorityZoneQuery["name"] = true; // Handy for debugging.
|
||||
|
||||
_entityViewer.getOctreeQuery().setJSONParameters(priorityZoneQuery);
|
||||
_slaveSharedData.entityTree = entityTree;
|
||||
}
|
||||
|
|
|
@ -23,8 +23,7 @@
|
|||
|
||||
#include "AvatarMixerSlave.h"
|
||||
|
||||
AvatarMixerClientData::AvatarMixerClientData(const QUuid& nodeID, Node::LocalID nodeLocalID) :
|
||||
NodeData(nodeID, nodeLocalID) {
|
||||
AvatarMixerClientData::AvatarMixerClientData(const QUuid& nodeID, Node::LocalID nodeLocalID) : NodeData(nodeID, nodeLocalID) {
|
||||
// in case somebody calls getSessionUUID on the AvatarData instance, make sure it has the right ID
|
||||
_avatar->setID(nodeID);
|
||||
}
|
||||
|
@ -92,28 +91,37 @@ int AvatarMixerClientData::processPackets(const SlaveSharedData& slaveSharedData
|
|||
}
|
||||
|
||||
namespace {
|
||||
using std::static_pointer_cast;
|
||||
using std::static_pointer_cast;
|
||||
|
||||
// Operator to find if a point is within an avatar-priority (hero) Zone Entity.
|
||||
struct FindPriorityZone {
|
||||
// Operator to find if a point is within an avatar-priority (hero) Zone Entity.
|
||||
struct FindContainingZone {
|
||||
glm::vec3 position;
|
||||
bool isInPriorityZone { false };
|
||||
float zoneVolume { std::numeric_limits<float>::max() };
|
||||
bool isInScreenshareZone { false };
|
||||
float priorityZoneVolume { std::numeric_limits<float>::max() };
|
||||
float screenshareZoneVolume { priorityZoneVolume };
|
||||
EntityItemID screenshareZoneid{};
|
||||
|
||||
static bool operation(const OctreeElementPointer& element, void* extraData) {
|
||||
auto findPriorityZone = static_cast<FindPriorityZone*>(extraData);
|
||||
if (element->getAACube().contains(findPriorityZone->position)) {
|
||||
auto findContainingZone = static_cast<FindContainingZone*>(extraData);
|
||||
if (element->getAACube().contains(findContainingZone->position)) {
|
||||
const EntityTreeElementPointer entityTreeElement = static_pointer_cast<EntityTreeElement>(element);
|
||||
entityTreeElement->forEachEntity([&findPriorityZone](EntityItemPointer item) {
|
||||
if (item->getType() == EntityTypes::Zone
|
||||
&& item->contains(findPriorityZone->position)) {
|
||||
entityTreeElement->forEachEntity([&findContainingZone](EntityItemPointer item) {
|
||||
if (item->getType() == EntityTypes::Zone && item->contains(findContainingZone->position)) {
|
||||
auto zoneItem = static_pointer_cast<ZoneEntityItem>(item);
|
||||
if (zoneItem->getAvatarPriority() != COMPONENT_MODE_INHERIT) {
|
||||
auto avatarPriorityProperty = zoneItem->getAvatarPriority();
|
||||
auto screenshareProperty = zoneItem->getScreenshare();
|
||||
float volume = zoneItem->getVolumeEstimate();
|
||||
if (volume < findPriorityZone->zoneVolume) { // Smaller volume wins
|
||||
findPriorityZone->isInPriorityZone = zoneItem->getAvatarPriority() == COMPONENT_MODE_ENABLED;
|
||||
findPriorityZone->zoneVolume = volume;
|
||||
if (avatarPriorityProperty != COMPONENT_MODE_INHERIT
|
||||
&& volume < findContainingZone->priorityZoneVolume) { // Smaller volume wins
|
||||
findContainingZone->isInPriorityZone = avatarPriorityProperty == COMPONENT_MODE_ENABLED;
|
||||
findContainingZone->priorityZoneVolume = volume;
|
||||
}
|
||||
if (screenshareProperty != COMPONENT_MODE_INHERIT
|
||||
&& volume < findContainingZone->screenshareZoneVolume) {
|
||||
findContainingZone->isInScreenshareZone = screenshareProperty == COMPONENT_MODE_ENABLED;
|
||||
findContainingZone->screenshareZoneVolume = volume;
|
||||
findContainingZone->screenshareZoneid = zoneItem->getEntityItemID();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -122,9 +130,9 @@ namespace {
|
|||
return false;
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
} // Close anonymous namespace.
|
||||
} // namespace
|
||||
|
||||
int AvatarMixerClientData::parseData(ReceivedMessage& message, const SlaveSharedData& slaveSharedData) {
|
||||
// pull the sequence number from the data first
|
||||
|
@ -150,9 +158,24 @@ int AvatarMixerClientData::parseData(ReceivedMessage& message, const SlaveShared
|
|||
auto newPosition = _avatar->getClientGlobalPosition();
|
||||
if (newPosition != oldPosition || _avatar->getNeedsHeroCheck()) {
|
||||
EntityTree& entityTree = *slaveSharedData.entityTree;
|
||||
FindPriorityZone findPriorityZone { newPosition } ;
|
||||
entityTree.recurseTreeWithOperation(&FindPriorityZone::operation, &findPriorityZone);
|
||||
_avatar->setHasPriority(findPriorityZone.isInPriorityZone);
|
||||
FindContainingZone findContainingZone{ newPosition };
|
||||
entityTree.recurseTreeWithOperation(&FindContainingZone::operation, &findContainingZone);
|
||||
bool currentlyHasPriority = findContainingZone.isInPriorityZone;
|
||||
if (currentlyHasPriority != _avatar->getHasPriority()) {
|
||||
_avatar->setHasPriority(currentlyHasPriority);
|
||||
}
|
||||
bool isInScreenshareZone = findContainingZone.isInScreenshareZone;
|
||||
if (isInScreenshareZone != _avatar->isInScreenshareZone()
|
||||
|| findContainingZone.screenshareZoneid != _avatar->getScreenshareZone()) {
|
||||
_avatar->setInScreenshareZone(isInScreenshareZone);
|
||||
_avatar->setScreenshareZone(findContainingZone.screenshareZoneid);
|
||||
const QUuid& zoneId = isInScreenshareZone ? findContainingZone.screenshareZoneid : QUuid();
|
||||
auto nodeList = DependencyManager::get<NodeList>();
|
||||
auto packet = NLPacket::create(PacketType::AvatarZonePresence, 2 * NUM_BYTES_RFC4122_UUID, true);
|
||||
packet->write(_avatar->getSessionUUID().toRfc4122());
|
||||
packet->write(zoneId.toRfc4122());
|
||||
nodeList->sendPacket(std::move(packet), nodeList->getDomainSockAddr());
|
||||
}
|
||||
_avatar->setNeedsHeroCheck(false);
|
||||
}
|
||||
|
||||
|
@ -217,8 +240,7 @@ void AvatarMixerClientData::processSetTraitsMessage(ReceivedMessage& message,
|
|||
}
|
||||
} else {
|
||||
// Trying to read more bytes than available, bail
|
||||
if (message.getBytesLeftToRead() < qint64(NUM_BYTES_RFC4122_UUID +
|
||||
sizeof(AvatarTraits::TraitWireSize))) {
|
||||
if (message.getBytesLeftToRead() < qint64(NUM_BYTES_RFC4122_UUID + sizeof(AvatarTraits::TraitWireSize))) {
|
||||
qWarning() << "Refusing to process malformed traits packet from" << message.getSenderSockAddr();
|
||||
return;
|
||||
}
|
||||
|
@ -234,8 +256,7 @@ void AvatarMixerClientData::processSetTraitsMessage(ReceivedMessage& message,
|
|||
break;
|
||||
}
|
||||
|
||||
if (traitType == AvatarTraits::AvatarEntity ||
|
||||
traitType == AvatarTraits::Grab) {
|
||||
if (traitType == AvatarTraits::AvatarEntity || traitType == AvatarTraits::Grab) {
|
||||
auto& instanceVersionRef = _lastReceivedTraitVersions.getInstanceValueRef(traitType, instanceID);
|
||||
|
||||
if (packetTraitVersion > instanceVersionRef) {
|
||||
|
@ -293,7 +314,8 @@ void AvatarMixerClientData::processBulkAvatarTraitsAckMessage(ReceivedMessage& m
|
|||
auto simpleReceivedIt = traitVersions.simpleCBegin();
|
||||
while (simpleReceivedIt != traitVersions.simpleCEnd()) {
|
||||
if (*simpleReceivedIt != AvatarTraits::DEFAULT_TRAIT_VERSION) {
|
||||
auto traitType = static_cast<AvatarTraits::TraitType>(std::distance(traitVersions.simpleCBegin(), simpleReceivedIt));
|
||||
auto traitType =
|
||||
static_cast<AvatarTraits::TraitType>(std::distance(traitVersions.simpleCBegin(), simpleReceivedIt));
|
||||
_perNodeAckedTraitVersions[nodeId][traitType] = *simpleReceivedIt;
|
||||
}
|
||||
simpleReceivedIt++;
|
||||
|
@ -351,8 +373,8 @@ void AvatarMixerClientData::checkSkeletonURLAgainstWhitelist(const SlaveSharedDa
|
|||
// make sure we're not unecessarily overriding the default avatar with the default avatar
|
||||
if (_avatar->getWireSafeSkeletonModelURL() != slaveSharedData.skeletonReplacementURL) {
|
||||
// we need to change this avatar's skeleton URL, and send them a traits packet informing them of the change
|
||||
qDebug() << "Overwriting avatar URL" << _avatar->getWireSafeSkeletonModelURL()
|
||||
<< "to replacement" << slaveSharedData.skeletonReplacementURL << "for" << sendingNode.getUUID();
|
||||
qDebug() << "Overwriting avatar URL" << _avatar->getWireSafeSkeletonModelURL() << "to replacement"
|
||||
<< slaveSharedData.skeletonReplacementURL << "for" << sendingNode.getUUID();
|
||||
_avatar->setSkeletonModelURL(slaveSharedData.skeletonReplacementURL);
|
||||
|
||||
auto packet = NLPacket::create(PacketType::SetAvatarTraits, -1, true);
|
||||
|
@ -453,9 +475,7 @@ void AvatarMixerClientData::readViewFrustumPacket(const QByteArray& message) {
|
|||
|
||||
bool AvatarMixerClientData::otherAvatarInView(const AABox& otherAvatarBox) {
|
||||
return std::any_of(std::begin(_currentViewFrustums), std::end(_currentViewFrustums),
|
||||
[&](const ConicalViewFrustum& viewFrustum) {
|
||||
return viewFrustum.intersects(otherAvatarBox);
|
||||
});
|
||||
[&](const ConicalViewFrustum& viewFrustum) { return viewFrustum.intersects(otherAvatarBox); });
|
||||
}
|
||||
|
||||
void AvatarMixerClientData::loadJSONStats(QJsonObject& jsonObject) const {
|
||||
|
@ -474,7 +494,8 @@ void AvatarMixerClientData::loadJSONStats(QJsonObject& jsonObject) const {
|
|||
jsonObject["recent_other_av_out_of_view"] = _recentOtherAvatarsOutOfView;
|
||||
}
|
||||
|
||||
AvatarMixerClientData::TraitsCheckTimestamp AvatarMixerClientData::getLastOtherAvatarTraitsSendPoint(Node::LocalID otherAvatar) const {
|
||||
AvatarMixerClientData::TraitsCheckTimestamp AvatarMixerClientData::getLastOtherAvatarTraitsSendPoint(
|
||||
Node::LocalID otherAvatar) const {
|
||||
auto it = _lastSentTraitsTimestamps.find(otherAvatar);
|
||||
|
||||
if (it != _lastSentTraitsTimestamps.end()) {
|
||||
|
|
|
@ -43,6 +43,11 @@ public:
|
|||
};
|
||||
Q_ENUM(VerifyState)
|
||||
|
||||
bool isInScreenshareZone() const { return _inScreenshareZone; }
|
||||
void setInScreenshareZone(bool value = true) { _inScreenshareZone = value; }
|
||||
const QUuid& getScreenshareZone() const { return _screenshareZone; }
|
||||
void setScreenshareZone(QUuid zone) { _screenshareZone = zone; }
|
||||
|
||||
private:
|
||||
bool _needsHeroCheck { false };
|
||||
static const char* stateToName(VerifyState state);
|
||||
|
@ -65,6 +70,8 @@ private:
|
|||
int _numberChallenges { 0 };
|
||||
bool _certifyFailed { false };
|
||||
bool _needsIdentityUpdate { false };
|
||||
bool _inScreenshareZone { false };
|
||||
QUuid _screenshareZone;
|
||||
|
||||
bool generateFSTHash();
|
||||
bool validateFSTHash(const QString& publicKey) const;
|
||||
|
|
|
@ -144,10 +144,10 @@ void ScriptableAvatar::update(float deltatime) {
|
|||
}
|
||||
_animationDetails.currentFrame = currentFrame;
|
||||
|
||||
const QVector<HFMJoint>& modelJoints = _bind->getHFMModel().joints;
|
||||
const std::vector<HFMJoint>& modelJoints = _bind->getHFMModel().joints;
|
||||
QStringList animationJointNames = _animation->getJointNames();
|
||||
|
||||
const int nJoints = modelJoints.size();
|
||||
const auto nJoints = (int)modelJoints.size();
|
||||
if (_jointData.size() != nJoints) {
|
||||
_jointData.resize(nJoints);
|
||||
}
|
||||
|
@ -280,6 +280,17 @@ void ScriptableAvatar::setJointMappingsFromNetworkReply() {
|
|||
}
|
||||
|
||||
AvatarEntityMap ScriptableAvatar::getAvatarEntityData() const {
|
||||
auto data = getAvatarEntityDataInternal(true);
|
||||
return data;
|
||||
}
|
||||
|
||||
AvatarEntityMap ScriptableAvatar::getAvatarEntityDataNonDefault() const {
|
||||
auto data = getAvatarEntityDataInternal(false);
|
||||
return data;
|
||||
|
||||
}
|
||||
|
||||
AvatarEntityMap ScriptableAvatar::getAvatarEntityDataInternal(bool allProperties) const {
|
||||
// DANGER: Now that we store the AvatarEntityData in packed format this call is potentially Very Expensive!
|
||||
// Avoid calling this method if possible.
|
||||
AvatarEntityMap data;
|
||||
|
@ -288,9 +299,18 @@ AvatarEntityMap ScriptableAvatar::getAvatarEntityData() const {
|
|||
for (const auto& itr : _entities) {
|
||||
QUuid id = itr.first;
|
||||
EntityItemPointer entity = itr.second;
|
||||
EntityItemProperties properties = entity->getProperties();
|
||||
|
||||
EncodeBitstreamParams params;
|
||||
auto desiredProperties = entity->getEntityProperties(params);
|
||||
desiredProperties += PROP_LOCAL_POSITION;
|
||||
desiredProperties += PROP_LOCAL_ROTATION;
|
||||
desiredProperties += PROP_LOCAL_VELOCITY;
|
||||
desiredProperties += PROP_LOCAL_ANGULAR_VELOCITY;
|
||||
desiredProperties += PROP_LOCAL_DIMENSIONS;
|
||||
EntityItemProperties properties = entity->getProperties(desiredProperties);
|
||||
|
||||
QByteArray blob;
|
||||
EntityItemProperties::propertiesToBlob(_scriptEngine, sessionID, properties, blob);
|
||||
EntityItemProperties::propertiesToBlob(_scriptEngine, sessionID, properties, blob, allProperties);
|
||||
data[id] = blob;
|
||||
}
|
||||
});
|
||||
|
|
|
@ -76,6 +76,22 @@
|
|||
* size in the virtual world. <em>Read-only.</em>
|
||||
* @property {boolean} hasPriority - <code>true</code> if the avatar is in a "hero" zone, <code>false</code> if it isn't.
|
||||
* <em>Read-only.</em>
|
||||
* @property {boolean} hasScriptedBlendshapes=false - <code>true</code> if blend shapes are controlled by scripted actions,
|
||||
* otherwise <code>false</code>. Set this to <code>true</code> before using the {@link MyAvatar.setBlendshape} method,
|
||||
* and set back to <code>false</code> after you no longer want scripted control over the blend shapes.
|
||||
* <p><strong>Note:</strong> This property will automatically be set to true if the Controller system has valid facial
|
||||
* blend shape actions.</p>
|
||||
* @property {boolean} hasProceduralBlinkFaceMovement=true - <code>true</code> if avatars blink automatically by animating
|
||||
* facial blend shapes, <code>false</code> if automatic blinking is disabled. Set this property to <code>false</code> if
|
||||
* you wish to fully control the blink facial blend shapes via the {@link MyAvatar.setBlendshape} method.
|
||||
* @property {boolean} hasProceduralEyeFaceMovement=true - <code>true</code> if the facial blend shapes for an avatar's eyes
|
||||
* adjust automatically as the eyes move, <code>false</code> if this automatic movement is disabled. Set this property
|
||||
* to <code>true</code> to prevent the iris from being obscured by the upper or lower lids. Set this property to
|
||||
* <code>false</code> if you wish to fully control the eye blend shapes via the {@link MyAvatar.setBlendshape} method.
|
||||
* @property {boolean} hasAudioEnabledFaceMovement=true - <code>true</code> if the avatar's mouth blend shapes animate
|
||||
* automatically based on detected microphone input, <code>false</code> if this automatic movement is disabled. Set
|
||||
* this property to <code>false</code> if you wish to fully control the mouth facial blend shapes via the
|
||||
* {@link MyAvatar.setBlendshape} method.
|
||||
*
|
||||
* @example <caption>Create a scriptable avatar.</caption>
|
||||
* (function () {
|
||||
|
@ -157,13 +173,17 @@ public:
|
|||
* Gets details of all avatar entities.
|
||||
* <p><strong>Warning:</strong> Potentially an expensive call. Do not use if possible.</p>
|
||||
* @function Avatar.getAvatarEntityData
|
||||
* @returns {AvatarEntityMap} Details of the avatar entities.
|
||||
* @returns {AvatarEntityMap} Details of all avatar entities.
|
||||
* @example <caption>Report the current avatar entities.</caption>
|
||||
* var avatarEntityData = Avatar.getAvatarEntityData();
|
||||
* print("Avatar entities: " + JSON.stringify(avatarEntityData));
|
||||
*/
|
||||
Q_INVOKABLE AvatarEntityMap getAvatarEntityData() const override;
|
||||
|
||||
AvatarEntityMap getAvatarEntityDataNonDefault() const override;
|
||||
|
||||
AvatarEntityMap getAvatarEntityDataInternal(bool allProperties) const;
|
||||
|
||||
/**jsdoc
|
||||
* Sets all avatar entities from an object.
|
||||
* <p><strong>Warning:</strong> Potentially an expensive call. Do not use if possible.</p>
|
||||
|
|
|
@ -61,6 +61,8 @@ endif ()
|
|||
|
||||
if (APPLE)
|
||||
set(CMAKE_XCODE_ATTRIBUTE_OTHER_CODE_SIGN_FLAGS "--deep")
|
||||
set(CMAKE_XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "")
|
||||
set(CMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED "NO")
|
||||
endif()
|
||||
|
||||
if (UNIX)
|
||||
|
|
14
cmake/macros/DumpCmakeVariables.cmake
Normal file
14
cmake/macros/DumpCmakeVariables.cmake
Normal file
|
@ -0,0 +1,14 @@
|
|||
function(dump_cmake_variables)
|
||||
get_cmake_property(_variableNames VARIABLES)
|
||||
list (SORT _variableNames)
|
||||
foreach (_variableName ${_variableNames})
|
||||
if (ARGV0)
|
||||
unset(MATCHED)
|
||||
string(REGEX MATCH ${ARGV0} MATCHED ${_variableName})
|
||||
if (NOT MATCHED)
|
||||
continue()
|
||||
endif()
|
||||
endif()
|
||||
message(STATUS "${_variableName}=${${_variableName}}")
|
||||
endforeach()
|
||||
endfunction()
|
|
@ -91,39 +91,11 @@ macro(SET_PACKAGING_PARAMETERS)
|
|||
endif ()
|
||||
|
||||
if ((PRODUCTION_BUILD OR PR_BUILD) AND NOT STABLE_BUILD)
|
||||
set(GIT_COMMIT_SHORT $ENV{GIT_COMMIT_SHORT})
|
||||
# append the abbreviated commit SHA to the build version
|
||||
# since this is a PR build or master/nightly builds
|
||||
|
||||
# for PR_BUILDS, we need to grab the abbreviated SHA
|
||||
# for the second parent of HEAD (not HEAD) since that is the
|
||||
# SHA of the commit merged to master for the build
|
||||
if (PR_BUILD)
|
||||
set(_GIT_LOG_FORMAT "%p %h")
|
||||
else ()
|
||||
set(_GIT_LOG_FORMAT "%h")
|
||||
endif ()
|
||||
|
||||
execute_process(
|
||||
COMMAND git log -1 --abbrev=7 --format=${_GIT_LOG_FORMAT}
|
||||
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
||||
OUTPUT_VARIABLE _GIT_LOG_OUTPUT
|
||||
ERROR_VARIABLE _GIT_LOG_ERROR
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
|
||||
if (PR_BUILD)
|
||||
separate_arguments(_COMMIT_PARENTS UNIX_COMMAND ${_GIT_LOG_OUTPUT})
|
||||
list(GET _COMMIT_PARENTS 1 GIT_COMMIT_HASH)
|
||||
else ()
|
||||
set(GIT_COMMIT_HASH ${_GIT_LOG_OUTPUT})
|
||||
endif ()
|
||||
|
||||
if (_GIT_LOG_ERROR OR NOT GIT_COMMIT_HASH)
|
||||
message(FATAL_ERROR "Could not retreive abbreviated SHA for PR or production master build")
|
||||
endif ()
|
||||
|
||||
set(BUILD_VERSION_NO_SHA ${BUILD_VERSION})
|
||||
set(BUILD_VERSION "${BUILD_VERSION}-${GIT_COMMIT_HASH}")
|
||||
set(BUILD_VERSION "${BUILD_VERSION}-${GIT_COMMIT_SHORT}")
|
||||
|
||||
# pass along a release number without the SHA in case somebody
|
||||
# wants to compare master or PR builds as integers
|
||||
|
@ -148,6 +120,7 @@ macro(SET_PACKAGING_PARAMETERS)
|
|||
|
||||
set(CONSOLE_INSTALL_DIR ${DMG_SUBFOLDER_NAME})
|
||||
set(INTERFACE_INSTALL_DIR ${DMG_SUBFOLDER_NAME})
|
||||
set(SCREENSHARE_INSTALL_DIR ${DMG_SUBFOLDER_NAME})
|
||||
set(NITPICK_INSTALL_DIR ${DMG_SUBFOLDER_NAME})
|
||||
|
||||
if (CLIENT_ONLY)
|
||||
|
@ -155,14 +128,17 @@ macro(SET_PACKAGING_PARAMETERS)
|
|||
else ()
|
||||
set(CONSOLE_EXEC_NAME "Sandbox.app")
|
||||
endif()
|
||||
|
||||
set(CONSOLE_INSTALL_APP_PATH "${CONSOLE_INSTALL_DIR}/${CONSOLE_EXEC_NAME}")
|
||||
|
||||
set(SCREENSHARE_EXEC_NAME "hifi-screenshare.app")
|
||||
set(SCREENSHARE_INSTALL_APP_PATH "${SCREENSHARE_INSTALL_DIR}/${SCREENSHARE_EXEC_NAME}")
|
||||
|
||||
set(CONSOLE_APP_CONTENTS "${CONSOLE_INSTALL_APP_PATH}/Contents")
|
||||
set(COMPONENT_APP_PATH "${CONSOLE_APP_CONTENTS}/MacOS/Components.app")
|
||||
set(COMPONENT_INSTALL_DIR "${COMPONENT_APP_PATH}/Contents/MacOS")
|
||||
set(CONSOLE_PLUGIN_INSTALL_DIR "${COMPONENT_APP_PATH}/Contents/PlugIns")
|
||||
|
||||
set(SCREENSHARE_APP_CONTENTS "${SCREENSHARE_INSTALL_APP_PATH}/Contents")
|
||||
|
||||
set(INTERFACE_INSTALL_APP_PATH "${CONSOLE_INSTALL_DIR}/${INTERFACE_BUNDLE_NAME}.app")
|
||||
set(INTERFACE_ICON_FILENAME "${INTERFACE_ICON_PREFIX}.icns")
|
||||
|
@ -170,9 +146,11 @@ macro(SET_PACKAGING_PARAMETERS)
|
|||
else ()
|
||||
if (WIN32)
|
||||
set(CONSOLE_INSTALL_DIR "server-console")
|
||||
set(SCREENSHARE_INSTALL_DIR "hifi-screenshare")
|
||||
set(NITPICK_INSTALL_DIR "nitpick")
|
||||
else ()
|
||||
set(CONSOLE_INSTALL_DIR ".")
|
||||
set(SCREENSHARE_INSTALL_DIR ".")
|
||||
set(NITPICK_INSTALL_DIR ".")
|
||||
endif ()
|
||||
|
||||
|
@ -186,6 +164,7 @@ macro(SET_PACKAGING_PARAMETERS)
|
|||
set(NITPICK_ICON_FILENAME "${NITPICK_ICON_PREFIX}.ico")
|
||||
|
||||
set(CONSOLE_EXEC_NAME "server-console.exe")
|
||||
set(SCREENSHARE_EXEC_NAME "hifi-screenshare.exe")
|
||||
|
||||
set(DS_EXEC_NAME "domain-server.exe")
|
||||
set(AC_EXEC_NAME "assignment-client.exe")
|
||||
|
|
|
@ -48,18 +48,12 @@ macro(setup_qt)
|
|||
# if we are in a development build and QT_CMAKE_PREFIX_PATH is specified
|
||||
# then use it,
|
||||
# otherwise, use the vcpkg'ed version
|
||||
if(NOT DEFINED VCPKG_QT_CMAKE_PREFIX_PATH)
|
||||
message(FATAL_ERROR "VCPKG_QT_CMAKE_PREFIX_PATH should have been set by hifi_vcpkg.py")
|
||||
if(NOT DEFINED QT_CMAKE_PREFIX_PATH)
|
||||
message(FATAL_ERROR "QT_CMAKE_PREFIX_PATH should have been set by hifi_qt.py")
|
||||
endif()
|
||||
if (NOT DEV_BUILD)
|
||||
message("override QT_CMAKE_PREFIX_PATH with VCPKG_QT_CMAKE_PREFIX_PATH")
|
||||
set(QT_CMAKE_PREFIX_PATH ${VCPKG_QT_CMAKE_PREFIX_PATH})
|
||||
else()
|
||||
# DEV_BUILD
|
||||
if (DEV_BUILD)
|
||||
if (DEFINED ENV{QT_CMAKE_PREFIX_PATH})
|
||||
set(QT_CMAKE_PREFIX_PATH $ENV{QT_CMAKE_PREFIX_PATH})
|
||||
else()
|
||||
set(QT_CMAKE_PREFIX_PATH ${VCPKG_QT_CMAKE_PREFIX_PATH})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
|
15
cmake/macros/TargetAristo.cmake
Normal file
15
cmake/macros/TargetAristo.cmake
Normal file
|
@ -0,0 +1,15 @@
|
|||
#
|
||||
# Copyright 2019 High Fidelity, Inc.
|
||||
#
|
||||
# Distributed under the Apache License, Version 2.0.
|
||||
# See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
#
|
||||
macro(TARGET_ARISTO)
|
||||
|
||||
if (WIN32)
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PUBLIC "${VCPKG_INSTALL_ROOT}/include")
|
||||
find_library(ARISTO_LIBRARY NAMES aristo_interface PATHS ${VCPKG_INSTALL_ROOT}/lib/ NO_DEFAULT_PATH)
|
||||
target_link_libraries(${TARGET_NAME} ${ARISTO_LIBRARY})
|
||||
endif()
|
||||
|
||||
endmacro()
|
|
@ -16,21 +16,15 @@ macro(TARGET_GLAD)
|
|||
find_library(EGL EGL)
|
||||
target_link_libraries(${TARGET_NAME} ${EGL})
|
||||
else()
|
||||
if (USE_GLES)
|
||||
set(GLAD_VER "32es")
|
||||
else()
|
||||
set(GLAD_VER "45")
|
||||
endif()
|
||||
find_package(OpenGL REQUIRED)
|
||||
list(APPEND GLAD_EXTRA_LIBRARIES ${OPENGL_LIBRARY})
|
||||
find_library(GLAD_LIBRARY_RELEASE glad PATHS ${VCPKG_INSTALL_ROOT}/lib NO_DEFAULT_PATH)
|
||||
find_library(GLAD_LIBRARY_DEBUG glad_d PATHS ${VCPKG_INSTALL_ROOT}/debug/lib NO_DEFAULT_PATH)
|
||||
select_library_configurations(GLAD)
|
||||
if (NOT WIN32)
|
||||
list(APPEND GLAD_EXTRA_LIBRARIES dl)
|
||||
endif()
|
||||
set(GLAD "glad${GLAD_VER}")
|
||||
string(TOUPPER ${GLAD} GLAD_UPPER)
|
||||
add_dependency_external_projects(${GLAD})
|
||||
set(GLAD_INCLUDE_DIRS ${${GLAD_UPPER}_INCLUDE_DIRS})
|
||||
set(GLAD_LIBRARY ${${GLAD_UPPER}_LIBRARY})
|
||||
endif()
|
||||
|
||||
target_include_directories(${TARGET_NAME} PUBLIC ${GLAD_INCLUDE_DIRS})
|
||||
|
|
4
cmake/macros/TargetLiblo.cmake
Normal file
4
cmake/macros/TargetLiblo.cmake
Normal file
|
@ -0,0 +1,4 @@
|
|||
macro(target_liblo)
|
||||
find_library(LIBLO LIBLO)
|
||||
target_link_libraries(${TARGET_NAME} ${LIBLO})
|
||||
endmacro()
|
|
@ -13,12 +13,33 @@ macro(TARGET_POLYVOX)
|
|||
list(APPEND POLYVOX_LIBRARIES ${LIB_DIR}/libPolyVoxUtil.so)
|
||||
list(APPEND POLYVOX_LIBRARIES ${LIB_DIR}/Release/libPolyVoxCore.so)
|
||||
else()
|
||||
add_dependency_external_projects(polyvox)
|
||||
find_package(PolyVox REQUIRED)
|
||||
find_library(POLYVOX_LIBRARY_RELEASE PolyVoxCore PATHS ${VCPKG_INSTALL_ROOT}/lib NO_DEFAULT_PATH)
|
||||
find_library(POLYVOX_UTIL_LIBRARY_RELEASE PolyVoxUtil PATHS ${VCPKG_INSTALL_ROOT}/lib NO_DEFAULT_PATH)
|
||||
list(APPEND POLYVOX_LIBRARY_RELEASE ${POLYVOX_UTIL_LIBRARY_RELEASE})
|
||||
find_library(POLYVOX_LIBRARY_DEBUG PolyVoxCore PATHS ${VCPKG_INSTALL_ROOT}/debug/lib NO_DEFAULT_PATH)
|
||||
find_library(POLYVOX_UTIL_LIBRARY_DEBUG PolyVoxUtil PATHS ${VCPKG_INSTALL_ROOT}/debug/lib NO_DEFAULT_PATH)
|
||||
list(APPEND POLYVOX_LIBRARY_DEBUG ${POLYVOX_UTIL_LIBRARY_DEBUG})
|
||||
select_library_configurations(POLYVOX)
|
||||
list(APPEND POLYVOX_INCLUDE_DIRS ${VCPKG_INSTALL_ROOT}/include)
|
||||
if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
|
||||
set(_LIB_GLOBS)
|
||||
if(${CMAKE_BUILD_TYPE} STREQUAL "Debug")
|
||||
set(_PV_LIBRARIES ${POLYVOX_LIBRARY_DEBUG})
|
||||
else()
|
||||
set(_PV_LIBRARIES ${POLYVOX_LIBRARY_RELEASE})
|
||||
endif()
|
||||
foreach(_lib ${_PV_LIBRARIES})
|
||||
list(APPEND _LIB_GLOBS ${_lib}*)
|
||||
endforeach()
|
||||
add_custom_command(
|
||||
TARGET ${TARGET_NAME}
|
||||
POST_BUILD
|
||||
COMMAND cp
|
||||
ARGS -d ${_LIB_GLOBS} ${CMAKE_BINARY_DIR}
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PUBLIC ${POLYVOX_INCLUDE_DIRS})
|
||||
target_link_libraries(${TARGET_NAME} ${POLYVOX_LIBRARIES})
|
||||
target_include_directories(${TARGET_NAME} PUBLIC ${POLYVOX_INCLUDE_DIRS})
|
||||
endmacro()
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -6,11 +6,8 @@
|
|||
# See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
#
|
||||
macro(TARGET_QUAZIP)
|
||||
add_dependency_external_projects(quazip)
|
||||
find_package(QuaZip REQUIRED)
|
||||
target_include_directories(${TARGET_NAME} PUBLIC ${QUAZIP_INCLUDE_DIRS})
|
||||
find_library(QUAZIP_LIBRARY_RELEASE quazip5 PATHS ${VCPKG_INSTALL_ROOT}/lib NO_DEFAULT_PATH)
|
||||
find_library(QUAZIP_LIBRARY_DEBUG quazip5 PATHS ${VCPKG_INSTALL_ROOT}/debug/lib NO_DEFAULT_PATH)
|
||||
select_library_configurations(QUAZIP)
|
||||
target_link_libraries(${TARGET_NAME} ${QUAZIP_LIBRARIES})
|
||||
if (WIN32)
|
||||
add_paths_to_fixup_libs(${QUAZIP_DLL_PATH})
|
||||
endif ()
|
||||
endmacro()
|
|
@ -1,15 +0,0 @@
|
|||
macro(TARGET_SPIRV)
|
||||
add_dependency_external_projects(spirv_cross)
|
||||
target_link_libraries(${TARGET_NAME} ${SPIRV_CROSS_LIBRARIES})
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PRIVATE ${SPIRV_CROSS_INCLUDE_DIRS})
|
||||
|
||||
# spirv-tools requires spirv-headers
|
||||
add_dependency_external_projects(spirv_headers)
|
||||
add_dependency_external_projects(spirv_tools)
|
||||
target_link_libraries(${TARGET_NAME} ${SPIRV_TOOLS_LIBRARIES})
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PRIVATE ${SPIRV_TOOLS_INCLUDE_DIRS})
|
||||
|
||||
add_dependency_external_projects(glslang)
|
||||
target_link_libraries(${TARGET_NAME} ${GLSLANG_LIBRARIES})
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PRIVATE ${GLSLANG_INCLUDE_DIRS})
|
||||
endmacro()
|
18
cmake/macros/TargetSRanipalEye.cmake
Normal file
18
cmake/macros/TargetSRanipalEye.cmake
Normal file
|
@ -0,0 +1,18 @@
|
|||
#
|
||||
# Copyright 2019 High Fidelity, Inc.
|
||||
#
|
||||
# Distributed under the Apache License, Version 2.0.
|
||||
# See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
#
|
||||
macro(TARGET_SRANIPAL)
|
||||
|
||||
if (WIN32)
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PUBLIC "${VCPKG_INSTALL_ROOT}/include")
|
||||
find_library(SRANIPAL_LIBRARY NAMES SRanipal PATHS ${VCPKG_INSTALL_ROOT}/lib/ NO_DEFAULT_PATH)
|
||||
target_link_libraries(${TARGET_NAME} ${SRANIPAL_LIBRARY})
|
||||
|
||||
find_library(SRANIPAL_LIBRARY NAMES SRanipal PATHS ${VCPKG_INSTALL_ROOT}/lib/ NO_DEFAULT_PATH)
|
||||
target_link_libraries(${TARGET_NAME} ${SRANIPAL_LIBRARY})
|
||||
endif()
|
||||
|
||||
endmacro()
|
|
@ -1,10 +0,0 @@
|
|||
#
|
||||
# Created by Bradley Austin Davis on 2016/02/16
|
||||
#
|
||||
# Distributed under the Apache License, Version 2.0.
|
||||
# See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
#
|
||||
macro(TARGET_SPIRV_BINARIES)
|
||||
add_dependency_external_projects(spirv_binaries)
|
||||
endmacro()
|
||||
|
|
@ -15,11 +15,6 @@ if (ANDROID)
|
|||
set(TBB_LIBRARIES ${TBB_LIBRARY} ${TBB_MALLOC_LIBRARY})
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PUBLIC ${TBB_INCLUDE_DIRS})
|
||||
target_link_libraries(${TARGET_NAME} ${TBB_LIBRARIES})
|
||||
elseif(APPLE)
|
||||
add_dependency_external_projects(tbb)
|
||||
find_package(TBB REQUIRED)
|
||||
target_link_libraries(${TARGET_NAME} ${TBB_LIBRARIES})
|
||||
target_include_directories(${TARGET_NAME} SYSTEM PUBLIC ${TBB_INCLUDE_DIRS})
|
||||
else()
|
||||
# using VCPKG for TBB
|
||||
find_package(TBB CONFIG REQUIRED)
|
||||
|
|
6
cmake/macros/TargetVHACD.cmake
Normal file
6
cmake/macros/TargetVHACD.cmake
Normal file
|
@ -0,0 +1,6 @@
|
|||
macro(TARGET_VHACD)
|
||||
find_library(VHACD_LIBRARY_RELEASE VHACD PATHS ${VCPKG_INSTALL_ROOT}/lib NO_DEFAULT_PATH)
|
||||
find_library(VHACD_LIBRARY_DEBUG VHACD PATHS ${VCPKG_INSTALL_ROOT}/debug/lib NO_DEFAULT_PATH)
|
||||
select_library_configurations(VHACD)
|
||||
target_link_libraries(${TARGET_NAME} ${VHACD_LIBRARIES})
|
||||
endmacro()
|
1
cmake/ports/.gitattributes
vendored
Normal file
1
cmake/ports/.gitattributes
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
* eol=lf
|
3
cmake/ports/aristo/CONTROL
Normal file
3
cmake/ports/aristo/CONTROL
Normal file
|
@ -0,0 +1,3 @@
|
|||
Source: aristo
|
||||
Version: 0.8.1
|
||||
Description: Aristo
|
20
cmake/ports/aristo/portfile.cmake
Normal file
20
cmake/ports/aristo/portfile.cmake
Normal file
|
@ -0,0 +1,20 @@
|
|||
include(vcpkg_common_functions)
|
||||
set(ARISTO_VERSION 0.8.1)
|
||||
set(MASTER_COPY_SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src)
|
||||
|
||||
if (WIN32)
|
||||
vcpkg_download_distfile(
|
||||
ARISTO_SOURCE_ARCHIVE
|
||||
URLS https://hifi-public.s3.amazonaws.com/seth/aristo-0.8.1-windows.zip
|
||||
SHA512 05179c63b72a1c9f5be8a7a2b7389025da683400dbf819e5a6199dd6473c56774d2885182dc5a11cb6324058d228a4ead832222e8b3e1bebaa4c61982e85f0a8
|
||||
FILENAME aristo-0.8.1-windows.zip
|
||||
)
|
||||
|
||||
vcpkg_extract_source_archive(${ARISTO_SOURCE_ARCHIVE})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/aristo/include DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/aristo/lib DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/aristo/debug DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/aristo/bin DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/aristo/share DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
|
||||
endif ()
|
3
cmake/ports/glad/CONTROL
Normal file
3
cmake/ports/glad/CONTROL
Normal file
|
@ -0,0 +1,3 @@
|
|||
Source: glad
|
||||
Version: 20191029
|
||||
Description: OpenGL function loader
|
20
cmake/ports/glad/copyright
Normal file
20
cmake/ports/glad/copyright
Normal file
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2013-2018 David Herberth
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
36
cmake/ports/glad/portfile.cmake
Normal file
36
cmake/ports/glad/portfile.cmake
Normal file
|
@ -0,0 +1,36 @@
|
|||
include(vcpkg_common_functions)
|
||||
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
||||
|
||||
if (ANDROID)
|
||||
vcpkg_download_distfile(
|
||||
SOURCE_ARCHIVE
|
||||
URLS https://public.highfidelity.com/dependencies/glad/glad32es.zip
|
||||
SHA512 2e02ac633eed8f2ba2adbf96ea85d08998f48dd2e9ec9a88ec3c25f48eaf1405371d258066327c783772fcb3793bdb82bd7375fdabb2ba5e2ce0835468b17f65
|
||||
)
|
||||
else()
|
||||
# else Linux desktop
|
||||
vcpkg_download_distfile(
|
||||
SOURCE_ARCHIVE
|
||||
URLS https://public.highfidelity.com/dependencies/glad/glad45.zip
|
||||
SHA512 653a7b873f9fbc52e0ab95006cc3143bc7b6f62c6e032bc994e87669273468f37978525c9af5efe36f924cb4acd221eb664ad9af0ce4bf711b4f1be724c0065e
|
||||
FILENAME glad45.zip
|
||||
)
|
||||
endif()
|
||||
|
||||
vcpkg_extract_source_archive_ex(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
ARCHIVE ${SOURCE_ARCHIVE}
|
||||
NO_REMOVE_ONE_LEVEL
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
OPTIONS -DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
file(COPY ${CMAKE_CURRENT_LIST_DIR}/copyright DESTINATION ${CURRENT_PACKAGES_DIR}/share/glad)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
Source: hifi-client-deps
|
||||
Version: 0
|
||||
Version: 0.1
|
||||
Description: Collected dependencies for High Fidelity applications
|
||||
Build-Depends: hifi-deps, glslang, nlohmann-json, openvr (windows), sdl2 (!android), spirv-cross (!android), spirv-tools (!android), vulkanmemoryallocator
|
||||
Build-Depends: hifi-deps, aristo (windows), glslang, liblo (windows), nlohmann-json, openvr (windows), quazip (!android), sdl2 (!android), spirv-cross (!android), spirv-tools (!android), sranipal (windows), vulkanmemoryallocator
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
Source: hifi-deps
|
||||
Version: 0.4
|
||||
Version: 0.1.4-github-actions
|
||||
Description: Collected dependencies for High Fidelity applications
|
||||
Build-Depends: bullet3, draco, etc2comp, glm, nvtt, openexr (!android), openssl (windows), opus, tbb (!android&!osx), zlib, webrtc (!android)
|
||||
Build-Depends: bullet3, draco, etc2comp, glad, glm, nvtt, openexr (!android), openssl (windows), opus, polyvox, tbb (!android), vhacd, webrtc (!android), zlib
|
||||
|
|
3
cmake/ports/liblo/CONTROL
Normal file
3
cmake/ports/liblo/CONTROL
Normal file
|
@ -0,0 +1,3 @@
|
|||
Source: liblo
|
||||
Version: 0.30
|
||||
Description: liblo is an implementation of the Open Sound Control protocol for POSIX systems
|
36
cmake/ports/liblo/portfile.cmake
Normal file
36
cmake/ports/liblo/portfile.cmake
Normal file
|
@ -0,0 +1,36 @@
|
|||
include(vcpkg_common_functions)
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO radarsat1/liblo
|
||||
REF 0.30
|
||||
SHA512 d36c141c513f869e6d1963bd0d584030038019b8be0b27bb9a684722b6e7a38e942ad2ee7c2e67ac13b965560937aad97259435ed86034aa2dc8cb92d23845d8
|
||||
HEAD_REF master
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}/cmake
|
||||
PREFER_NINJA # Disable this option if project cannot be built with Ninja
|
||||
OPTIONS -DTHREADING=1
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
# Install needed files into package directory
|
||||
vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/liblo)
|
||||
|
||||
file(INSTALL ${CURRENT_PACKAGES_DIR}/bin/oscsend.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/liblo)
|
||||
file(INSTALL ${CURRENT_PACKAGES_DIR}/bin/oscdump.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/liblo)
|
||||
vcpkg_copy_tool_dependencies(${CURRENT_PACKAGES_DIR}/tools/liblo)
|
||||
|
||||
# Remove unnecessary files
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
file(REMOVE ${CURRENT_PACKAGES_DIR}/bin/oscsend.exe ${CURRENT_PACKAGES_DIR}/bin/oscdump.exe)
|
||||
file(REMOVE ${CURRENT_PACKAGES_DIR}/debug/bin/oscsend.exe ${CURRENT_PACKAGES_DIR}/debug/bin/oscdump.exe)
|
||||
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL static)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin)
|
||||
endif()
|
||||
|
||||
# Handle copyright
|
||||
file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/liblo RENAME copyright)
|
|
@ -26,6 +26,7 @@ get_filename_component(COMPILER_ROOT "${CMAKE_C_COMPILER}" DIRECTORY)
|
|||
message("CMAKE_C_COMPILER=${CMAKE_C_COMPILER}")
|
||||
message("COMPILER_ROOT=${COMPILER_ROOT}")
|
||||
message("CMAKE_SYSROOT=${CMAKE_SYSROOT}")
|
||||
message("CMAKE_OSX_SYSROOT=${CMAKE_OSX_SYSROOT}")
|
||||
message("CMAKE_C_FLAGS=${CMAKE_C_FLAGS}")
|
||||
message("CMAKE_C_FLAGS_RELEASE=${CMAKE_C_FLAGS_RELEASE}")
|
||||
message("CMAKE_C_FLAGS_DEBUG=${CMAKE_C_FLAGS_DEBUG}")
|
||||
|
@ -43,6 +44,8 @@ if(CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN)
|
|||
endif()
|
||||
if(CMAKE_SYSROOT AND CMAKE_C_COMPILE_OPTIONS_SYSROOT)
|
||||
set(CFLAGS "${CFLAGS} ${CMAKE_C_COMPILE_OPTIONS_SYSROOT}${CMAKE_SYSROOT}")
|
||||
elseif(CMAKE_OSX_SYSROOT AND CMAKE_C_COMPILE_OPTIONS_SYSROOT)
|
||||
set(CFLAGS "${CFLAGS} ${CMAKE_C_COMPILE_OPTIONS_SYSROOT}${CMAKE_OSX_SYSROOT}")
|
||||
endif()
|
||||
|
||||
string(REGEX REPLACE "^ " "" CFLAGS "${CFLAGS}")
|
||||
|
@ -73,9 +76,27 @@ file(WRITE "${BUILDDIR}/Configure" "${_contents}")
|
|||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
set(SHARED shared)
|
||||
file(STRINGS "${BUILDDIR}/crypto/opensslv.h" SHLIB_VERSION
|
||||
REGEX "^#[\t ]*define[\t ]+SHLIB_VERSION_NUMBER[\t ]+\".*\".*")
|
||||
string(REGEX REPLACE "^.*SHLIB_VERSION_NUMBER[\t ]+\"([^\"]*)\".*$" "\\1"
|
||||
SHLIB_VERSION "${SHLIB_VERSION}")
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
|
||||
set(LIB_EXT dylib)
|
||||
set(LIB_EXTS ${SHLIB_VERSION}.${LIB_EXT})
|
||||
else()
|
||||
set(LIB_EXT so)
|
||||
set(LIB_EXTS ${LIB_EXT}.${SHLIB_VERSION})
|
||||
endif()
|
||||
list(APPEND LIB_EXTS ${LIB_EXT})
|
||||
else()
|
||||
set(SHARED no-shared)
|
||||
set(LIB_EXTS a)
|
||||
endif()
|
||||
foreach(lib ssl crypto)
|
||||
foreach(ext ${LIB_EXTS})
|
||||
list(APPEND INSTALL_LIBS "${BUILDDIR}/lib${lib}.${ext}")
|
||||
endforeach()
|
||||
endforeach()
|
||||
|
||||
if(CMAKE_HOST_WIN32)
|
||||
set(ENV_COMMAND set)
|
||||
|
@ -127,10 +148,10 @@ add_custom_target(build_libs ALL
|
|||
VERBATIM
|
||||
WORKING_DIRECTORY "${BUILDDIR}"
|
||||
DEPENDS depend
|
||||
BYPRODUCTS "${BUILDDIR}/libssl.a" "${BUILDDIR}/libcrypto.a"
|
||||
BYPRODUCTS ${INSTALL_LIBS}
|
||||
)
|
||||
|
||||
install(
|
||||
FILES "${BUILDDIR}/libssl.a" "${BUILDDIR}/libcrypto.a"
|
||||
FILES ${INSTALL_LIBS}
|
||||
DESTINATION lib
|
||||
)
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
Source: openssl-unix
|
||||
Version: 1.0.2p
|
||||
Version: 1.0.2s-1
|
||||
Description: OpenSSL is an open source project that provides a robust, commercial-grade, and full-featured toolkit for the Transport Layer Security (TLS) and Secure Sockets Layer (SSL) protocols. It is also a general-purpose cryptography library.
|
||||
|
|
|
@ -1,25 +1,37 @@
|
|||
include(vcpkg_common_functions)
|
||||
|
||||
if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore" OR NOT VCPKG_CMAKE_SYSTEM_NAME)
|
||||
message(FATAL_ERROR "This port is only for openssl on Unix-like systems")
|
||||
endif()
|
||||
|
||||
include(vcpkg_common_functions)
|
||||
set(OPENSSL_VERSION 1.0.2p)
|
||||
set(MASTER_COPY_SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/openssl-${OPENSSL_VERSION})
|
||||
if(EXISTS "${CURRENT_INSTALLED_DIR}/include/openssl/ssl.h")
|
||||
message(WARNING "Can't build openssl if libressl is installed. Please remove libressl, and try install openssl again if you need it. Build will continue but there might be problems since libressl is only a subset of openssl")
|
||||
set(VCPKG_POLICY_EMPTY_PACKAGE enabled)
|
||||
return()
|
||||
endif()
|
||||
|
||||
if (VCPKG_LIBRARY_LINKAGE STREQUAL static)
|
||||
set(VCPKG_LIBRARY_LINKAGE dynamic)
|
||||
endif()
|
||||
|
||||
vcpkg_find_acquire_program(PERL)
|
||||
|
||||
set(OPENSSL_VERSION 1.0.2s)
|
||||
|
||||
vcpkg_download_distfile(OPENSSL_SOURCE_ARCHIVE
|
||||
URLS "https://www.openssl.org/source/openssl-${OPENSSL_VERSION}.tar.gz" "https://www.openssl.org/source/old/1.0.2/openssl-${OPENSSL_VERSION}.tar.gz"
|
||||
FILENAME "openssl-${OPENSSL_VERSION}.tar.gz"
|
||||
SHA512 958c5a7c3324bbdc8f07dfb13e11329d9a1b4452c07cf41fbd2d42b5fe29c95679332a3476d24c2dc2b88be16e4a24744aba675a05a388c0905756c77a8a2f16
|
||||
SHA512 9f745452c4f777df694158e95003cde78a2cf8199bc481a563ec36644664c3c1415a774779b9791dd18f2aeb57fa1721cb52b3db12d025955e970071d5b66d2a
|
||||
)
|
||||
|
||||
vcpkg_extract_source_archive(${OPENSSL_SOURCE_ARCHIVE})
|
||||
vcpkg_apply_patches(
|
||||
SOURCE_PATH ${MASTER_COPY_SOURCE_PATH}
|
||||
PATCHES ${CMAKE_CURRENT_LIST_DIR}/ConfigureIncludeQuotesFix.patch
|
||||
${CMAKE_CURRENT_LIST_DIR}/STRINGIFYPatch.patch
|
||||
${CMAKE_CURRENT_LIST_DIR}/EmbedSymbolsInStaticLibsZ7.patch
|
||||
vcpkg_extract_source_archive_ex(
|
||||
OUT_SOURCE_PATH MASTER_COPY_SOURCE_PATH
|
||||
ARCHIVE ${OPENSSL_SOURCE_ARCHIVE}
|
||||
REF ${OPENSSL_VERSION}
|
||||
PATCHES
|
||||
ConfigureIncludeQuotesFix.patch
|
||||
STRINGIFYPatch.patch
|
||||
EmbedSymbolsInStaticLibsZ7.patch
|
||||
)
|
||||
|
||||
if(CMAKE_HOST_WIN32)
|
||||
|
|
3
cmake/ports/polyvox/CONTROL
Normal file
3
cmake/ports/polyvox/CONTROL
Normal file
|
@ -0,0 +1,3 @@
|
|||
Source: polyvox
|
||||
Version: 20150715
|
||||
Description: Polyvox
|
89
cmake/ports/polyvox/portfile.cmake
Normal file
89
cmake/ports/polyvox/portfile.cmake
Normal file
|
@ -0,0 +1,89 @@
|
|||
include(vcpkg_common_functions)
|
||||
|
||||
# else Linux desktop
|
||||
vcpkg_download_distfile(
|
||||
SOURCE_ARCHIVE
|
||||
URLS https://public.highfidelity.com/dependencies/polyvox-master-2015-7-15.zip
|
||||
SHA512 cc04cd43ae74b9c7bb065953540c0048053fcba6b52dc4218b3d9431fba178d65ad4f6c53cc1122ba61d0ab4061e99a7ebbb15db80011d607c5070ebebf8eddc
|
||||
FILENAME polyvox.zip
|
||||
)
|
||||
|
||||
vcpkg_extract_source_archive_ex(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
ARCHIVE ${SOURCE_ARCHIVE}
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
OPTIONS -DENABLE_EXAMPLES=OFF -DENABLE_BINDINGS=OFF
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
file(INSTALL ${SOURCE_PATH}/LICENSE.TXT DESTINATION ${CURRENT_PACKAGES_DIR}/share/polyvox RENAME copyright)
|
||||
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/include)
|
||||
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/lib)
|
||||
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/debug/lib)
|
||||
if(WIN32)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/PolyVoxCore/lib/Release/PolyVoxCore.lib ${CURRENT_PACKAGES_DIR}/lib/PolyVoxCore.lib)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/debug/PolyVoxCore/lib/Debug/PolyVoxCore.lib ${CURRENT_PACKAGES_DIR}/debug/lib/PolyVoxCore.lib)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/PolyVoxUtil/lib/PolyVoxUtil.lib ${CURRENT_PACKAGES_DIR}/lib/PolyVoxUtil.lib)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/debug/PolyVoxUtil/lib/PolyVoxUtil.lib ${CURRENT_PACKAGES_DIR}/debug/lib/PolyVoxUtil.lib)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/PolyVoxCore/include/PolyVoxCore ${CURRENT_PACKAGES_DIR}/include/PolyVoxCore)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/PolyVoxUtil/include/PolyVoxUtil ${CURRENT_PACKAGES_DIR}/include/PolyVoxUtil)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/cmake/PolyVoxConfig.cmake ${CURRENT_PACKAGES_DIR}/share/polyvox/polyvoxConfig.cmake)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/cmake)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/cmake)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/PolyVoxCore)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/PolyVoxUtil)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/PolyVoxUtil)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/PolyVoxCore)
|
||||
else()
|
||||
file(GLOB LIBS ${CURRENT_PACKAGES_DIR}/lib/Release/*)
|
||||
foreach(_lib ${LIBS})
|
||||
file(RELATIVE_PATH _libName ${CURRENT_PACKAGES_DIR}/lib/Release ${_lib})
|
||||
file(RENAME ${_lib} ${CURRENT_PACKAGES_DIR}/lib/${_libName})
|
||||
endforeach()
|
||||
file(GLOB LIBS ${CURRENT_PACKAGES_DIR}/debug/lib/Debug/*)
|
||||
foreach(_lib ${LIBS})
|
||||
file(RELATIVE_PATH _libName ${CURRENT_PACKAGES_DIR}/debug/lib/Debug ${_lib})
|
||||
file(RENAME ${_lib} ${CURRENT_PACKAGES_DIR}/debug/lib/${_libName})
|
||||
endforeach()
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/include/PolyVoxCore ${CURRENT_PACKAGES_DIR}/include/PolyVoxCore.temp)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/include/PolyVoxCore.temp/PolyVoxCore ${CURRENT_PACKAGES_DIR}/include/PolyVoxCore)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/PolyVoxCore.temp)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/include/PolyVoxUtil ${CURRENT_PACKAGES_DIR}/include/PolyVoxUtil.temp)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/include/PolyVoxUtil.temp/PolyVoxUtil ${CURRENT_PACKAGES_DIR}/include/PolyVoxUtil)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/PolyVoxUtil.temp)
|
||||
endif()
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/Release)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/RelWithDebInfo)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/Debug)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/Release)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/RelWithDebInfo)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/Debug)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
||||
|
||||
# if (APPLE)
|
||||
# set(INSTALL_NAME_LIBRARY_DIR ${INSTALL_DIR}/lib)
|
||||
# ExternalProject_Add_Step(
|
||||
# ${EXTERNAL_NAME}
|
||||
# change-install-name-debug
|
||||
# COMMENT "Calling install_name_tool on libraries to fix install name for dylib linking"
|
||||
# COMMAND ${CMAKE_COMMAND} -DINSTALL_NAME_LIBRARY_DIR=${INSTALL_NAME_LIBRARY_DIR}/Debug -P ${EXTERNAL_PROJECT_DIR}/OSXInstallNameChange.cmake
|
||||
# DEPENDEES install
|
||||
# WORKING_DIRECTORY <SOURCE_DIR>
|
||||
# LOG 1
|
||||
# )
|
||||
# ExternalProject_Add_Step(
|
||||
# ${EXTERNAL_NAME}
|
||||
# change-install-name-release
|
||||
# COMMENT "Calling install_name_tool on libraries to fix install name for dylib linking"
|
||||
# COMMAND ${CMAKE_COMMAND} -DINSTALL_NAME_LIBRARY_DIR=${INSTALL_NAME_LIBRARY_DIR}/Release -P ${EXTERNAL_PROJECT_DIR}/OSXInstallNameChange.cmake
|
||||
# DEPENDEES install
|
||||
# WORKING_DIRECTORY <SOURCE_DIR>
|
||||
# LOG 1
|
||||
# )
|
||||
# endif ()
|
4
cmake/ports/quazip/CONTROL
Normal file
4
cmake/ports/quazip/CONTROL
Normal file
|
@ -0,0 +1,4 @@
|
|||
Source: quazip
|
||||
Version: 0.7.3
|
||||
Description: Zip file manipulation for Qt
|
||||
Build-Depends: zlib
|
89
cmake/ports/quazip/portfile.cmake
Normal file
89
cmake/ports/quazip/portfile.cmake
Normal file
|
@ -0,0 +1,89 @@
|
|||
include(vcpkg_common_functions)
|
||||
|
||||
vcpkg_download_distfile(
|
||||
SOURCE_ARCHIVE
|
||||
URLS https://public.highfidelity.com/dependencies/quazip-0.7.3.zip
|
||||
SHA512 b2d812b6346317fd6d8f4f1344ad48b721d697c429acc8b7e7cb776ce5cba15a59efd64b2c5ae1f31b5a3c928014f084aa1379fd55d8a452a6cf4fd510b3afcc
|
||||
FILENAME quazip.zip
|
||||
)
|
||||
|
||||
vcpkg_extract_source_archive_ex(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
ARCHIVE ${SOURCE_ARCHIVE}
|
||||
NO_REMOVE_ONE_LEVEL
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
OPTIONS -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_PREFIX_PATH=$ENV{QT_CMAKE_PREFIX_PATH} -DBUILD_WITH_QT4=OFF
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
if (WIN32)
|
||||
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/bin)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/lib/quazip5.dll ${CURRENT_PACKAGES_DIR}/bin/quazip5.dll)
|
||||
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/debug/bin)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/debug/lib/quazip5d.dll ${CURRENT_PACKAGES_DIR}/debug/bin/quazip5.dll)
|
||||
elseif(DEFINED VCPKG_TARGET_IS_LINUX)
|
||||
# We only want static libs.
|
||||
file(GLOB QUAZIP5_DYNAMIC_LIBS ${CURRENT_PACKAGES_DIR}/lib/libquazip5.so* ${CURRENT_PACKAGES_DIR}/debug/lib/libquazip5d.so*)
|
||||
file(REMOVE ${QUAZIP5_DYNAMIC_LIBS})
|
||||
endif()
|
||||
file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/quazip RENAME copyright)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
|
||||
# set(QUAZIP_CMAKE_ARGS
|
||||
# -DCMAKE_PREFIX_PATH=${QT_CMAKE_PREFIX_PATH}
|
||||
# -DCMAKE_INSTALL_NAME_DIR:PATH=<INSTALL_DIR>/lib
|
||||
# -DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}
|
||||
# -DZLIB_ROOT=${VCPKG_INSTALL_ROOT}
|
||||
# -DCMAKE_POSITION_INDEPENDENT_CODE=ON)
|
||||
|
||||
# if (NOT APPLE)
|
||||
# set(QUAZIP_CMAKE_ARGS ${QUAZIP_CMAKE_ARGS} -DCMAKE_CXX_STANDARD=11)
|
||||
# endif ()
|
||||
|
||||
# ExternalProject_Add(
|
||||
# ${EXTERNAL_NAME}
|
||||
# URL
|
||||
# URL_MD5 ed03754d39b9da1775771819b8001d45
|
||||
# BINARY_DIR ${EXTERNAL_PROJECT_PREFIX}/build
|
||||
# CMAKE_ARGS ${QUAZIP_CMAKE_ARGS}
|
||||
# LOG_DOWNLOAD 1
|
||||
# LOG_CONFIGURE 1
|
||||
# LOG_BUILD 1
|
||||
# )
|
||||
|
||||
# # Hide this external target (for ide users)
|
||||
# set_target_properties(${EXTERNAL_NAME} PROPERTIES
|
||||
# FOLDER "hidden/externals"
|
||||
# INSTALL_NAME_DIR ${INSTALL_DIR}/lib
|
||||
# BUILD_WITH_INSTALL_RPATH True)
|
||||
|
||||
# ExternalProject_Get_Property(${EXTERNAL_NAME} INSTALL_DIR)
|
||||
# set(${EXTERNAL_NAME_UPPER}_INCLUDE_DIR ${INSTALL_DIR}/include CACHE PATH "List of QuaZip include directories")
|
||||
# set(${EXTERNAL_NAME_UPPER}_INCLUDE_DIRS ${${EXTERNAL_NAME_UPPER}_INCLUDE_DIR} CACHE PATH "List of QuaZip include directories")
|
||||
# set(${EXTERNAL_NAME_UPPER}_DLL_PATH ${INSTALL_DIR}/lib CACHE FILEPATH "Location of QuaZip DLL")
|
||||
|
||||
# if (APPLE)
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_RELEASE ${INSTALL_DIR}/lib/libquazip5.1.0.0.dylib CACHE FILEPATH "Location of QuaZip release library")
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_DEBUG ${INSTALL_DIR}/lib/libquazip5d.1.0.0.dylib CACHE FILEPATH "Location of QuaZip release library")
|
||||
# elseif (WIN32)
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_RELEASE ${INSTALL_DIR}/lib/quazip5.lib CACHE FILEPATH "Location of QuaZip release library")
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_DEBUG ${INSTALL_DIR}/lib/quazip5d.lib CACHE FILEPATH "Location of QuaZip release library")
|
||||
# elseif (CMAKE_SYSTEM_NAME MATCHES "Linux")
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_RELEASE ${INSTALL_DIR}/lib/libquazip5.so CACHE FILEPATH "Location of QuaZip release library")
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_DEBUG ${INSTALL_DIR}/lib/libquazip5d.so CACHE FILEPATH "Location of QuaZip release library")
|
||||
# else ()
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_RELEASE ${INSTALL_DIR}/lib/libquazip5.so CACHE FILEPATH "Location of QuaZip release library")
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY_DEBUG ${INSTALL_DIR}/lib/libquazip5.so CACHE FILEPATH "Location of QuaZip release library")
|
||||
# endif ()
|
||||
|
||||
# include(SelectLibraryConfigurations)
|
||||
# select_library_configurations(${EXTERNAL_NAME_UPPER})
|
||||
|
||||
# # Force selected libraries into the cache
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARY ${${EXTERNAL_NAME_UPPER}_LIBRARY} CACHE FILEPATH "Location of QuaZip libraries")
|
||||
# set(${EXTERNAL_NAME_UPPER}_LIBRARIES ${${EXTERNAL_NAME_UPPER}_LIBRARIES} CACHE FILEPATH "Location of QuaZip libraries")
|
3
cmake/ports/sranipal/CONTROL
Normal file
3
cmake/ports/sranipal/CONTROL
Normal file
|
@ -0,0 +1,3 @@
|
|||
Source: sranipal
|
||||
Version: 1.1.0.1
|
||||
Description: SRanipal
|
20
cmake/ports/sranipal/portfile.cmake
Normal file
20
cmake/ports/sranipal/portfile.cmake
Normal file
|
@ -0,0 +1,20 @@
|
|||
include(vcpkg_common_functions)
|
||||
set(SRANIPAL_VERSION 1.1.0.1)
|
||||
set(MASTER_COPY_SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src)
|
||||
|
||||
if (WIN32)
|
||||
vcpkg_download_distfile(
|
||||
SRANIPAL_SOURCE_ARCHIVE
|
||||
URLS https://hifi-public.s3.amazonaws.com/seth/sranipal-1.1.0.1-windows.zip
|
||||
SHA512 b09ce012abe4e3c71e8e69626bdd7823ff6576601a821ab365275f2764406a3e5f7b65fcf2eb1d0962eff31eb5958a148b00901f67c229dc6ace56eb5e6c9e1b
|
||||
FILENAME sranipal-1.1.0.1-windows.zip
|
||||
)
|
||||
|
||||
vcpkg_extract_source_archive(${SRANIPAL_SOURCE_ARCHIVE})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/sranipal/include DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/sranipal/lib DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/sranipal/debug DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/sranipal/bin DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
file(COPY ${MASTER_COPY_SOURCE_PATH}/sranipal/share DESTINATION ${CURRENT_PACKAGES_DIR})
|
||||
|
||||
endif ()
|
|
@ -4,7 +4,14 @@ file(GLOB SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/*)
|
|||
file(COPY ${SOURCES} DESTINATION ${CMAKE_CURRENT_BINARY_DIR}/src)
|
||||
|
||||
include(${CMAKE_CURRENT_BINARY_DIR}/src/cmake/TBBBuild.cmake REQUIRED)
|
||||
tbb_build(TBB_ROOT ${CMAKE_CURRENT_BINARY_DIR}/src MAKE_ARGS extra_inc=big_iron.inc)
|
||||
if(NOT BUILD_SHARED_LIBS)
|
||||
set(TBB_STATIC_INCLUDE extra_inc=big_iron.inc)
|
||||
endif()
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
|
||||
set(FORWARD_SDK_ROOT "SDKROOT=${CMAKE_OSX_SYSROOT}")
|
||||
endif()
|
||||
|
||||
tbb_build(TBB_ROOT ${CMAKE_CURRENT_BINARY_DIR}/src MAKE_ARGS ${TBB_STATIC_INCLUDE} ${FORWARD_SDK_ROOT})
|
||||
|
||||
set(SUBDIR ${CMAKE_CURRENT_BINARY_DIR}/tbb_cmake_build/tbb_cmake_build_subdir)
|
||||
if(CMAKE_BUILD_TYPE STREQUAL "Release")
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
Source: tbb
|
||||
Version: 2018_U5-4
|
||||
Version: 2019_U8-1
|
||||
Homepage: https://github.com/01org/tbb
|
||||
Description: Intel's Threading Building Blocks.
|
||||
|
|
13
cmake/ports/tbb/fix-static-build.patch
Normal file
13
cmake/ports/tbb/fix-static-build.patch
Normal file
|
@ -0,0 +1,13 @@
|
|||
diff --git a/src/tbb/cilk-tbb-interop.h b/src/tbb/cilk-tbb-interop.h
|
||||
index 295734b..f35531e 100644
|
||||
--- a/src/tbb/cilk-tbb-interop.h
|
||||
+++ b/src/tbb/cilk-tbb-interop.h
|
||||
@@ -29,6 +29,8 @@
|
||||
#else
|
||||
#ifdef IN_CILK_RUNTIME
|
||||
#define CILK_EXPORT __declspec(dllexport)
|
||||
+#elif defined(IN_CILK_STATIC)
|
||||
+#define CILK_EXPORT /* nothing */
|
||||
#else
|
||||
#define CILK_EXPORT __declspec(dllimport)
|
||||
#endif // IN_CILK_RUNTIME
|
|
@ -1,20 +1,17 @@
|
|||
include(vcpkg_common_functions)
|
||||
|
||||
if(NOT VCPKG_CMAKE_SYSTEM_NAME OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
|
||||
vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY)
|
||||
endif()
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO 01org/tbb
|
||||
REF 2018_U5
|
||||
SHA512 d86a110df9e55654c3638af8107fdfed2284434158cb5b3a38b3fc7cf143aa2346ee15da4e141e03fcfed864865462e6893c535b8dc227ebdd6ccd584c8a1e9b
|
||||
HEAD_REF tbb_2018
|
||||
REPO oneapi-src/oneTBB
|
||||
REF 4bdba61bafc6ba2d636f31564f1de5702d365cf7
|
||||
SHA512 f2a8d7e0476f846039390f4a79af3fe13770e23b01bf4741e738136f7ddb401357a0e50f35212e8d0fa5fc4cf1563418337309227d7243fc3676edd406ae652d
|
||||
HEAD_REF tbb_2019
|
||||
PATCHES fix-static-build.patch
|
||||
)
|
||||
|
||||
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
|
||||
|
||||
if(VCPKG_CMAKE_SYSTEM_NAME AND NOT VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
|
||||
if (NOT VCPKG_TARGET_IS_WINDOWS)
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
|
@ -22,7 +19,7 @@ if(VCPKG_CMAKE_SYSTEM_NAME AND NOT VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStor
|
|||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
# Settings for TBBConfigForSource.cmake.in
|
||||
# Settings for TBBConfigInternal.cmake.in
|
||||
set(TBB_LIB_EXT a)
|
||||
set(TBB_LIB_PREFIX lib)
|
||||
else()
|
||||
|
@ -34,13 +31,39 @@ else()
|
|||
set(DEBUG_CONFIGURATION Debug)
|
||||
endif()
|
||||
|
||||
macro(CONFIGURE_PROJ_FILE arg)
|
||||
set(CONFIGURE_FILE_NAME ${arg})
|
||||
set(CONFIGURE_BAK_FILE_NAME ${arg}.bak)
|
||||
if (NOT EXISTS ${CONFIGURE_BAK_FILE_NAME})
|
||||
configure_file(${CONFIGURE_FILE_NAME} ${CONFIGURE_BAK_FILE_NAME} COPYONLY)
|
||||
endif()
|
||||
configure_file(${CONFIGURE_BAK_FILE_NAME} ${CONFIGURE_FILE_NAME} COPYONLY)
|
||||
if (VCPKG_LIBRARY_LINKAGE STREQUAL static)
|
||||
file(READ ${CONFIGURE_FILE_NAME} SLN_CONFIGURE)
|
||||
string(REPLACE "<ConfigurationType>DynamicLibrary<\/ConfigurationType>"
|
||||
"<ConfigurationType>StaticLibrary<\/ConfigurationType>" SLN_CONFIGURE "${SLN_CONFIGURE}")
|
||||
string(REPLACE "\/D_CRT_SECURE_NO_DEPRECATE"
|
||||
"\/D_CRT_SECURE_NO_DEPRECATE \/DIN_CILK_STATIC" SLN_CONFIGURE "${SLN_CONFIGURE}")
|
||||
file(WRITE ${CONFIGURE_FILE_NAME} "${SLN_CONFIGURE}")
|
||||
else()
|
||||
file(READ ${CONFIGURE_FILE_NAME} SLN_CONFIGURE)
|
||||
string(REPLACE "\/D_CRT_SECURE_NO_DEPRECATE"
|
||||
"\/D_CRT_SECURE_NO_DEPRECATE \/DIN_CILK_RUNTIME" SLN_CONFIGURE "${SLN_CONFIGURE}")
|
||||
file(WRITE ${CONFIGURE_FILE_NAME} "${SLN_CONFIGURE}")
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
CONFIGURE_PROJ_FILE(${SOURCE_PATH}/build/vs2013/tbb.vcxproj)
|
||||
CONFIGURE_PROJ_FILE(${SOURCE_PATH}/build/vs2013/tbbmalloc.vcxproj)
|
||||
CONFIGURE_PROJ_FILE(${SOURCE_PATH}/build/vs2013/tbbmalloc_proxy.vcxproj)
|
||||
|
||||
vcpkg_install_msbuild(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PROJECT_SUBPATH build/vs2013/makefile.sln
|
||||
RELEASE_CONFIGURATION ${RELEASE_CONFIGURATION}
|
||||
DEBUG_CONFIGURATION ${DEBUG_CONFIGURATION}
|
||||
)
|
||||
# Settings for TBBConfigForSource.cmake.in
|
||||
# Settings for TBBConfigInternal.cmake.in
|
||||
set(TBB_LIB_EXT lib)
|
||||
set(TBB_LIB_PREFIX)
|
||||
endif()
|
||||
|
@ -50,12 +73,13 @@ file(COPY
|
|||
${SOURCE_PATH}/include/serial
|
||||
DESTINATION ${CURRENT_PACKAGES_DIR}/include)
|
||||
|
||||
# Settings for TBBConfigForSource.cmake.in
|
||||
# Settings for TBBConfigInternal.cmake.in
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
|
||||
set(TBB_DEFAULT_COMPONENTS tbb tbbmalloc)
|
||||
else()
|
||||
set(TBB_DEFAULT_COMPONENTS tbb tbbmalloc tbbmalloc_proxy)
|
||||
endif()
|
||||
|
||||
file(READ "${SOURCE_PATH}/include/tbb/tbb_stddef.h" _tbb_stddef)
|
||||
string(REGEX REPLACE ".*#define TBB_VERSION_MAJOR ([0-9]+).*" "\\1" _tbb_ver_major "${_tbb_stddef}")
|
||||
string(REGEX REPLACE ".*#define TBB_VERSION_MINOR ([0-9]+).*" "\\1" _tbb_ver_minor "${_tbb_stddef}")
|
||||
|
@ -65,7 +89,7 @@ set(TBB_RELEASE_DIR "\${_tbb_root}/lib")
|
|||
set(TBB_DEBUG_DIR "\${_tbb_root}/debug/lib")
|
||||
|
||||
configure_file(
|
||||
${SOURCE_PATH}/cmake/templates/TBBConfigForSource.cmake.in
|
||||
${SOURCE_PATH}/cmake/templates/TBBConfigInternal.cmake.in
|
||||
${CURRENT_PACKAGES_DIR}/share/tbb/TBBConfig.cmake
|
||||
@ONLY
|
||||
)
|
||||
|
@ -76,6 +100,18 @@ string(REPLACE
|
|||
_contents
|
||||
"${_contents}"
|
||||
)
|
||||
string(REPLACE
|
||||
"set(_tbb_release_lib \"/${TBB_LIB_PREFIX}"
|
||||
"set(_tbb_release_lib \"\${_tbb_root}/lib/${TBB_LIB_PREFIX}"
|
||||
_contents
|
||||
"${_contents}"
|
||||
)
|
||||
string(REPLACE
|
||||
"set(_tbb_debug_lib \"/${TBB_LIB_PREFIX}"
|
||||
"set(_tbb_debug_lib \"\${_tbb_root}/debug/lib/${TBB_LIB_PREFIX}"
|
||||
_contents
|
||||
"${_contents}"
|
||||
)
|
||||
string(REPLACE "SHARED IMPORTED)" "UNKNOWN IMPORTED)" _contents "${_contents}")
|
||||
file(WRITE ${CURRENT_PACKAGES_DIR}/share/tbb/TBBConfig.cmake "${_contents}")
|
||||
|
||||
|
@ -84,3 +120,4 @@ file(COPY ${SOURCE_PATH}/LICENSE ${CMAKE_CURRENT_LIST_DIR}/usage DESTINATION ${C
|
|||
file(RENAME ${CURRENT_PACKAGES_DIR}/share/tbb/LICENSE ${CURRENT_PACKAGES_DIR}/share/tbb/copyright)
|
||||
|
||||
vcpkg_test_cmake(PACKAGE_NAME TBB)
|
||||
#
|
||||
|
|
3
cmake/ports/vhacd/CONTROL
Normal file
3
cmake/ports/vhacd/CONTROL
Normal file
|
@ -0,0 +1,3 @@
|
|||
Source: vhacd
|
||||
Version: 20191029
|
||||
Description: vhacd
|
29
cmake/ports/vhacd/copyright
Normal file
29
cmake/ports/vhacd/copyright
Normal file
|
@ -0,0 +1,29 @@
|
|||
BSD 3-Clause License
|
||||
|
||||
Copyright (c) 2011, Khaled Mamou (kmamou at gmail dot com)
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are met:
|
||||
|
||||
1. Redistributions of source code must retain the above copyright notice, this
|
||||
list of conditions and the following disclaimer.
|
||||
|
||||
2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
this list of conditions and the following disclaimer in the documentation
|
||||
and/or other materials provided with the distribution.
|
||||
|
||||
3. Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
31
cmake/ports/vhacd/portfile.cmake
Normal file
31
cmake/ports/vhacd/portfile.cmake
Normal file
|
@ -0,0 +1,31 @@
|
|||
include(vcpkg_common_functions)
|
||||
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
||||
|
||||
# else Linux desktop
|
||||
vcpkg_download_distfile(
|
||||
SOURCE_ARCHIVE
|
||||
URLS https://public.highfidelity.com/dependencies/v-hacd-master.zip
|
||||
SHA512 5d9bd4872ead9eb3574e4806d6c4f490353a04036fd5f571e1e44f47cb66b709e311abcd53af30bae0015a690152170aeed93209a626c28ebcfd6591f3bb036f
|
||||
FILENAME vhacd.zip
|
||||
)
|
||||
|
||||
vcpkg_extract_source_archive_ex(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
ARCHIVE ${SOURCE_ARCHIVE}
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
file(COPY ${CMAKE_CURRENT_LIST_DIR}/copyright DESTINATION ${CURRENT_PACKAGES_DIR}/share/vhacd)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
if (WIN32)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/lib/Release/VHACD_LIB.lib ${CURRENT_PACKAGES_DIR}/lib/VHACD.lib)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/Release)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/debug/lib/Debug/VHACD_LIB.lib ${CURRENT_PACKAGES_DIR}/debug/lib/VHACD.lib)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/Debug)
|
||||
endif()
|
|
@ -1,3 +1,4 @@
|
|||
Source: zlib
|
||||
Version: 1.2.11-3
|
||||
Version: 1.2.11-5
|
||||
Homepage: https://www.zlib.net/
|
||||
Description: A compression library
|
||||
|
|
|
@ -1,16 +1,19 @@
|
|||
include(vcpkg_common_functions)
|
||||
set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/zlib-1.2.11)
|
||||
|
||||
set(VERSION 1.2.11)
|
||||
|
||||
vcpkg_download_distfile(ARCHIVE_FILE
|
||||
URLS "http://www.zlib.net/zlib-1.2.11.tar.gz" "https://downloads.sourceforge.net/project/libpng/zlib/1.2.11/zlib-1.2.11.tar.gz"
|
||||
URLS "http://www.zlib.net/zlib-${VERSION}.tar.gz" "https://downloads.sourceforge.net/project/libpng/zlib/${VERSION}/zlib-${VERSION}.tar.gz"
|
||||
FILENAME "zlib1211.tar.gz"
|
||||
SHA512 73fd3fff4adeccd4894084c15ddac89890cd10ef105dd5e1835e1e9bbb6a49ff229713bd197d203edfa17c2727700fce65a2a235f07568212d820dca88b528ae
|
||||
)
|
||||
vcpkg_extract_source_archive(${ARCHIVE_FILE})
|
||||
|
||||
vcpkg_apply_patches(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
vcpkg_extract_source_archive_ex(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
ARCHIVE ${ARCHIVE_FILE}
|
||||
REF ${VERSION}
|
||||
PATCHES
|
||||
${CMAKE_CURRENT_LIST_DIR}/cmake_dont_build_more_than_needed.patch
|
||||
"cmake_dont_build_more_than_needed.patch"
|
||||
)
|
||||
|
||||
# This is generated during the cmake build
|
||||
|
@ -44,4 +47,4 @@ vcpkg_copy_pdbs()
|
|||
|
||||
file(COPY ${CMAKE_CURRENT_LIST_DIR}/usage DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
|
||||
|
||||
#vcpkg_test_cmake(PACKAGE_NAME ZLIB MODULE)
|
||||
vcpkg_test_cmake(PACKAGE_NAME ZLIB MODULE)
|
||||
|
|
|
@ -767,6 +767,7 @@ void DomainServer::setupNodeListAndAssignments() {
|
|||
packetReceiver.registerListener(PacketType::DomainServerPathQuery, this, "processPathQueryPacket");
|
||||
packetReceiver.registerListener(PacketType::NodeJsonStats, this, "processNodeJSONStatsPacket");
|
||||
packetReceiver.registerListener(PacketType::DomainDisconnectRequest, this, "processNodeDisconnectRequestPacket");
|
||||
packetReceiver.registerListener(PacketType::AvatarZonePresence, this, "processAvatarZonePresencePacket");
|
||||
|
||||
// NodeList won't be available to the settings manager when it is created, so call registerListener here
|
||||
packetReceiver.registerListener(PacketType::DomainSettingsRequest, &_settingsManager, "processSettingsRequestPacket");
|
||||
|
@ -3614,3 +3615,81 @@ void DomainServer::handleOctreeFileReplacementRequest(QSharedPointer<ReceivedMes
|
|||
handleOctreeFileReplacement(message->readAll(), QString(), QString(), username);
|
||||
}
|
||||
}
|
||||
|
||||
void DomainServer::processAvatarZonePresencePacket(QSharedPointer<ReceivedMessage> message) {
|
||||
QUuid avatarID = QUuid::fromRfc4122(message->readWithoutCopy(NUM_BYTES_RFC4122_UUID));
|
||||
QUuid zoneID = QUuid::fromRfc4122(message->readWithoutCopy(NUM_BYTES_RFC4122_UUID));
|
||||
|
||||
if (avatarID.isNull()) {
|
||||
qCWarning(domain_server) << "Ignoring null avatar presence";
|
||||
return;
|
||||
}
|
||||
static const int SCREENSHARE_EXPIRATION_SECONDS = 24 * 60 * 60;
|
||||
screensharePresence(zoneID.isNull() ? "" : zoneID.toString(), avatarID, SCREENSHARE_EXPIRATION_SECONDS);
|
||||
}
|
||||
|
||||
void DomainServer::screensharePresence(QString roomname, QUuid avatarID, int expirationSeconds) {
|
||||
if (!DependencyManager::get<AccountManager>()->hasValidAccessToken()) {
|
||||
static std::once_flag presenceAuthorityWarning;
|
||||
std::call_once(presenceAuthorityWarning, [] {
|
||||
qCDebug(domain_server) << "No authority to send screensharePresence.";
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
auto limitedNodeList = DependencyManager::get<LimitedNodeList>();
|
||||
auto matchingNode = limitedNodeList->nodeWithUUID(avatarID);
|
||||
if (!matchingNode) {
|
||||
qCWarning(domain_server) << "Ignoring avatar presence for unknown avatar ID" << avatarID;
|
||||
return;
|
||||
}
|
||||
QString verifiedUsername = matchingNode->getPermissions().getVerifiedUserName();
|
||||
if (verifiedUsername.isEmpty()) { // Silently bail for users who are not logged in.
|
||||
return;
|
||||
}
|
||||
|
||||
JSONCallbackParameters callbackParams;
|
||||
callbackParams.callbackReceiver = this;
|
||||
callbackParams.jsonCallbackMethod = "handleSuccessfulScreensharePresence";
|
||||
callbackParams.errorCallbackMethod = "handleFailedScreensharePresence";
|
||||
// Construct `callbackData`, which is data that will be available to the callback functions.
|
||||
// In this case, the "success" callback needs access to the "roomname" (the zone ID) and the
|
||||
// relevant avatar's UUID.
|
||||
QJsonObject callbackData;
|
||||
callbackData.insert("roomname", roomname);
|
||||
callbackData.insert("avatarID", avatarID.toString());
|
||||
callbackParams.callbackData = callbackData;
|
||||
const QString PATH = "api/v1/domains/%1/screenshare";
|
||||
QString domain_id = uuidStringWithoutCurlyBraces(getID());
|
||||
QJsonObject json, screenshare;
|
||||
screenshare["username"] = verifiedUsername;
|
||||
screenshare["roomname"] = roomname;
|
||||
if (expirationSeconds > 0) {
|
||||
screenshare["expiration"] = expirationSeconds;
|
||||
}
|
||||
json["screenshare"] = screenshare;
|
||||
DependencyManager::get<AccountManager>()->sendRequest(
|
||||
PATH.arg(domain_id),
|
||||
AccountManagerAuth::Required,
|
||||
QNetworkAccessManager::PostOperation,
|
||||
callbackParams, QJsonDocument(json).toJson()
|
||||
);
|
||||
}
|
||||
|
||||
void DomainServer::handleSuccessfulScreensharePresence(QNetworkReply* requestReply, QJsonObject callbackData) {
|
||||
QJsonObject jsonObject = QJsonDocument::fromJson(requestReply->readAll()).object();
|
||||
if (jsonObject["status"].toString() != "success") {
|
||||
qCWarning(domain_server) << "screensharePresence api call failed:" << QJsonDocument(jsonObject).toJson(QJsonDocument::Compact);
|
||||
return;
|
||||
}
|
||||
|
||||
// Tell the client that we just authorized to screenshare which zone ID in which they are authorized to screenshare.
|
||||
auto nodeList = DependencyManager::get<LimitedNodeList>();
|
||||
auto packet = NLPacket::create(PacketType::AvatarZonePresence, NUM_BYTES_RFC4122_UUID, true);
|
||||
packet->write(QUuid(callbackData["roomname"].toString()).toRfc4122());
|
||||
nodeList->sendPacket(std::move(packet), *(nodeList->nodeWithUUID(QUuid(callbackData["avatarID"].toString()))));
|
||||
}
|
||||
|
||||
void DomainServer::handleFailedScreensharePresence(QNetworkReply* requestReply) {
|
||||
qCWarning(domain_server) << "screensharePresence api call failed:" << requestReply->error();
|
||||
}
|
||||
|
|
|
@ -78,6 +78,8 @@ public:
|
|||
|
||||
bool isAssetServerEnabled();
|
||||
|
||||
void screensharePresence(QString roomname, QUuid avatarID, int expiration_seconds = 0);
|
||||
|
||||
public slots:
|
||||
/// Called by NodeList to inform us a node has been added
|
||||
void nodeAdded(SharedNodePointer node);
|
||||
|
@ -96,6 +98,7 @@ private slots:
|
|||
void processNodeDisconnectRequestPacket(QSharedPointer<ReceivedMessage> message);
|
||||
void processICEServerHeartbeatDenialPacket(QSharedPointer<ReceivedMessage> message);
|
||||
void processICEServerHeartbeatACK(QSharedPointer<ReceivedMessage> message);
|
||||
void processAvatarZonePresencePacket(QSharedPointer<ReceivedMessage> packet);
|
||||
|
||||
void handleDomainContentReplacementFromURLRequest(QSharedPointer<ReceivedMessage> message);
|
||||
void handleOctreeFileReplacementRequest(QSharedPointer<ReceivedMessage> message);
|
||||
|
@ -129,6 +132,9 @@ private slots:
|
|||
void handleSuccessfulICEServerAddressUpdate(QNetworkReply* requestReply);
|
||||
void handleFailedICEServerAddressUpdate(QNetworkReply* requestReply);
|
||||
|
||||
void handleSuccessfulScreensharePresence(QNetworkReply* requestReply, QJsonObject callbackData);
|
||||
void handleFailedScreensharePresence(QNetworkReply* requestReply);
|
||||
|
||||
void updateReplicatedNodes();
|
||||
void updateDownstreamNodes();
|
||||
void updateUpstreamNodes();
|
||||
|
|
78
hifi_qt.py
Normal file
78
hifi_qt.py
Normal file
|
@ -0,0 +1,78 @@
|
|||
import hifi_utils
|
||||
import hifi_android
|
||||
import hashlib
|
||||
import os
|
||||
import platform
|
||||
import re
|
||||
import shutil
|
||||
import tempfile
|
||||
import json
|
||||
import xml.etree.ElementTree as ET
|
||||
import functools
|
||||
|
||||
print = functools.partial(print, flush=True)
|
||||
|
||||
# Encapsulates the vcpkg system
|
||||
class QtDownloader:
|
||||
CMAKE_TEMPLATE = """
|
||||
# this file auto-generated by hifi_qt.py
|
||||
get_filename_component(QT_CMAKE_PREFIX_PATH "{}" ABSOLUTE CACHE)
|
||||
get_filename_component(QT_CMAKE_PREFIX_PATH_UNCACHED "{}" ABSOLUTE)
|
||||
|
||||
# If the cached cmake toolchain path is different from the computed one, exit
|
||||
if(NOT (QT_CMAKE_PREFIX_PATH_UNCACHED STREQUAL QT_CMAKE_PREFIX_PATH))
|
||||
message(FATAL_ERROR "QT_CMAKE_PREFIX_PATH has changed, please wipe the build directory and rerun cmake")
|
||||
endif()
|
||||
"""
|
||||
def __init__(self, args):
|
||||
self.args = args
|
||||
self.configFilePath = os.path.join(args.build_root, 'qt.cmake')
|
||||
self.version = '5.12.3'
|
||||
|
||||
defaultBasePath = os.path.expanduser('~/hifi/qt')
|
||||
self.basePath = os.getenv('HIFI_QT_BASE', defaultBasePath)
|
||||
if (not os.path.isdir(self.basePath)):
|
||||
os.makedirs(self.basePath)
|
||||
self.path = os.path.join(self.basePath, self.version)
|
||||
self.fullPath = os.path.join(self.path, 'qt5-install')
|
||||
self.cmakePath = os.path.join(self.fullPath, 'lib/cmake')
|
||||
|
||||
print("Using qt path {}".format(self.path))
|
||||
lockDir, lockName = os.path.split(self.path)
|
||||
lockName += '.lock'
|
||||
if not os.path.isdir(lockDir):
|
||||
os.makedirs(lockDir)
|
||||
|
||||
self.lockFile = os.path.join(lockDir, lockName)
|
||||
|
||||
# OS dependent information
|
||||
system = platform.system()
|
||||
|
||||
if 'Windows' == system:
|
||||
self.qtUrl = 'https://hifi-public.s3.amazonaws.com/dependencies/vcpkg/qt5-install-5.12.3-windows3.tar.gz?versionId=5ADqP0M0j5ZfimUHrx4zJld6vYceHEsI'
|
||||
elif 'Darwin' == system:
|
||||
self.qtUrl = 'https://hifi-public.s3.amazonaws.com/dependencies/vcpkg/qt5-install-5.12.3-macos.tar.gz?versionId=bLAgnoJ8IMKpqv8NFDcAu8hsyQy3Rwwz'
|
||||
elif 'Linux' == system:
|
||||
if platform.linux_distribution()[1][:3] == '16.':
|
||||
self.qtUrl = 'https://hifi-public.s3.amazonaws.com/dependencies/vcpkg/qt5-install-5.12.3-ubuntu-16.04-with-symbols.tar.gz'
|
||||
elif platform.linux_distribution()[1][:3] == '18.':
|
||||
self.qtUrl = 'https://hifi-public.s3.amazonaws.com/dependencies/vcpkg/qt5-install-5.12.3-ubuntu-18.04.tar.gz'
|
||||
else:
|
||||
raise Exception('UNKNOWN LINUX VERSION!!!')
|
||||
else:
|
||||
raise Exception('UNKNOWN OPERATING SYSTEM!!!')
|
||||
|
||||
def writeConfig(self):
|
||||
print("Writing cmake config to {}".format(self.configFilePath))
|
||||
# Write out the configuration for use by CMake
|
||||
cmakeConfig = QtDownloader.CMAKE_TEMPLATE.format(self.cmakePath, self.cmakePath).replace('\\', '/')
|
||||
with open(self.configFilePath, 'w') as f:
|
||||
f.write(cmakeConfig)
|
||||
|
||||
def installQt(self):
|
||||
if not os.path.isdir(self.fullPath):
|
||||
print ('Downloading Qt from AWS')
|
||||
print('Extracting ' + self.qtUrl + ' to ' + self.path)
|
||||
hifi_utils.downloadAndExtract(self.qtUrl, self.path)
|
||||
else:
|
||||
print ('Qt has already been downloaded')
|
|
@ -113,7 +113,7 @@ def downloadFile(url, hash=None, hasher=hashlib.sha512(), retries=3):
|
|||
|
||||
def downloadAndExtract(url, destPath, hash=None, hasher=hashlib.sha512(), isZip=False):
|
||||
tempFileName = downloadFile(url, hash, hasher)
|
||||
if isZip:
|
||||
if isZip or ".zip" in url:
|
||||
with zipfile.ZipFile(tempFileName) as zip:
|
||||
zip.extractall(destPath)
|
||||
else:
|
||||
|
|
136
hifi_vcpkg.py
136
hifi_vcpkg.py
|
@ -22,7 +22,6 @@ get_filename_component(CMAKE_TOOLCHAIN_FILE "{}" ABSOLUTE CACHE)
|
|||
get_filename_component(CMAKE_TOOLCHAIN_FILE_UNCACHED "{}" ABSOLUTE)
|
||||
set(VCPKG_INSTALL_ROOT "{}")
|
||||
set(VCPKG_TOOLS_DIR "{}")
|
||||
set(VCPKG_QT_CMAKE_PREFIX_PATH "{}")
|
||||
"""
|
||||
|
||||
CMAKE_TEMPLATE_NON_ANDROID = """
|
||||
|
@ -40,19 +39,24 @@ endif()
|
|||
self.configFilePath = os.path.join(args.build_root, 'vcpkg.cmake')
|
||||
self.assets_url = self.readVar('EXTERNAL_BUILD_ASSETS')
|
||||
|
||||
# The noClean flag indicates we're doing weird dependency maintenance stuff
|
||||
# i.e. we've got an explicit checkout of vcpkg and we don't want the script to
|
||||
# do stuff it might otherwise do. It typically indicates that we're using our
|
||||
# own git checkout of vcpkg and manually managing it
|
||||
self.noClean = False
|
||||
|
||||
# OS dependent information
|
||||
system = platform.system()
|
||||
|
||||
if self.args.vcpkg_root is not None:
|
||||
if 'HIFI_VCPKG_PATH' in os.environ:
|
||||
self.path = os.environ['HIFI_VCPKG_PATH']
|
||||
self.noClean = True
|
||||
elif self.args.vcpkg_root is not None:
|
||||
self.path = args.vcpkg_root
|
||||
self.noClean = True
|
||||
else:
|
||||
if 'Darwin' == system:
|
||||
defaultBasePath = os.path.expanduser('~/hifi/vcpkg')
|
||||
else:
|
||||
defaultBasePath = os.path.join(tempfile.gettempdir(), 'hifi', 'vcpkg')
|
||||
self.basePath = os.getenv('HIFI_VCPKG_BASE', defaultBasePath)
|
||||
if self.basePath == defaultBasePath:
|
||||
print("Warning: Environment variable HIFI_VCPKG_BASE not set, using {}".format(defaultBasePath))
|
||||
if self.args.android:
|
||||
self.basePath = os.path.join(self.basePath, 'android')
|
||||
if (not os.path.isdir(self.basePath)):
|
||||
|
@ -67,27 +71,36 @@ endif()
|
|||
|
||||
self.lockFile = os.path.join(lockDir, lockName)
|
||||
self.tagFile = os.path.join(self.path, '.id')
|
||||
self.prebuildTagFile = os.path.join(self.path, '.prebuild')
|
||||
# A format version attached to the tag file... increment when you want to force the build systems to rebuild
|
||||
# without the contents of the ports changing
|
||||
self.version = 1
|
||||
self.tagContents = "{}_{}".format(self.id, self.version)
|
||||
self.bootstrapEnv = os.environ.copy()
|
||||
self.buildEnv = os.environ.copy()
|
||||
self.prebuiltArchive = None
|
||||
usePrebuilt = ('CI_BUILD' in os.environ) and os.environ["CI_BUILD"] == "Github" and (not self.noClean)
|
||||
|
||||
if 'Windows' == system:
|
||||
self.exe = os.path.join(self.path, 'vcpkg.exe')
|
||||
self.bootstrapCmd = 'bootstrap-vcpkg.bat'
|
||||
self.vcpkgUrl = self.assets_url + '/dependencies/vcpkg/vcpkg-win32.tar.gz%3FversionId=YZYkDejDRk7L_hrK_WVFthWvisAhbDzZ'
|
||||
self.vcpkgHash = '3e0ff829a74956491d57666109b3e6b5ce4ed0735c24093884317102387b2cb1b2cd1ff38af9ed9173501f6e32ffa05cc6fe6d470b77a71ca1ffc3e0aa46ab9e'
|
||||
self.bootstrapCmds = [ os.path.join(self.path, 'bootstrap-vcpkg.bat') ]
|
||||
self.vcpkgUrl = self.assets_url + '/dependencies/vcpkg/builds/vcpkg-win32-client.zip%3FversionId=tSFzbw01VkkVFeRQ6YuAY4dro2HxJR9U'
|
||||
self.vcpkgHash = 'a650db47a63ccdc9904b68ddd16af74772e7e78170b513ea8de5a3b47d032751a3b73dcc7526d88bcb500753ea3dd9880639ca842bb176e2bddb1710f9a58cd3'
|
||||
self.hostTriplet = 'x64-windows'
|
||||
if usePrebuilt:
|
||||
self.prebuiltArchive = self.assets_url + "/dependencies/vcpkg/builds/vcpkg-win32.zip?versionId=3SF3mDC8dkQH1JP041m88xnYmWNzZflx"
|
||||
elif 'Darwin' == system:
|
||||
self.exe = os.path.join(self.path, 'vcpkg')
|
||||
self.bootstrapCmd = 'bootstrap-vcpkg.sh'
|
||||
self.vcpkgUrl = self.assets_url + '/dependencies/vcpkg/vcpkg-osx.tar.gz%3FversionId=_fhqSxjfrtDJBvEsQ8L_ODcdUjlpX9cc'
|
||||
self.bootstrapCmds = [ os.path.join(self.path, 'bootstrap-vcpkg.sh'), '--allowAppleClang' ]
|
||||
self.vcpkgUrl = self.assets_url + '/dependencies/vcpkg/builds/vcpkg-osx-client.tgz%3FversionId=j0b4azo_zTlH_Q9DElEWOz1UMYZ2nqQw'
|
||||
self.vcpkgHash = '519d666d02ef22b87c793f016ca412e70f92e1d55953c8f9bd4ee40f6d9f78c1df01a6ee293907718f3bbf24075cc35492fb216326dfc50712a95858e9cbcb4d'
|
||||
self.hostTriplet = 'x64-osx'
|
||||
if usePrebuilt:
|
||||
self.prebuiltArchive = self.assets_url + "/dependencies/vcpkg/builds/vcpkg-osx.tgz?versionId=6JrIMTdvpBF3MAsjA92BMkO79Psjzs6Z"
|
||||
else:
|
||||
self.exe = os.path.join(self.path, 'vcpkg')
|
||||
self.bootstrapCmd = 'bootstrap-vcpkg.sh'
|
||||
self.vcpkgUrl = self.assets_url + '/dependencies/vcpkg/vcpkg-linux.tar.gz%3FversionId=97Nazh24etEVKWz33XwgLY0bvxEfZgMU'
|
||||
self.bootstrapCmds = [ os.path.join(self.path, 'bootstrap-vcpkg.sh') ]
|
||||
self.vcpkgUrl = self.assets_url + '/dependencies/vcpkg/builds/vcpkg-linux-client.tgz%3FversionId=y7mct0gFicEXz5hJy3KROBugcLR56YWf'
|
||||
self.vcpkgHash = '6a1ce47ef6621e699a4627e8821ad32528c82fce62a6939d35b205da2d299aaa405b5f392df4a9e5343dd6a296516e341105fbb2dd8b48864781d129d7fba10d'
|
||||
self.hostTriplet = 'x64-linux'
|
||||
|
||||
|
@ -103,7 +116,7 @@ endif()
|
|||
|
||||
def upToDate(self):
|
||||
# Prevent doing a clean if we've explcitly set a directory for vcpkg
|
||||
if self.args.vcpkg_root is not None:
|
||||
if self.noClean:
|
||||
return True
|
||||
|
||||
if self.args.force_build:
|
||||
|
@ -145,8 +158,10 @@ endif()
|
|||
self.copyEnv()
|
||||
return
|
||||
|
||||
self.clean()
|
||||
if self.prebuiltArchive is not None:
|
||||
return
|
||||
|
||||
self.clean()
|
||||
downloadVcpkg = False
|
||||
if self.args.force_bootstrap:
|
||||
print("Forcing bootstrap")
|
||||
|
@ -167,10 +182,10 @@ endif()
|
|||
print("Cloning vcpkg from github to {}".format(self.path))
|
||||
hifi_utils.executeSubprocess(['git', 'clone', 'https://github.com/microsoft/vcpkg', self.path])
|
||||
print("Bootstrapping vcpkg")
|
||||
hifi_utils.executeSubprocess([self.bootstrapCmd], folder=self.path)
|
||||
hifi_utils.executeSubprocess(self.bootstrapCmds, folder=self.path, env=self.bootstrapEnv)
|
||||
else:
|
||||
print("Fetching vcpkg from {} to {}".format(self.vcpkgUrl, self.path))
|
||||
hifi_utils.downloadAndExtract(self.vcpkgUrl, self.path, self.vcpkgHash)
|
||||
hifi_utils.downloadAndExtract(self.vcpkgUrl, self.path)
|
||||
|
||||
print("Replacing port files")
|
||||
portsPath = os.path.join(self.path, 'ports')
|
||||
|
@ -186,9 +201,19 @@ endif()
|
|||
actualCommands.extend(commands)
|
||||
print("Running command")
|
||||
print(actualCommands)
|
||||
hifi_utils.executeSubprocess(actualCommands, folder=self.path)
|
||||
hifi_utils.executeSubprocess(actualCommands, folder=self.path, env=self.buildEnv)
|
||||
|
||||
def setupDependencies(self, qt=None):
|
||||
if self.prebuiltArchive:
|
||||
if not os.path.isfile(self.prebuildTagFile):
|
||||
print('Extracting ' + self.prebuiltArchive + ' to ' + self.path)
|
||||
hifi_utils.downloadAndExtract(self.prebuiltArchive, self.path)
|
||||
self.writePrebuildTag()
|
||||
return
|
||||
|
||||
if qt is not None:
|
||||
self.buildEnv['QT_CMAKE_PREFIX_PATH'] = qt
|
||||
|
||||
def setupDependencies(self):
|
||||
# Special case for android, grab a bunch of binaries
|
||||
# FIXME remove special casing for android builds eventually
|
||||
if self.args.android:
|
||||
|
@ -203,12 +228,9 @@ endif()
|
|||
print("Installing build dependencies")
|
||||
self.run(['install', '--triplet', self.triplet, 'hifi-client-deps'])
|
||||
|
||||
# If not android, install our Qt build
|
||||
if not self.args.android:
|
||||
print("Installing Qt")
|
||||
self.installQt()
|
||||
|
||||
def cleanBuilds(self):
|
||||
if self.noClean:
|
||||
return
|
||||
# Remove temporary build artifacts
|
||||
builddir = os.path.join(self.path, 'buildtrees')
|
||||
if os.path.isdir(builddir):
|
||||
|
@ -238,16 +260,18 @@ endif()
|
|||
hifi_utils.downloadAndExtract(url, dest, isZip=zipFile, hash=package['checksum'], hasher=hashlib.md5())
|
||||
|
||||
def writeTag(self):
|
||||
if self.noClean:
|
||||
return
|
||||
print("Writing tag {} to {}".format(self.tagContents, self.tagFile))
|
||||
if not os.path.isdir(self.path):
|
||||
os.makedirs(self.path)
|
||||
with open(self.tagFile, 'w') as f:
|
||||
f.write(self.tagContents)
|
||||
|
||||
def getQt5InstallPath(self):
|
||||
qt5InstallPath = os.path.join(self.path, 'installed', 'qt5-install')
|
||||
if self.args.android:
|
||||
precompiled = os.path.realpath(self.androidPackagePath)
|
||||
qt5InstallPath = os.path.realpath(os.path.join(precompiled, 'qt'))
|
||||
return qt5InstallPath
|
||||
def writePrebuildTag(self):
|
||||
print("Writing tag {} to {}".format(self.tagContents, self.tagFile))
|
||||
with open(self.prebuildTagFile, 'w') as f:
|
||||
f.write(self.tagContents)
|
||||
|
||||
def writeConfig(self):
|
||||
print("Writing cmake config to {}".format(self.configFilePath))
|
||||
|
@ -262,9 +286,7 @@ endif()
|
|||
cmakeTemplate += 'set(HIFI_ANDROID_PRECOMPILED "{}")\n'.format(precompiled)
|
||||
else:
|
||||
cmakeTemplate += VcpkgRepo.CMAKE_TEMPLATE_NON_ANDROID
|
||||
|
||||
qtCmakePrefixPath = os.path.join(self.getQt5InstallPath(), "lib/cmake")
|
||||
cmakeConfig = cmakeTemplate.format(cmakeScript, cmakeScript, installPath, toolsPath, qtCmakePrefixPath).replace('\\', '/')
|
||||
cmakeConfig = cmakeTemplate.format(cmakeScript, cmakeScript, installPath, toolsPath).replace('\\', '/')
|
||||
with open(self.configFilePath, 'w') as f:
|
||||
f.write(cmakeConfig)
|
||||
|
||||
|
@ -273,49 +295,3 @@ endif()
|
|||
# update the tag file on every run, we can scan the base dir for sub directories containing
|
||||
# a tag file that is older than N days, and if found, delete the directory, recovering space
|
||||
print("Not implemented")
|
||||
|
||||
|
||||
def installQt(self):
|
||||
qt5InstallPath = self.getQt5InstallPath()
|
||||
if not os.path.isdir(qt5InstallPath):
|
||||
print ('Downloading Qt from AWS')
|
||||
dest, tail = os.path.split(qt5InstallPath)
|
||||
|
||||
url = 'NOT DEFINED'
|
||||
if platform.system() == 'Windows':
|
||||
url = self.assets_url + '/dependencies/vcpkg/qt5-install-5.12.3-windows3.tar.gz'
|
||||
elif platform.system() == 'Darwin':
|
||||
url = self.assets_url + '/dependencies/vcpkg/qt5-install-5.12.3-macos.tar.gz%3FversionId=bLAgnoJ8IMKpqv8NFDcAu8hsyQy3Rwwz'
|
||||
elif platform.system() == 'Linux':
|
||||
dist = distro.linux_distribution()
|
||||
|
||||
if distro.id() == 'ubuntu':
|
||||
u_major = int( distro.major_version() )
|
||||
u_minor = int( distro.minor_version() )
|
||||
|
||||
if u_major == 16:
|
||||
url = self.assets_url + '/dependencies/vcpkg/qt5-install-5.12.3-ubuntu-16.04-with-symbols.tar.gz'
|
||||
elif u_major == 18:
|
||||
url = self.assets_url + '/dependencies/vcpkg/qt5-install-5.12.3-ubuntu-18.04.tar.gz'
|
||||
elif u_major == 19 and u_minor == 10:
|
||||
url = self.assets_url + '/dependencies/vcpkg/qt5-install-5.12.6-ubuntu-19.10.tar.xz'
|
||||
elif u_major > 18 and ( u_major != 19 and u_minor != 4):
|
||||
print("We don't support " + distro.name(pretty=True) + " yet. Perhaps consider helping us out?")
|
||||
else:
|
||||
print("Sorry, " + distro.name(pretty=True) + " is old and won't be officially supported. Please consider upgrading.");
|
||||
else:
|
||||
print("Sorry, " + distro.name(pretty=True) + " is not supported. Please consider helping us out.")
|
||||
print("It's also possible to build Qt for your distribution, please see the documentation at:")
|
||||
print("https://github.com/kasenvr/project-athena/tree/kasen/core/tools/qt-builder")
|
||||
return;
|
||||
else:
|
||||
print('UNKNOWN OPERATING SYSTEM!!!')
|
||||
print("System : " + platform.system())
|
||||
print("Architecture: " + platform.architecture())
|
||||
print("Machine : " + platform.machine())
|
||||
return;
|
||||
|
||||
print('Extracting ' + url + ' to ' + dest)
|
||||
hifi_utils.downloadAndExtract(url, dest)
|
||||
else:
|
||||
print ('Qt has already been downloaded')
|
||||
|
|
|
@ -190,7 +190,10 @@ if (BUILD_TOOLS AND NPM_EXECUTABLE)
|
|||
add_dependencies(resources jsdoc)
|
||||
endif()
|
||||
|
||||
add_dependencies(${TARGET_NAME} resources)
|
||||
if (WIN32 OR APPLE)
|
||||
add_dependencies(${TARGET_NAME} resources screenshare)
|
||||
endif()
|
||||
|
||||
|
||||
if (WIN32)
|
||||
# These are external plugins, but we need to do the 'add dependency' here so that their
|
||||
|
@ -328,6 +331,10 @@ if (APPLE)
|
|||
COMMAND "${CMAKE_COMMAND}" -E copy_directory
|
||||
"${CMAKE_SOURCE_DIR}/scripts"
|
||||
"${RESOURCES_DEV_DIR}/scripts"
|
||||
# copy screenshare app to the resource folder
|
||||
COMMAND "${CMAKE_COMMAND}" -E copy_directory
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/../screenshare/hifi-screenshare-darwin-x64/hifi-screenshare.app"
|
||||
"${RESOURCES_DEV_DIR}/hifi-screenshare.app"
|
||||
# copy JSDoc files beside the executable
|
||||
COMMAND "${CMAKE_COMMAND}" -E copy_directory
|
||||
"${CMAKE_SOURCE_DIR}/tools/jsdoc/out"
|
||||
|
|
BIN
interface/resources/avatar/animations/afk_texting.fbx
Normal file
BIN
interface/resources/avatar/animations/afk_texting.fbx
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
interface/resources/avatar/animations/settle_to_idle.fbx
Normal file
BIN
interface/resources/avatar/animations/settle_to_idle.fbx
Normal file
Binary file not shown.
BIN
interface/resources/avatar/animations/settle_to_idle02.fbx
Normal file
BIN
interface/resources/avatar/animations/settle_to_idle02.fbx
Normal file
Binary file not shown.
BIN
interface/resources/avatar/animations/settle_to_idle03.fbx
Normal file
BIN
interface/resources/avatar/animations/settle_to_idle03.fbx
Normal file
Binary file not shown.
BIN
interface/resources/avatar/animations/settle_to_idle04.fbx
Normal file
BIN
interface/resources/avatar/animations/settle_to_idle04.fbx
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
interface/resources/avatar/animations/sitting_turn_left.fbx
Normal file
BIN
interface/resources/avatar/animations/sitting_turn_left.fbx
Normal file
Binary file not shown.
BIN
interface/resources/avatar/animations/sitting_turn_right.fbx
Normal file
BIN
interface/resources/avatar/animations/sitting_turn_right.fbx
Normal file
Binary file not shown.
6864
interface/resources/avatar/avatar-animation-optimized-ik.json
Normal file
6864
interface/resources/avatar/avatar-animation-optimized-ik.json
Normal file
File diff suppressed because it is too large
Load diff
|
@ -681,6 +681,8 @@
|
|||
{
|
||||
"children": [
|
||||
{
|
||||
"children": [
|
||||
{
|
||||
"children": [
|
||||
{
|
||||
"children": [
|
||||
|
@ -815,9 +817,163 @@
|
|||
"triggerRandomSwitch": "seatedIdleSwitch",
|
||||
"triggerTimeMax": 10
|
||||
},
|
||||
"id": "masterSeatedIdle",
|
||||
"id": "masterSeatedIdleRand",
|
||||
"type": "randomSwitchStateMachine"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"endFrame": 200,
|
||||
"loopFlag": true,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/sitting_turn_left.fbx"
|
||||
},
|
||||
"id": "seatedTurnLeft",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"endFrame": 200,
|
||||
"loopFlag": true,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/sitting_turn_right.fbx"
|
||||
},
|
||||
"id": "seatedTurnRight",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"endFrame": 45,
|
||||
"loopFlag": false,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_sitturnright_to_sitidle.fbx"
|
||||
},
|
||||
"id": "seatedTurnRight_to_Idle",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"endFrame": 45,
|
||||
"loopFlag": false,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_sitturnleft_to_sitidle.fbx"
|
||||
},
|
||||
"id": "seatedTurnLeft_to_Idle",
|
||||
"type": "clip"
|
||||
}
|
||||
],
|
||||
"data": {
|
||||
"currentState": "masterSeatedIdleRand",
|
||||
"states": [
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "masterSeatedIdleRand",
|
||||
"interpDuration": 15,
|
||||
"interpTarget": 15,
|
||||
"interpType": "snapshotPrev",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "seatedTurnLeft",
|
||||
"var": "isSeatedTurningLeft"
|
||||
},
|
||||
{
|
||||
"state": "seatedTurnRight",
|
||||
"var": "isSeatedTurningRight"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "seatedTurnLeft",
|
||||
"interpDuration": 22,
|
||||
"interpTarget": 22,
|
||||
"interpType": "evaluateBoth",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "seatedTurnLeft_to_Idle",
|
||||
"var": "isSeatedNotTurning"
|
||||
},
|
||||
{
|
||||
"state": "seatedTurnRight",
|
||||
"var": "isSeatedTurningRight"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "seatedTurnRight",
|
||||
"interpDuration": 22,
|
||||
"interpTarget": 22,
|
||||
"interpType": "evaluateBoth",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "seatedTurnLeft",
|
||||
"var": "isSeatedTurningLeft"
|
||||
},
|
||||
{
|
||||
"state": "seatedTurnRight_to_Idle",
|
||||
"var": "isSeatedNotTurning"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "seatedTurnRight_to_Idle",
|
||||
"interpDuration": 22,
|
||||
"interpTarget": 22,
|
||||
"interpType": "evaluateBoth",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "seatedTurnLeft",
|
||||
"var": "isSeatedTurningLeft"
|
||||
},
|
||||
{
|
||||
"state": "seatedTurnRight",
|
||||
"var": "isSeatedTurningRight"
|
||||
},
|
||||
{
|
||||
"state": "masterSeatedIdleRand",
|
||||
"var": "seatedTurnRight_to_IdleOnDone"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "seatedTurnLeft_to_Idle",
|
||||
"interpDuration": 22,
|
||||
"interpTarget": 22,
|
||||
"interpType": "evaluateBoth",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "seatedTurnRight",
|
||||
"var": "isSeatedTurningRight"
|
||||
},
|
||||
{
|
||||
"state": "seatedTurnLeft",
|
||||
"var": "isSeatedTurningLeft"
|
||||
},
|
||||
{
|
||||
"state": "masterSeatedIdleRand",
|
||||
"var": "seatedTurnLeft_to_IdleOnDone"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"id": "masterSeatedIdle",
|
||||
"type": "stateMachine"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
{
|
||||
|
@ -1082,6 +1238,14 @@
|
|||
{
|
||||
"randomSwitchState": "masterSeatedIdle",
|
||||
"var": "seatedFidgetShakeLegsOnDone"
|
||||
},
|
||||
{
|
||||
"randomSwitchState": "masterSeatedIdle",
|
||||
"var": "isSeatedTurningRight"
|
||||
},
|
||||
{
|
||||
"randomSwitchState": "masterSeatedIdle",
|
||||
"var": "isSeatedTurningLeft"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
@ -4802,6 +4966,8 @@
|
|||
"id": "idleToWalkFwd",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
|
@ -4810,10 +4976,109 @@
|
|||
"loopFlag": false,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_to_idle_small.fbx"
|
||||
"url": "qrc:///avatar/animations/settle_to_idle.fbx"
|
||||
},
|
||||
"id": "idleSettle01",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"blendType": "",
|
||||
"endFrame": 40,
|
||||
"loopFlag": false,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_to_idle02.fbx"
|
||||
},
|
||||
"id": "idleSettle02",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"endFrame": 60,
|
||||
"loopFlag": false,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_to_idle03.fbx"
|
||||
},
|
||||
"id": "idleSettle03",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"endFrame": 82,
|
||||
"loopFlag": false,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_to_idle04.fbx"
|
||||
},
|
||||
"id": "idleSettle04",
|
||||
"type": "clip"
|
||||
}
|
||||
],
|
||||
"data": {
|
||||
"currentState": "idleSettle01",
|
||||
"endFrame": 59,
|
||||
"loopFlag": false,
|
||||
"randomSwitchTimeMin": 1,
|
||||
"startFrame": 1,
|
||||
"states": [
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "idleSettle01",
|
||||
"interpDuration": 1,
|
||||
"interpTarget": 1,
|
||||
"interpType": "evaluateBoth",
|
||||
"priority": 1,
|
||||
"resume": false,
|
||||
"transitions": [
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "idleSettle02",
|
||||
"interpDuration": 1,
|
||||
"interpTarget": 1,
|
||||
"interpType": "evaluateBoth",
|
||||
"priority": 1,
|
||||
"resume": false,
|
||||
"transitions": [
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "idleSettle03",
|
||||
"interpDuration": 1,
|
||||
"interpTarget": 1,
|
||||
"interpType": "evaluateBoth",
|
||||
"priority": 1,
|
||||
"resume": false,
|
||||
"transitions": [
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "idleSettle04",
|
||||
"interpDuration": 1,
|
||||
"interpTarget": 1,
|
||||
"interpType": "evaluateBoth",
|
||||
"priority": 1,
|
||||
"resume": false,
|
||||
"transitions": [
|
||||
]
|
||||
}
|
||||
],
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_to_idle.fbx"
|
||||
},
|
||||
"id": "idleSettle",
|
||||
"type": "clip"
|
||||
"type": "randomSwitchStateMachine"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
|
@ -5346,6 +5611,19 @@
|
|||
},
|
||||
"id": "LANDRUN",
|
||||
"type": "clip"
|
||||
},
|
||||
{
|
||||
"children": [
|
||||
],
|
||||
"data": {
|
||||
"endFrame": 40,
|
||||
"loopFlag": false,
|
||||
"startFrame": 1,
|
||||
"timeScale": 1,
|
||||
"url": "qrc:///avatar/animations/settle_to_idle_small.fbx"
|
||||
},
|
||||
"id": "idleSettleSmall",
|
||||
"type": "clip"
|
||||
}
|
||||
],
|
||||
"data": {
|
||||
|
@ -5371,7 +5649,7 @@
|
|||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "idle",
|
||||
"interpDuration": 15,
|
||||
"interpDuration": 20,
|
||||
"interpTarget": 20,
|
||||
"interpType": "evaluateBoth",
|
||||
"transitions": [
|
||||
|
@ -5503,13 +5781,114 @@
|
|||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "idleSettle",
|
||||
"interpDuration": 13,
|
||||
"interpTarget": 14,
|
||||
"interpDuration": 15,
|
||||
"interpTarget": 15,
|
||||
"interpType": "snapshotPrev",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "idleSettleOnDone"
|
||||
"var": "idleSettle01OnDone"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "idleSettle02OnDone"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "idleSettle03OnDone"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "idleSettle04OnDone"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "reactionPositiveTrigger"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "reactionNegativeTrigger"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "reactionRaiseHandEnabled"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "reactionApplaudEnabled"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "reactionPointEnabled"
|
||||
},
|
||||
{
|
||||
"state": "WALKFWD",
|
||||
"var": "isInputForward"
|
||||
},
|
||||
{
|
||||
"state": "WALKBWD",
|
||||
"var": "isInputBackward"
|
||||
},
|
||||
{
|
||||
"state": "STRAFERIGHT",
|
||||
"var": "isInputRight"
|
||||
},
|
||||
{
|
||||
"state": "STRAFELEFT",
|
||||
"var": "isInputLeft"
|
||||
},
|
||||
{
|
||||
"state": "strafeRightHmd",
|
||||
"var": "isMovingRightHmd"
|
||||
},
|
||||
{
|
||||
"state": "strafeLeftHmd",
|
||||
"var": "isMovingLeftHmd"
|
||||
},
|
||||
{
|
||||
"state": "turnRight",
|
||||
"var": "isTurningRight"
|
||||
},
|
||||
{
|
||||
"state": "turnLeft",
|
||||
"var": "isTurningLeft"
|
||||
},
|
||||
{
|
||||
"state": "fly",
|
||||
"var": "isFlying"
|
||||
},
|
||||
{
|
||||
"state": "takeoffStand",
|
||||
"var": "isTakeoffStand"
|
||||
},
|
||||
{
|
||||
"state": "TAKEOFFRUN",
|
||||
"var": "isTakeoffRun"
|
||||
},
|
||||
{
|
||||
"state": "inAirStand",
|
||||
"var": "isInAirStand"
|
||||
},
|
||||
{
|
||||
"state": "INAIRRUN",
|
||||
"var": "isInAirRun"
|
||||
},
|
||||
{
|
||||
"state": "seated",
|
||||
"var": "isSeated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"easingType": "easeInOutQuad",
|
||||
"id": "idleSettleSmall",
|
||||
"interpDuration": 10,
|
||||
"interpTarget": 10,
|
||||
"interpType": "snapshotPrev",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "idle",
|
||||
"var": "idleSettleSmallOnDone"
|
||||
},
|
||||
{
|
||||
"state": "idle",
|
||||
|
@ -5595,6 +5974,10 @@
|
|||
"interpTarget": 35,
|
||||
"interpType": "snapshotPrev",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "idleSettleSmall",
|
||||
"var": "isNotInputNoMomentum"
|
||||
},
|
||||
{
|
||||
"state": "idleSettle",
|
||||
"var": "isNotInputSlow"
|
||||
|
@ -5659,6 +6042,10 @@
|
|||
"interpTarget": 35,
|
||||
"interpType": "snapshotPrev",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "idleSettleSmall",
|
||||
"var": "isNotInputNoMomentum"
|
||||
},
|
||||
{
|
||||
"state": "idleSettle",
|
||||
"var": "isNotInputSlow"
|
||||
|
@ -5723,6 +6110,10 @@
|
|||
"interpTarget": 25,
|
||||
"interpType": "snapshotPrev",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "idleSettleSmall",
|
||||
"var": "isNotInputNoMomentum"
|
||||
},
|
||||
{
|
||||
"state": "idleSettle",
|
||||
"var": "isNotInputSlow"
|
||||
|
@ -5779,6 +6170,10 @@
|
|||
"interpTarget": 25,
|
||||
"interpType": "snapshotPrev",
|
||||
"transitions": [
|
||||
{
|
||||
"state": "idleSettleSmall",
|
||||
"var": "isNotInputNoMomentum"
|
||||
},
|
||||
{
|
||||
"state": "idleSettle",
|
||||
"var": "isNotInputSlow"
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -269,6 +269,8 @@
|
|||
{ "from": "Keyboard.MouseWheelDown", "to": "Actions.LATERAL_LEFT" },
|
||||
{ "from": "Keyboard.MouseWheelLeft", "to": "Actions.BOOM_OUT", "filters": [ { "type": "scale", "scale": 0.02 } ]},
|
||||
{ "from": "Keyboard.MouseWheelRight", "to": "Actions.BOOM_IN", "filters": [ { "type": "scale", "scale": 0.02 } ]},
|
||||
{ "from": "Keyboard.GesturePinchOut", "to": "Actions.BOOM_OUT"},
|
||||
{ "from": "Keyboard.GesturePinchIn", "to": "Actions.BOOM_IN"},
|
||||
|
||||
{ "from": "Keyboard.Space", "to": "Actions.VERTICAL_UP" },
|
||||
{ "from": "Keyboard.R", "to": "Actions.ACTION1" },
|
||||
|
|
71
interface/resources/controllers/osc.json
Normal file
71
interface/resources/controllers/osc.json
Normal file
|
@ -0,0 +1,71 @@
|
|||
{
|
||||
"name": "OSC to Standard",
|
||||
"channels": [
|
||||
{ "from": "OSC.Head", "to" : "Standard.Head" },
|
||||
{ "from": "OSC.LeftEye", "to" : "Standard.LeftEye" },
|
||||
{ "from": "OSC.RightEye", "to" : "Standard.RightEye" },
|
||||
|
||||
{ "from": "OSC.EyeBlink_L", "to": "Standard.EyeBlink_L" },
|
||||
{ "from": "OSC.EyeBlink_R", "to": "Standard.EyeBlink_R" },
|
||||
{ "from": "OSC.EyeSquint_L", "to": "Standard.EyeSquint_L" },
|
||||
{ "from": "OSC.EyeSquint_R", "to": "Standard.EyeSquint_R" },
|
||||
{ "from": "OSC.EyeDown_L", "to": "Standard.EyeDown_L" },
|
||||
{ "from": "OSC.EyeDown_R", "to": "Standard.EyeDown_R" },
|
||||
{ "from": "OSC.EyeIn_L", "to": "Standard.EyeIn_L" },
|
||||
{ "from": "OSC.EyeIn_R", "to": "Standard.EyeIn_R" },
|
||||
{ "from": "OSC.EyeOpen_L", "to": "Standard.EyeOpen_L" },
|
||||
{ "from": "OSC.EyeOpen_R", "to": "Standard.EyeOpen_R" },
|
||||
{ "from": "OSC.EyeOut_L", "to": "Standard.EyeOut_L" },
|
||||
{ "from": "OSC.EyeOut_R", "to": "Standard.EyeOut_R" },
|
||||
{ "from": "OSC.EyeUp_L", "to": "Standard.EyeUp_L" },
|
||||
{ "from": "OSC.EyeUp_R", "to": "Standard.EyeUp_R" },
|
||||
{ "from": "OSC.BrowsD_L", "to": "Standard.BrowsD_L" },
|
||||
{ "from": "OSC.BrowsD_R", "to": "Standard.BrowsD_R" },
|
||||
{ "from": "OSC.BrowsU_C", "to": "Standard.BrowsU_C" },
|
||||
{ "from": "OSC.BrowsU_L", "to": "Standard.BrowsU_L" },
|
||||
{ "from": "OSC.BrowsU_R", "to": "Standard.BrowsU_R" },
|
||||
{ "from": "OSC.JawFwd", "to": "Standard.JawFwd" },
|
||||
{ "from": "OSC.JawLeft", "to": "Standard.JawLeft" },
|
||||
{ "from": "OSC.JawOpen", "to": "Standard.JawOpen" },
|
||||
{ "from": "OSC.JawRight", "to": "Standard.JawRight" },
|
||||
{ "from": "OSC.MouthLeft", "to": "Standard.MouthLeft" },
|
||||
{ "from": "OSC.MouthRight", "to": "Standard.MouthRight" },
|
||||
{ "from": "OSC.MouthFrown_L", "to": "Standard.MouthFrown_L" },
|
||||
{ "from": "OSC.MouthFrown_R", "to": "Standard.MouthFrown_R" },
|
||||
{ "from": "OSC.MouthSmile_L", "to": "Standard.MouthSmile_L" },
|
||||
{ "from": "OSC.MouthSmile_R", "to": "Standard.MouthSmile_R" },
|
||||
{ "from": "OSC.MouthDimple_L", "to": "Standard.MouthDimple_L" },
|
||||
{ "from": "OSC.MouthDimple_R", "to": "Standard.MouthDimple_R" },
|
||||
{ "from": "OSC.LipsStretch_L", "to": "Standard.LipsStretch_L" },
|
||||
{ "from": "OSC.LipsStretch_R", "to": "Standard.LipsStretch_R" },
|
||||
{ "from": "OSC.LipsUpperClose", "to": "Standard.LipsUpperClose" },
|
||||
{ "from": "OSC.LipsLowerClose", "to": "Standard.LipsLowerClose" },
|
||||
{ "from": "OSC.LipsFunnel", "to": "Standard.LipsFunnel" },
|
||||
{ "from": "OSC.LipsPucker", "to": "Standard.LipsPucker" },
|
||||
{ "from": "OSC.Puff", "to": "Standard.Puff" },
|
||||
{ "from": "OSC.CheekSquint_L", "to": "Standard.CheekSquint_L" },
|
||||
{ "from": "OSC.CheekSquint_R", "to": "Standard.CheekSquint_R" },
|
||||
{ "from": "OSC.MouthClose", "to": "Standard.MouthClose" },
|
||||
{ "from": "OSC.MouthUpperUp_L", "to": "Standard.MouthUpperUp_L" },
|
||||
{ "from": "OSC.MouthUpperUp_R", "to": "Standard.MouthUpperUp_R" },
|
||||
{ "from": "OSC.MouthLowerDown_L", "to": "Standard.MouthLowerDown_L" },
|
||||
{ "from": "OSC.MouthLowerDown_R", "to": "Standard.MouthLowerDown_R" },
|
||||
{ "from": "OSC.MouthPress_L", "to": "Standard.MouthPress_L" },
|
||||
{ "from": "OSC.MouthPress_R", "to": "Standard.MouthPress_R" },
|
||||
{ "from": "OSC.MouthShrugLower", "to": "Standard.MouthShrugLower" },
|
||||
{ "from": "OSC.MouthShrugUpper", "to": "Standard.MouthShrugUpper" },
|
||||
{ "from": "OSC.NoseSneer_L", "to": "Standard.NoseSneer_L" },
|
||||
{ "from": "OSC.NoseSneer_R", "to": "Standard.NoseSneer_R" },
|
||||
{ "from": "OSC.TongueOut", "to": "Standard.TongueOut" },
|
||||
{ "from": "OSC.UserBlendshape0", "to": "Standard.UserBlendshape0" },
|
||||
{ "from": "OSC.UserBlendshape1", "to": "Standard.UserBlendshape1" },
|
||||
{ "from": "OSC.UserBlendshape2", "to": "Standard.UserBlendshape2" },
|
||||
{ "from": "OSC.UserBlendshape3", "to": "Standard.UserBlendshape3" },
|
||||
{ "from": "OSC.UserBlendshape4", "to": "Standard.UserBlendshape4" },
|
||||
{ "from": "OSC.UserBlendshape5", "to": "Standard.UserBlendshape5" },
|
||||
{ "from": "OSC.UserBlendshape6", "to": "Standard.UserBlendshape6" },
|
||||
{ "from": "OSC.UserBlendshape7", "to": "Standard.UserBlendshape7" },
|
||||
{ "from": "OSC.UserBlendshape8", "to": "Standard.UserBlendshape8" },
|
||||
{ "from": "OSC.UserBlendshape9", "to": "Standard.UserBlendshape9" }
|
||||
]
|
||||
}
|
|
@ -52,7 +52,6 @@
|
|||
{ "from": "GamePad.DL", "to": "Standard.DL" },
|
||||
{ "from": "GamePad.DR", "to": "Standard.DR" },
|
||||
|
||||
{ "from": [ "GamePad.Y" ], "to": "Standard.RightPrimaryThumb", "peek": true },
|
||||
{ "from": "GamePad.A", "to": "Standard.A" },
|
||||
{ "from": "GamePad.B", "to": "Standard.B" },
|
||||
{ "from": "GamePad.X", "to": "Standard.X" },
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 20 KiB |
Binary file not shown.
Before Width: | Height: | Size: 125 KiB |
|
@ -201,7 +201,7 @@ Item {
|
|||
}
|
||||
StatText {
|
||||
visible: root.expanded;
|
||||
text: "Audio In Audio: " + root.audioAudioInboundPPS + " pps, " +
|
||||
text: "Audio In Audio: " + root.audioInboundPPS + " pps, " +
|
||||
"Silent: " + root.audioSilentInboundPPS + " pps";
|
||||
}
|
||||
StatText {
|
||||
|
|
|
@ -85,27 +85,31 @@ Item {
|
|||
UserActivityLogger.logAction("encourageLoginDialog", data);
|
||||
}
|
||||
bodyLoader.setSource("LoggingInBody.qml", { "loginDialog": loginDialog, "root": root, "bodyLoader": bodyLoader, "withSteam": linkAccountBody.withSteam,
|
||||
"withOculus": linkAccountBody.withOculus, "linkSteam": linkAccountBody.linkSteam, "linkOculus": linkAccountBody.linkOculus });
|
||||
"withOculus": linkAccountBody.withOculus, "linkSteam": linkAccountBody.linkSteam, "linkOculus": linkAccountBody.linkOculus,
|
||||
"displayName":displayNameField.text });
|
||||
}
|
||||
|
||||
function init() {
|
||||
// going to/from sign in/up dialog.
|
||||
loginErrorMessage.text = linkAccountBody.errorString;
|
||||
loginErrorMessage.visible = (linkAccountBody.errorString !== "");
|
||||
if (loginErrorMessageTextMetrics.width > emailField.width) {
|
||||
if (loginErrorMessageTextMetrics.width > displayNameField.width) {
|
||||
loginErrorMessage.wrapMode = Text.WordWrap;
|
||||
errorContainer.height = (loginErrorMessageTextMetrics.width / emailField.width) * loginErrorMessageTextMetrics.height;
|
||||
errorContainer.height = (loginErrorMessageTextMetrics.width / displayNameField.width) * loginErrorMessageTextMetrics.height;
|
||||
}
|
||||
loginButton.text = (!linkAccountBody.linkSteam && !linkAccountBody.linkOculus) ? "Log In" : "Link Account";
|
||||
loginButton.color = hifi.buttons.blue;
|
||||
displayNameField.placeholderText = "Display Name (optional)";
|
||||
var savedDisplayName = Settings.getValue("Avatar/displayName", "");
|
||||
displayNameField.text = savedDisplayName;
|
||||
emailField.placeholderText = "Username or Email";
|
||||
var savedUsername = Settings.getValue("keepMeLoggedIn/savedUsername", "");
|
||||
emailField.text = keepMeLoggedInCheckbox.checked ? savedUsername === "Unknown user" ? "" : savedUsername : "";
|
||||
if (linkAccountBody.linkSteam || linkAccountBody.linkOculus) {
|
||||
loginButton.width = (passwordField.width - hifi.dimensions.contentSpacing.x) / 2;
|
||||
loginButton.anchors.right = emailField.right;
|
||||
loginButton.anchors.right = displayNameField.right;
|
||||
} else {
|
||||
loginButton.anchors.left = emailField.left;
|
||||
loginButton.anchors.left = displayNameField.left;
|
||||
}
|
||||
loginContainer.visible = true;
|
||||
}
|
||||
|
@ -125,14 +129,14 @@ Item {
|
|||
|
||||
Item {
|
||||
id: loginContainer
|
||||
width: emailField.width
|
||||
height: errorContainer.height + emailField.height + passwordField.height + 5.5 * hifi.dimensions.contentSpacing.y +
|
||||
width: displayNameField.width
|
||||
height: errorContainer.height + displayNameField.height + emailField.height + passwordField.height + 5.5 * hifi.dimensions.contentSpacing.y +
|
||||
keepMeLoggedInCheckbox.height + loginButton.height + cantAccessTextMetrics.height + continueButton.height
|
||||
anchors {
|
||||
top: parent.top
|
||||
topMargin: root.bannerHeight + 0.25 * parent.height
|
||||
left: parent.left
|
||||
leftMargin: (parent.width - emailField.width) / 2
|
||||
leftMargin: (parent.width - displayNameField.width) / 2
|
||||
}
|
||||
|
||||
Item {
|
||||
|
@ -140,9 +144,9 @@ Item {
|
|||
width: parent.width
|
||||
height: loginErrorMessageTextMetrics.height
|
||||
anchors {
|
||||
bottom: emailField.top;
|
||||
bottom: displayNameField.top;
|
||||
bottomMargin: hifi.dimensions.contentSpacing.y;
|
||||
left: emailField.left;
|
||||
left: displayNameField.left;
|
||||
}
|
||||
TextMetrics {
|
||||
id: loginErrorMessageTextMetrics
|
||||
|
@ -163,7 +167,7 @@ Item {
|
|||
}
|
||||
|
||||
HifiControlsUit.TextField {
|
||||
id: emailField
|
||||
id: displayNameField
|
||||
width: root.bannerWidth
|
||||
height: linkAccountBody.textFieldHeight
|
||||
font.pixelSize: linkAccountBody.textFieldFontSize
|
||||
|
@ -172,6 +176,45 @@ Item {
|
|||
top: parent.top
|
||||
topMargin: errorContainer.height
|
||||
}
|
||||
placeholderText: "Display Name (optional)"
|
||||
activeFocusOnPress: true
|
||||
Keys.onPressed: {
|
||||
switch (event.key) {
|
||||
case Qt.Key_Tab:
|
||||
event.accepted = true;
|
||||
emailField.focus = true;
|
||||
break;
|
||||
case Qt.Key_Backtab:
|
||||
event.accepted = true;
|
||||
passwordField.focus = true;
|
||||
break;
|
||||
case Qt.Key_Enter:
|
||||
case Qt.Key_Return:
|
||||
event.accepted = true;
|
||||
if (keepMeLoggedInCheckbox.checked) {
|
||||
Settings.setValue("keepMeLoggedIn/savedUsername", emailField.text);
|
||||
}
|
||||
linkAccountBody.login();
|
||||
break;
|
||||
}
|
||||
}
|
||||
onFocusChanged: {
|
||||
root.text = "";
|
||||
if (focus) {
|
||||
root.isPassword = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
HifiControlsUit.TextField {
|
||||
id: emailField
|
||||
width: root.bannerWidth
|
||||
height: linkAccountBody.textFieldHeight
|
||||
font.pixelSize: linkAccountBody.textFieldFontSize
|
||||
styleRenderType: Text.QtRendering
|
||||
anchors {
|
||||
top: displayNameField.bottom
|
||||
topMargin: 1.5 * hifi.dimensions.contentSpacing.y
|
||||
}
|
||||
placeholderText: "Username or Email"
|
||||
activeFocusOnPress: true
|
||||
Keys.onPressed: {
|
||||
|
@ -182,7 +225,7 @@ Item {
|
|||
break;
|
||||
case Qt.Key_Backtab:
|
||||
event.accepted = true;
|
||||
passwordField.focus = true;
|
||||
displayNameField.focus = true;
|
||||
break;
|
||||
case Qt.Key_Enter:
|
||||
case Qt.Key_Return:
|
||||
|
@ -257,6 +300,9 @@ Item {
|
|||
Keys.onPressed: {
|
||||
switch (event.key) {
|
||||
case Qt.Key_Tab:
|
||||
event.accepted = true;
|
||||
displayNameField.focus = true;
|
||||
break;
|
||||
case Qt.Key_Backtab:
|
||||
event.accepted = true;
|
||||
emailField.focus = true;
|
||||
|
@ -350,7 +396,7 @@ Item {
|
|||
anchors {
|
||||
top: loginButton.bottom
|
||||
topMargin: hifi.dimensions.contentSpacing.y
|
||||
left: emailField.left
|
||||
left: displayNameField.left
|
||||
}
|
||||
font.family: linkAccountBody.fontFamily
|
||||
font.pixelSize: linkAccountBody.textFieldFontSize
|
||||
|
@ -381,13 +427,13 @@ Item {
|
|||
}
|
||||
HifiControlsUit.Button {
|
||||
id: continueButton;
|
||||
width: emailField.width;
|
||||
width: displayNameField.width;
|
||||
height: d.minHeightButton
|
||||
color: hifi.buttons.none;
|
||||
anchors {
|
||||
top: cantAccessText.bottom
|
||||
topMargin: hifi.dimensions.contentSpacing.y
|
||||
left: emailField.left
|
||||
left: displayNameField.left
|
||||
}
|
||||
text: qsTr("CONTINUE WITH STEAM")
|
||||
fontFamily: linkAccountBody.fontFamily
|
||||
|
@ -420,7 +466,8 @@ Item {
|
|||
}
|
||||
|
||||
bodyLoader.setSource("LoggingInBody.qml", { "loginDialog": loginDialog, "root": root, "bodyLoader": bodyLoader,
|
||||
"withSteam": linkAccountBody.withSteam, "withOculus": linkAccountBody.withOculus, "linkSteam": linkAccountBody.linkSteam, "linkOculus": linkAccountBody.linkOculus });
|
||||
"withSteam": linkAccountBody.withSteam, "withOculus": linkAccountBody.withOculus, "linkSteam": linkAccountBody.linkSteam, "linkOculus": linkAccountBody.linkOculus,
|
||||
"displayName":displayNameField.text});
|
||||
}
|
||||
Component.onCompleted: {
|
||||
if (linkAccountBody.linkSteam || linkAccountBody.linkOculus) {
|
||||
|
@ -535,7 +582,7 @@ Item {
|
|||
onFocusEnabled: {
|
||||
if (!linkAccountBody.lostFocus) {
|
||||
Qt.callLater(function() {
|
||||
emailField.forceActiveFocus();
|
||||
displayNameField.forceActiveFocus();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -543,6 +590,7 @@ Item {
|
|||
linkAccountBody.lostFocus = !root.isTablet && !root.isOverlay;
|
||||
if (linkAccountBody.lostFocus) {
|
||||
Qt.callLater(function() {
|
||||
displayNameField.focus = false;
|
||||
emailField.focus = false;
|
||||
passwordField.focus = false;
|
||||
});
|
||||
|
@ -558,7 +606,7 @@ Item {
|
|||
d.resize();
|
||||
init();
|
||||
Qt.callLater(function() {
|
||||
emailField.forceActiveFocus();
|
||||
displayNameField.forceActiveFocus();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -31,6 +31,7 @@ Item {
|
|||
property bool linkSteam: linkSteam
|
||||
property bool linkOculus: linkOculus
|
||||
property bool createOculus: createOculus
|
||||
property string displayName: ""
|
||||
|
||||
readonly property bool loginDialogPoppedUp: loginDialog.getLoginDialogPoppedUp()
|
||||
|
||||
|
@ -161,6 +162,7 @@ Item {
|
|||
}
|
||||
|
||||
}
|
||||
MyAvatar.displayName = displayName;
|
||||
successTimer.start();
|
||||
}
|
||||
|
||||
|
|
|
@ -238,7 +238,7 @@ Item {
|
|||
}
|
||||
StatText {
|
||||
visible: root.expanded;
|
||||
text: "Audio In Audio: " + root.audioAudioInboundPPS + " pps, " +
|
||||
text: "Audio In Audio: " + root.audioInboundPPS + " pps, " +
|
||||
"Silent: " + root.audioSilentInboundPPS + " pps";
|
||||
}
|
||||
StatText {
|
||||
|
|
|
@ -49,4 +49,6 @@ Item {
|
|||
Component.onCompleted: {
|
||||
load(root.url, root.scriptUrl);
|
||||
}
|
||||
|
||||
signal sendToScript(var message);
|
||||
}
|
||||
|
|
|
@ -777,9 +777,7 @@ Rectangle {
|
|||
hoverEnabled: true
|
||||
|
||||
onClicked: {
|
||||
popup.showBuyAvatars(function() {
|
||||
emitSendToScript({'method' : 'navigate', 'url' : 'hifi://BodyMart'})
|
||||
}, function(link) {
|
||||
popup.showBuyAvatars(null, function(link) {
|
||||
emitSendToScript({'method' : 'navigate', 'url' : link})
|
||||
});
|
||||
}
|
||||
|
|
|
@ -245,9 +245,7 @@ Rectangle {
|
|||
linkColor: hifi.colors.blueHighlight
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
onLinkActivated: {
|
||||
popup.showGetWearables(function() {
|
||||
emitSendToScript({'method' : 'navigate', 'url' : 'hifi://AvatarIsland/11.5848,-8.10862,-2.80195'})
|
||||
}, function(link) {
|
||||
popup.showGetWearables(null, function(link) {
|
||||
emitSendToScript({'method' : 'navigate', 'url' : link})
|
||||
});
|
||||
}
|
||||
|
|
|
@ -56,25 +56,12 @@ MessageBox {
|
|||
popup.inputText.forceActiveFocus();
|
||||
}
|
||||
|
||||
property url getWearablesUrl: '../../../images/avatarapp/AvatarIsland.jpg'
|
||||
|
||||
function showGetWearables(callback, linkCallback) {
|
||||
popup.button2text = 'AvatarIsland'
|
||||
popup.dialogButtons.yesButton.fontCapitalization = Font.MixedCase;
|
||||
popup.dialogButtons.yesButton.visible = false;
|
||||
popup.button1text = 'CANCEL'
|
||||
popup.titleText = 'Get Wearables'
|
||||
popup.bodyText = 'Get wearables from <b><a href="app://marketplace">Marketplace.</a></b>' + '<br/>' +
|
||||
'Wear wearable from <b><a href="app://purchases">Inventory.</a></b>' + '<br/>' + '<br/>' +
|
||||
'Visit “AvatarIsland” to get wearables'
|
||||
|
||||
popup.imageSource = getWearablesUrl;
|
||||
popup.onButton2Clicked = function() {
|
||||
popup.close();
|
||||
|
||||
if (callback) {
|
||||
callback();
|
||||
}
|
||||
}
|
||||
'Wear wearable from <b><a href="app://purchases">Inventory.</a></b>'
|
||||
|
||||
popup.onLinkClicked = function(link) {
|
||||
popup.close();
|
||||
|
@ -120,26 +107,13 @@ MessageBox {
|
|||
popup.open();
|
||||
}
|
||||
|
||||
property url getAvatarsUrl: '../../../images/avatarapp/BodyMart.PNG'
|
||||
|
||||
function showBuyAvatars(callback, linkCallback) {
|
||||
popup.button2text = 'BodyMart'
|
||||
popup.dialogButtons.yesButton.fontCapitalization = Font.MixedCase;
|
||||
popup.dialogButtons.yesButton.visible = false;
|
||||
popup.button1text = 'CANCEL'
|
||||
popup.titleText = 'Get Avatars'
|
||||
|
||||
popup.bodyText = 'Get avatars from <b><a href="app://marketplace">Marketplace.</a></b>' + '<br/>' +
|
||||
'Wear avatars in <b><a href="app://purchases">Inventory.</a></b>' + '<br/>' + '<br/>' +
|
||||
'Visit “BodyMart” to get free avatars.'
|
||||
|
||||
popup.imageSource = getAvatarsUrl;
|
||||
popup.onButton2Clicked = function() {
|
||||
popup.close();
|
||||
|
||||
if (callback) {
|
||||
callback();
|
||||
}
|
||||
}
|
||||
'Wear avatars in <b><a href="app://purchases">Inventory.</a></b>'
|
||||
|
||||
popup.onLinkClicked = function(link) {
|
||||
popup.close();
|
||||
|
|
|
@ -332,7 +332,7 @@ Item {
|
|||
anchors.fill: stackView
|
||||
id: controllerPrefereneces
|
||||
objectName: "TabletControllerPreferences"
|
||||
showCategories: ["VR Movement", "Game Controller", "Sixense Controllers", "Perception Neuron", "Leap Motion"]
|
||||
showCategories: ["VR Movement", "Game Controller", "Sixense Controllers", "Perception Neuron", "Leap Motion", "Open Sound Control (OSC)"]
|
||||
categoryProperties: {
|
||||
"VR Movement" : {
|
||||
"User real-world height (meters)" : { "anchors.right" : "undefined" },
|
||||
|
|
|
@ -185,6 +185,7 @@
|
|||
#include "scripting/AssetMappingsScriptingInterface.h"
|
||||
#include "scripting/ClipboardScriptingInterface.h"
|
||||
#include "scripting/DesktopScriptingInterface.h"
|
||||
#include "scripting/ScreenshareScriptingInterface.h"
|
||||
#include "scripting/AccountServicesScriptingInterface.h"
|
||||
#include "scripting/HMDScriptingInterface.h"
|
||||
#include "scripting/MenuScriptingInterface.h"
|
||||
|
@ -664,10 +665,17 @@ private:
|
|||
* </thead>
|
||||
* <tbody>
|
||||
* <tr><td><code>CameraFirstPerson</code></td><td>number</td><td>number</td><td>The camera is in first-person mode.
|
||||
* </td></tr>
|
||||
* <em>Legacy first person camera mode.</em></td></tr>
|
||||
* <tr><td><code>CameraFirstPersonLookAt</code></td><td>number</td><td>number</td><td>The camera is in first-person mode.
|
||||
* <em>Default first person camera mode.</em></td></tr>
|
||||
* <tr><td><code>CameraThirdPerson</code></td><td>number</td><td>number</td><td>The camera is in third-person mode.
|
||||
* </td></tr>
|
||||
* <tr><td><code>CameraFSM</code></td><td>number</td><td>number</td><td>The camera is in full screen mirror mode.</td></tr>
|
||||
* <em>Legacy third person camera mode.</em></td></tr>
|
||||
* <tr><td><code>CameraLookAt</code></td><td>number</td><td>number</td><td>The camera is in third-person mode.
|
||||
* <em>Default third person camera mode.</em></td></tr>
|
||||
* <tr><td><code>CameraFSM</code></td><td>number</td><td>number</td><td>The camera is in full screen mirror mode.
|
||||
* <em>Legacy "look at myself" behavior.</em></td></tr>
|
||||
* <tr><td><code>CameraSelfie</code></td><td>number</td><td>number</td><td>The camera is in selfie mode.
|
||||
* <em>Default "look at myself" camera mode.</em></td></tr>
|
||||
* <tr><td><code>CameraIndependent</code></td><td>number</td><td>number</td><td>The camera is in independent mode.</td></tr>
|
||||
* <tr><td><code>CameraEntity</code></td><td>number</td><td>number</td><td>The camera is in entity mode.</td></tr>
|
||||
* <tr><td><code>InHMD</code></td><td>number</td><td>number</td><td>The user is in HMD mode.</td></tr>
|
||||
|
@ -939,6 +947,7 @@ bool setupEssentials(int& argc, char** argv, bool runningMarkerExisted) {
|
|||
DependencyManager::set<KeyboardScriptingInterface>();
|
||||
DependencyManager::set<GrabManager>();
|
||||
DependencyManager::set<AvatarPackager>();
|
||||
DependencyManager::set<ScreenshareScriptingInterface>();
|
||||
PlatformHelper::setup();
|
||||
|
||||
QObject::connect(PlatformHelper::instance(), &PlatformHelper::systemWillWake, [] {
|
||||
|
@ -2908,6 +2917,7 @@ Application::~Application() {
|
|||
DependencyManager::destroy<SoundCache>();
|
||||
DependencyManager::destroy<OctreeStatsProvider>();
|
||||
DependencyManager::destroy<GeometryCache>();
|
||||
DependencyManager::destroy<ScreenshareScriptingInterface>();
|
||||
|
||||
DependencyManager::get<ResourceManager>()->cleanup();
|
||||
|
||||
|
@ -3401,6 +3411,10 @@ void Application::initializeUi() {
|
|||
|
||||
|
||||
setIsInterstitialMode(true);
|
||||
|
||||
#if defined(DISABLE_QML) && defined(Q_OS_LINUX)
|
||||
resumeAfterLoginDialogActionTaken();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
@ -3439,7 +3453,7 @@ void Application::onDesktopRootContextCreated(QQmlContext* surfaceContext) {
|
|||
surfaceContext->setContextProperty("Users", DependencyManager::get<UsersScriptingInterface>().data());
|
||||
|
||||
surfaceContext->setContextProperty("UserActivityLogger", DependencyManager::get<UserActivityLoggerScriptingInterface>().data());
|
||||
|
||||
surfaceContext->setContextProperty("Screenshare", DependencyManager::get<ScreenshareScriptingInterface>().data());
|
||||
surfaceContext->setContextProperty("Camera", &_myCamera);
|
||||
|
||||
#if defined(Q_OS_MAC) || defined(Q_OS_WIN)
|
||||
|
@ -3545,6 +3559,7 @@ void Application::userKickConfirmation(const QUuid& nodeID) {
|
|||
}
|
||||
|
||||
void Application::setupQmlSurface(QQmlContext* surfaceContext, bool setAdditionalContextProperties) {
|
||||
surfaceContext->setContextProperty("Screenshare", DependencyManager::get<ScreenshareScriptingInterface>().data());
|
||||
surfaceContext->setContextProperty("Users", DependencyManager::get<UsersScriptingInterface>().data());
|
||||
surfaceContext->setContextProperty("HMD", DependencyManager::get<HMDScriptingInterface>().data());
|
||||
surfaceContext->setContextProperty("UserActivityLogger", DependencyManager::get<UserActivityLoggerScriptingInterface>().data());
|
||||
|
@ -4880,6 +4895,9 @@ void Application::touchEndEvent(QTouchEvent* event) {
|
|||
}
|
||||
|
||||
void Application::touchGestureEvent(QGestureEvent* event) {
|
||||
if (_keyboardMouseDevice->isActive()) {
|
||||
_keyboardMouseDevice->touchGestureEvent(event);
|
||||
}
|
||||
if (_touchscreenDevice && _touchscreenDevice->isActive()) {
|
||||
_touchscreenDevice->touchGestureEvent(event);
|
||||
}
|
||||
|
@ -5670,6 +5688,7 @@ void Application::resumeAfterLoginDialogActionTaken() {
|
|||
return;
|
||||
}
|
||||
|
||||
#if !defined(DISABLE_QML)
|
||||
if (!isHMDMode() && getDesktopTabletBecomesToolbarSetting()) {
|
||||
auto toolbar = DependencyManager::get<ToolbarScriptingInterface>()->getToolbar("com.highfidelity.interface.toolbar.system");
|
||||
toolbar->writeProperty("visible", true);
|
||||
|
@ -5679,6 +5698,7 @@ void Application::resumeAfterLoginDialogActionTaken() {
|
|||
}
|
||||
|
||||
updateSystemTabletMode();
|
||||
#endif
|
||||
|
||||
{
|
||||
auto userInputMapper = DependencyManager::get<UserInputMapper>();
|
||||
|
@ -5829,12 +5849,7 @@ void Application::centerUI() {
|
|||
|
||||
void Application::cycleCamera() {
|
||||
auto menu = Menu::getInstance();
|
||||
if (menu->isOptionChecked(MenuOption::FullscreenMirror)) {
|
||||
|
||||
menu->setIsOptionChecked(MenuOption::FullscreenMirror, false);
|
||||
menu->setIsOptionChecked(MenuOption::FirstPersonLookAt, true);
|
||||
|
||||
} else if (menu->isOptionChecked(MenuOption::FirstPersonLookAt)) {
|
||||
if (menu->isOptionChecked(MenuOption::FirstPersonLookAt)) {
|
||||
|
||||
menu->setIsOptionChecked(MenuOption::FirstPersonLookAt, false);
|
||||
menu->setIsOptionChecked(MenuOption::LookAtCamera, true);
|
||||
|
@ -5842,12 +5857,16 @@ void Application::cycleCamera() {
|
|||
} else if (menu->isOptionChecked(MenuOption::LookAtCamera)) {
|
||||
|
||||
menu->setIsOptionChecked(MenuOption::LookAtCamera, false);
|
||||
if (menu->getActionForOption(MenuOption::SelfieCamera)->isVisible()) {
|
||||
menu->setIsOptionChecked(MenuOption::SelfieCamera, true);
|
||||
} else {
|
||||
menu->setIsOptionChecked(MenuOption::FirstPersonLookAt, true);
|
||||
}
|
||||
|
||||
} else if (menu->isOptionChecked(MenuOption::SelfieCamera)) {
|
||||
|
||||
menu->setIsOptionChecked(MenuOption::SelfieCamera, false);
|
||||
menu->setIsOptionChecked(MenuOption::FullscreenMirror, true);
|
||||
menu->setIsOptionChecked(MenuOption::FirstPersonLookAt, true);
|
||||
|
||||
}
|
||||
cameraMenuChanged(); // handle the menu change
|
||||
|
@ -6273,7 +6292,7 @@ void Application::update(float deltaTime) {
|
|||
myAvatar->setDriveKey(MyAvatar::TRANSLATE_Z, -1.0f * userInputMapper->getActionState(controller::Action::TRANSLATE_Z));
|
||||
myAvatar->setDriveKey(MyAvatar::TRANSLATE_Y, userInputMapper->getActionState(controller::Action::TRANSLATE_Y));
|
||||
myAvatar->setDriveKey(MyAvatar::TRANSLATE_X, userInputMapper->getActionState(controller::Action::TRANSLATE_X));
|
||||
if (deltaTime > FLT_EPSILON) {
|
||||
if (deltaTime > FLT_EPSILON && userInputMapper->getActionState(controller::Action::TRANSLATE_CAMERA_Z) == 0.0f) {
|
||||
myAvatar->setDriveKey(MyAvatar::PITCH, -1.0f * userInputMapper->getActionState(controller::Action::PITCH));
|
||||
myAvatar->setDriveKey(MyAvatar::YAW, -1.0f * userInputMapper->getActionState(controller::Action::YAW));
|
||||
myAvatar->setDriveKey(MyAvatar::DELTA_PITCH, -1.0f * userInputMapper->getActionState(controller::Action::DELTA_PITCH));
|
||||
|
@ -7329,6 +7348,7 @@ void Application::registerScriptEngineWithApplicationServices(const ScriptEngine
|
|||
scriptEngine->registerGlobalObject("AvatarList", DependencyManager::get<AvatarManager>().data());
|
||||
|
||||
scriptEngine->registerGlobalObject("Camera", &_myCamera);
|
||||
scriptEngine->registerGlobalObject("Screenshare", DependencyManager::get<ScreenshareScriptingInterface>().data());
|
||||
|
||||
#if defined(Q_OS_MAC) || defined(Q_OS_WIN)
|
||||
scriptEngine->registerGlobalObject("SpeechRecognizer", DependencyManager::get<SpeechRecognizer>().data());
|
||||
|
|
|
@ -154,7 +154,7 @@ void AvatarBookmarks::deleteBookmark() {
|
|||
|
||||
void AvatarBookmarks::updateAvatarEntities(const QVariantList &avatarEntities) {
|
||||
auto myAvatar = DependencyManager::get<AvatarManager>()->getMyAvatar();
|
||||
auto currentAvatarEntities = myAvatar->getAvatarEntityData();
|
||||
auto currentAvatarEntities = myAvatar->getAvatarEntityDataNonDefault();
|
||||
std::set<QUuid> newAvatarEntities;
|
||||
|
||||
// Update or add all the new avatar entities
|
||||
|
@ -187,7 +187,7 @@ void AvatarBookmarks::updateAvatarEntities(const QVariantList &avatarEntities) {
|
|||
* @property {number} avatarScale - The target scale of the avatar.
|
||||
* @property {Array<Object<"properties",Entities.EntityProperties>>} [avatarEntites] - The avatar entities included with the
|
||||
* bookmark.
|
||||
* @property {MyAvatar.AttachmentData[]} [attachments] - The attachments included with the bookmark.
|
||||
* @property {AttachmentData[]} [attachments] - The attachments included with the bookmark.
|
||||
* <p class="important">Deprecated: Use avatar entities instead.
|
||||
*/
|
||||
|
||||
|
@ -296,7 +296,7 @@ QVariantMap AvatarBookmarks::getAvatarDataToBookmark() {
|
|||
|
||||
if (entityTree) {
|
||||
QScriptEngine scriptEngine;
|
||||
auto avatarEntities = myAvatar->getAvatarEntityData();
|
||||
auto avatarEntities = myAvatar->getAvatarEntityDataNonDefault();
|
||||
for (auto entityID : avatarEntities.keys()) {
|
||||
auto entity = entityTree->findEntityByID(entityID);
|
||||
if (!entity || !isWearableEntity(entity)) {
|
||||
|
|
|
@ -45,10 +45,6 @@ SpatiallyNestableWeakPointer InterfaceParentFinder::find(QUuid parentID, bool& s
|
|||
success = true;
|
||||
return parent;
|
||||
}
|
||||
if (parentID == AVATAR_SELF_ID) {
|
||||
success = true;
|
||||
return avatarManager->getMyAvatar();
|
||||
}
|
||||
|
||||
success = false;
|
||||
return parent;
|
||||
|
|
|
@ -66,16 +66,62 @@ class AABox;
|
|||
|
||||
|
||||
/**jsdoc
|
||||
* The LOD class manages your Level of Detail functions within Interface.
|
||||
* The <code>LODManager</code> API manages the Level of Detail displayed in Interface. If the LOD is being automatically
|
||||
* adjusted, the LOD is decreased if the measured frame rate is lower than the target FPS, and increased if the measured frame
|
||||
* rate is greater than the target FPS.
|
||||
*
|
||||
* @namespace LODManager
|
||||
*
|
||||
* @hifi-interface
|
||||
* @hifi-client-entity
|
||||
* @hifi-avatar
|
||||
*
|
||||
* @property {number} presentTime <em>Read-only.</em>
|
||||
* @property {number} engineRunTime <em>Read-only.</em>
|
||||
* @property {number} gpuTime <em>Read-only.</em>
|
||||
* @property {LODManager.WorldDetailQuality} worldDetailQuality - The quality of the rendered world detail.
|
||||
* <p>Setting this value updates the current desktop or HMD target LOD FPS.</p>
|
||||
* @property {number} lodQualityLevel - <em>Not used.</em>
|
||||
* <p class="important">Deprecated: This property is deprecated and will be removed.</p>
|
||||
* @property {boolean} automaticLODAdjust - <code>true</code> to automatically adjust the LOD, <code>false</code> to manually
|
||||
* adjust it.
|
||||
*
|
||||
* @property {number} engineRunTime - The time spent in the "render" thread to produce the most recent frame, in ms.
|
||||
* <em>Read-only.</em>
|
||||
* @property {number} batchTime - The time spent in the "present" thread processing the batches of the most recent frame, in ms.
|
||||
* <em>Read-only.</em>
|
||||
* @property {number} presentTime - The time spent in the "present" thread between the last buffer swap, i.e., the total time
|
||||
* to submit the most recent frame, in ms.
|
||||
* <em>Read-only.</em>
|
||||
* @property {number} gpuTime - The time spent in the GPU executing the most recent frame, in ms.
|
||||
* <em>Read-only.</em>
|
||||
*
|
||||
* @property {number} nowRenderTime - The current, instantaneous time spend to produce frames, in ms. This is the worst of
|
||||
* <code>engineRunTime</code>, <code>batchTime</code>, <code>presentTime</code>, and <code>gpuTime</code>.
|
||||
* <em>Read-only.</em>
|
||||
* @property {number} nowRenderFPS - The current, instantaneous frame rate, in Hz.
|
||||
* <em>Read-only.</em>
|
||||
*
|
||||
* @property {number} smoothScale - The amount of smoothing applied to calculate <code>smoothRenderTime</code> and
|
||||
* <code>smoothRenderFPS</code>.
|
||||
* @property {number} smoothRenderTime - The average time spend to produce frames, in ms.
|
||||
* <em>Read-only.</em>
|
||||
* @property {number} smoothRenderFPS - The average frame rate, in Hz.
|
||||
* <em>Read-only.</em>
|
||||
*
|
||||
* @property {number} lodTargetFPS - The target LOD FPS per the current desktop or HMD display mode, capped by the target
|
||||
* refresh rate set by the {@link Performance} API.
|
||||
* <em>Read-only.</em>
|
||||
|
||||
* @property {number} lodAngleDeg - The minimum angular dimension (relative to the camera position) of an entity in order for
|
||||
* it to be rendered, in degrees. The angular dimension is calculated as a sphere of radius half the diagonal of the
|
||||
* entity's AA box.
|
||||
*
|
||||
* @property {number} pidKp - <em>Not used.</em>
|
||||
* @property {number} pidKi - <em>Not used.</em>
|
||||
* @property {number} pidKd - <em>Not used.</em>
|
||||
* @property {number} pidKv - <em>Not used.</em>
|
||||
* @property {number} pidOp - <em>Not used.</em> <em>Read-only.</em>
|
||||
* @property {number} pidOi - <em>Not used.</em> <em>Read-only.</em>
|
||||
* @property {number} pidOd - <em>Not used.</em> <em>Read-only.</em>
|
||||
* @property {number} pidO - <em>Not used.</em> <em>Read-only.</em>
|
||||
*/
|
||||
class LODManager : public QObject, public Dependency {
|
||||
Q_OBJECT
|
||||
|
@ -117,82 +163,95 @@ class LODManager : public QObject, public Dependency {
|
|||
public:
|
||||
|
||||
/**jsdoc
|
||||
* Sets whether the LOD should be automatically adjusted.
|
||||
* @function LODManager.setAutomaticLODAdjust
|
||||
* @param {boolean} value
|
||||
* @param {boolean} value - <code>true</code> to automatically adjust the LOD, <code>false</code> to manually adjust it.
|
||||
*/
|
||||
Q_INVOKABLE void setAutomaticLODAdjust(bool value);
|
||||
|
||||
/**jsdoc
|
||||
* Gets whether the LOD is being automatically adjusted.
|
||||
* @function LODManager.getAutomaticLODAdjust
|
||||
* @returns {boolean}
|
||||
* @returns {boolean} <code>true</code> if the LOD is being automatically adjusted, <code>false</code> if it is being
|
||||
* manually adjusted.
|
||||
*/
|
||||
Q_INVOKABLE bool getAutomaticLODAdjust() const { return _automaticLODAdjust; }
|
||||
|
||||
/**jsdoc
|
||||
* Sets the target desktop LOD FPS.
|
||||
* @function LODManager.setDesktopLODTargetFPS
|
||||
* @param {number} value
|
||||
* @param {number} value - The target desktop LOD FPS, in Hz.
|
||||
*/
|
||||
Q_INVOKABLE void setDesktopLODTargetFPS(float value);
|
||||
|
||||
/**jsdoc
|
||||
* Gets the target desktop LOD FPS.
|
||||
* @function LODManager.getDesktopLODTargetFPS
|
||||
* @returns {number}
|
||||
* @returns {number} The target desktop LOD FPS, in Hz.
|
||||
*/
|
||||
|
||||
Q_INVOKABLE float getDesktopLODTargetFPS() const;
|
||||
|
||||
/**jsdoc
|
||||
* Sets the target HMD LOD FPS.
|
||||
* @function LODManager.setHMDLODTargetFPS
|
||||
* @param {number} value
|
||||
* @param {number} value - The target HMD LOD FPS, in Hz.
|
||||
*/
|
||||
|
||||
Q_INVOKABLE void setHMDLODTargetFPS(float value);
|
||||
|
||||
/**jsdoc
|
||||
* Gets the target HMD LOD FPS.
|
||||
* The target FPS in HMD mode. The LOD is adjusted to ...
|
||||
* @function LODManager.getHMDLODTargetFPS
|
||||
* @returns {number}
|
||||
* @returns {number} The target HMD LOD FPS, in Hz.
|
||||
*/
|
||||
Q_INVOKABLE float getHMDLODTargetFPS() const;
|
||||
|
||||
|
||||
// User Tweakable LOD Items
|
||||
|
||||
/**jsdoc
|
||||
* Gets a text description of the current level of detail rendered.
|
||||
* @function LODManager.getLODFeedbackText
|
||||
* @returns {string}
|
||||
* @returns {string} A text description of the current level of detail rendered.
|
||||
* @example <caption>Report the current level of detail rendered.</caption>
|
||||
* print("You can currently see: " + LODManager.getLODFeedbackText());
|
||||
*/
|
||||
Q_INVOKABLE QString getLODFeedbackText();
|
||||
|
||||
/**jsdoc
|
||||
* @function LODManager.setOctreeSizeScale
|
||||
* @param {number} sizeScale
|
||||
* @deprecated This function is deprecated and will be removed. Use the {@link LODManager.lodAngleDeg} property instead.
|
||||
* @param {number} sizeScale - The octree size scale.
|
||||
* @deprecated This function is deprecated and will be removed. Use the <code>lodAngleDeg</code> property instead.
|
||||
*/
|
||||
Q_INVOKABLE void setOctreeSizeScale(float sizeScale);
|
||||
|
||||
/**jsdoc
|
||||
* @function LODManager.getOctreeSizeScale
|
||||
* @returns {number}
|
||||
* @deprecated This function is deprecated and will be removed. Use the {@link LODManager.lodAngleDeg} property instead.
|
||||
* @returns {number} The octree size scale.
|
||||
* @deprecated This function is deprecated and will be removed. Use the <code>lodAngleDeg</code> property instead.
|
||||
*/
|
||||
Q_INVOKABLE float getOctreeSizeScale() const;
|
||||
|
||||
/**jsdoc
|
||||
* @function LODManager.setBoundaryLevelAdjust
|
||||
* @param {number} boundaryLevelAdjust
|
||||
* @param {number} boundaryLevelAdjust - The boundary level adjust factor.
|
||||
* @deprecated This function is deprecated and will be removed.
|
||||
*/
|
||||
Q_INVOKABLE void setBoundaryLevelAdjust(int boundaryLevelAdjust);
|
||||
|
||||
/**jsdoc
|
||||
* @function LODManager.getBoundaryLevelAdjust
|
||||
* @returns {number}
|
||||
* @returns {number} The boundary level adjust factor.
|
||||
* @deprecated This function is deprecated and will be removed.
|
||||
*/
|
||||
Q_INVOKABLE int getBoundaryLevelAdjust() const { return _boundaryLevelAdjust; }
|
||||
|
||||
/**jsdoc
|
||||
* The target LOD FPS per the current desktop or HMD display mode, capped by the target refresh rate.
|
||||
* @function LODManager.getLODTargetFPS
|
||||
* @returns {number}
|
||||
* @returns {number} The target LOD FPS, in Hz.
|
||||
*/
|
||||
Q_INVOKABLE float getLODTargetFPS() const;
|
||||
|
||||
|
@ -249,19 +308,41 @@ public:
|
|||
signals:
|
||||
|
||||
/**jsdoc
|
||||
* <em>Not triggered.</em>
|
||||
* @function LODManager.LODIncreased
|
||||
* @returns {Signal}
|
||||
* @deprecated This signal is deprecated and will be removed.
|
||||
*/
|
||||
void LODIncreased();
|
||||
|
||||
/**jsdoc
|
||||
* <em>Not triggered.</em>
|
||||
* @function LODManager.LODDecreased
|
||||
* @returns {Signal}
|
||||
* @deprecated This signal is deprecated and will be removed.
|
||||
*/
|
||||
void LODDecreased();
|
||||
|
||||
/**jsdoc
|
||||
* Triggered when whether or not the LOD is being automatically adjusted changes.
|
||||
* @function LODManager.autoLODChanged
|
||||
* @returns {Signal}
|
||||
*/
|
||||
void autoLODChanged();
|
||||
|
||||
/**jsdoc
|
||||
* Triggered when the <code>lodQualityLevel</code> property value changes.
|
||||
* @function LODManager.lodQualityLevelChanged
|
||||
* @returns {Signal}
|
||||
* @deprecated This signal is deprecated and will be removed.
|
||||
*/
|
||||
void lodQualityLevelChanged();
|
||||
|
||||
/**jsdoc
|
||||
* Triggered when the world detail quality changes.
|
||||
* @function LODManager.worldDetailQualityChanged
|
||||
* @returns {Signal}
|
||||
*/
|
||||
void worldDetailQualityChanged();
|
||||
|
||||
private:
|
||||
|
|
|
@ -29,6 +29,8 @@
|
|||
#include <VrMenu.h>
|
||||
#include <ScriptEngines.h>
|
||||
#include <MenuItemProperties.h>
|
||||
#include <ui/types/FileTypeProfile.h>
|
||||
#include <ui/types/HFWebEngineProfile.h>
|
||||
|
||||
#include "Application.h"
|
||||
#include "AccountManager.h"
|
||||
|
@ -595,8 +597,20 @@ Menu::Menu() {
|
|||
QString("hifi/tablet/TabletNetworkingPreferences.qml"), "NetworkingPreferencesDialog");
|
||||
});
|
||||
addActionToQMenuAndActionHash(networkMenu, MenuOption::ReloadContent, 0, qApp, SLOT(reloadResourceCaches()));
|
||||
addActionToQMenuAndActionHash(networkMenu, MenuOption::ClearDiskCache, 0,
|
||||
DependencyManager::get<AssetClient>().data(), SLOT(clearCache()));
|
||||
|
||||
action = addActionToQMenuAndActionHash(networkMenu, MenuOption::ClearDiskCaches);
|
||||
connect(action, &QAction::triggered, [] {
|
||||
// The following caches are cleared immediately
|
||||
DependencyManager::get<AssetClient>()->clearCache();
|
||||
#ifndef Q_OS_ANDROID
|
||||
FileTypeProfile::clearCache();
|
||||
HFWebEngineProfile::clearCache();
|
||||
#endif
|
||||
|
||||
// Clear the KTX cache on the next restart. It can't be cleared immediately because its files might be in use.
|
||||
Setting::Handle<int>(KTXCache::SETTING_VERSION_NAME, KTXCache::INVALID_VERSION).set(KTXCache::INVALID_VERSION);
|
||||
});
|
||||
|
||||
addCheckableActionToQMenuAndActionHash(networkMenu,
|
||||
MenuOption::DisableActivityLogger,
|
||||
0,
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue