From be68d99bedba857159262cc2e27c47a7f9e1796f Mon Sep 17 00:00:00 2001 From: Mike Moody Date: Thu, 6 Jul 2017 23:17:23 -0700 Subject: [PATCH 01/30] added ability to drag ParticleEffects and Light Entities around via Overlay Icon. --- scripts/system/edit.js | 10 ++++++++-- .../libraries/entityIconOverlayManager.js | 17 +++++++++++++++++ 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/scripts/system/edit.js b/scripts/system/edit.js index a83d2159bb..11ab4771b9 100644 --- a/scripts/system/edit.js +++ b/scripts/system/edit.js @@ -648,7 +648,10 @@ var toolBar = (function () { // everybody else to think that Interface has lost focus overall. fogbugzid:558 // Window.setFocus(); } - entityIconOverlayManager.setVisible(isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); + var activeLightParticle = (isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); + entityIconOverlayManager.setVisible(activeLightParticle); + entityIconOverlayManager.setIconsSelectable(activeLightParticle); + Entities.setDrawZoneBoundaries(isActive && Menu.isOptionChecked(MENU_SHOW_ZONES_IN_EDIT_MODE)); }; @@ -1464,7 +1467,10 @@ function handeMenuEvent(menuItem) { } else if (menuItem === "Select All Entities Touching Box") { selectAllEtitiesInCurrentSelectionBox(true); } else if (menuItem === MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE) { - entityIconOverlayManager.setVisible(isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); + var activeLightParticle = (isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); + entityIconOverlayManager.setVisible(activeLightParticle); + entityIconOverlayManager.setIconsSelectable(activeLightParticle); + } else if (menuItem === MENU_SHOW_ZONES_IN_EDIT_MODE) { Entities.setDrawZoneBoundaries(isActive && Menu.isOptionChecked(MENU_SHOW_ZONES_IN_EDIT_MODE)); } diff --git a/scripts/system/libraries/entityIconOverlayManager.js b/scripts/system/libraries/entityIconOverlayManager.js index f557a05f60..65a98df90d 100644 --- a/scripts/system/libraries/entityIconOverlayManager.js +++ b/scripts/system/libraries/entityIconOverlayManager.js @@ -2,6 +2,7 @@ EntityIconOverlayManager = function(entityTypes, getOverlayPropertiesFunc) { var visible = false; + var iconsSelectable = false; // List of all created overlays var allOverlays = []; @@ -69,6 +70,18 @@ EntityIconOverlayManager = function(entityTypes, getOverlayPropertiesFunc) { } }; + + this.setIconsSelectable = function(isIconsSelectable) { + if (iconsSelectable !== isIconsSelectable) { + iconsSelectable = isIconsSelectable; + for (var id in entityOverlays) { + Overlays.editOverlay(entityOverlays[id], { + ignoreRayIntersection: iconsSelectable + }); + } + } + }; + // Allocate or get an unused overlay function getOverlay() { var overlay; @@ -114,6 +127,10 @@ EntityIconOverlayManager = function(entityTypes, getOverlayPropertiesFunc) { overlayProperties[key] = customProperties[key]; } } + + if(properties.type === 'ParticleEffect' || properties.type === 'Light'){ + overlayProperties.ignoreRayIntersection = true; + } Overlays.editOverlay(overlay, overlayProperties); } } From d9706452ac4c781a87cc1cf261c1fa27ef2b0924 Mon Sep 17 00:00:00 2001 From: Mike Moody Date: Thu, 6 Jul 2017 23:32:22 -0700 Subject: [PATCH 02/30] added ability to drag ParticleEffects and Light Entities around via Overlay Icon. --- scripts/system/libraries/entityIconOverlayManager.js | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/system/libraries/entityIconOverlayManager.js b/scripts/system/libraries/entityIconOverlayManager.js index 65a98df90d..1953b02d94 100644 --- a/scripts/system/libraries/entityIconOverlayManager.js +++ b/scripts/system/libraries/entityIconOverlayManager.js @@ -127,7 +127,6 @@ EntityIconOverlayManager = function(entityTypes, getOverlayPropertiesFunc) { overlayProperties[key] = customProperties[key]; } } - if(properties.type === 'ParticleEffect' || properties.type === 'Light'){ overlayProperties.ignoreRayIntersection = true; } From 53f581c3d418a246809e019668361dc7a4601bc9 Mon Sep 17 00:00:00 2001 From: Mike Moody Date: Sat, 8 Jul 2017 02:52:27 -0700 Subject: [PATCH 03/30] Fixed Icons not being selectable while not highlighted. --- scripts/system/edit.js | 14 ++++++------- .../libraries/entityIconOverlayManager.js | 21 ++++++++++++++----- 2 files changed, 22 insertions(+), 13 deletions(-) diff --git a/scripts/system/edit.js b/scripts/system/edit.js index 11ab4771b9..e9afc3a167 100644 --- a/scripts/system/edit.js +++ b/scripts/system/edit.js @@ -644,14 +644,12 @@ var toolBar = (function () { selectionDisplay.triggerMapping.enable(); print("starting tablet in landscape mode") tablet.landscape = true; + entityIconOverlayManager.setIconsSelectable(null,false); // Not sure what the following was meant to accomplish, but it currently causes // everybody else to think that Interface has lost focus overall. fogbugzid:558 // Window.setFocus(); } - var activeLightParticle = (isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); - entityIconOverlayManager.setVisible(activeLightParticle); - entityIconOverlayManager.setIconsSelectable(activeLightParticle); - + entityIconOverlayManager.setVisible(isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); Entities.setDrawZoneBoundaries(isActive && Menu.isOptionChecked(MENU_SHOW_ZONES_IN_EDIT_MODE)); }; @@ -944,6 +942,9 @@ function mouseClickEvent(event) { } else { selectionManager.addEntity(foundEntity, true); } + + entityIconOverlayManager.setIconsSelectable(selectionManager.selections,true); + if (wantDebug) { print("Model selected: " + foundEntity); } @@ -1467,10 +1468,7 @@ function handeMenuEvent(menuItem) { } else if (menuItem === "Select All Entities Touching Box") { selectAllEtitiesInCurrentSelectionBox(true); } else if (menuItem === MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE) { - var activeLightParticle = (isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); - entityIconOverlayManager.setVisible(activeLightParticle); - entityIconOverlayManager.setIconsSelectable(activeLightParticle); - + entityIconOverlayManager.setVisible(isActive && Menu.isOptionChecked(MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE)); } else if (menuItem === MENU_SHOW_ZONES_IN_EDIT_MODE) { Entities.setDrawZoneBoundaries(isActive && Menu.isOptionChecked(MENU_SHOW_ZONES_IN_EDIT_MODE)); } diff --git a/scripts/system/libraries/entityIconOverlayManager.js b/scripts/system/libraries/entityIconOverlayManager.js index 1953b02d94..a374783b1f 100644 --- a/scripts/system/libraries/entityIconOverlayManager.js +++ b/scripts/system/libraries/entityIconOverlayManager.js @@ -1,8 +1,8 @@ /* globals EntityIconOverlayManager:true */ EntityIconOverlayManager = function(entityTypes, getOverlayPropertiesFunc) { + var visible = false; - var iconsSelectable = false; // List of all created overlays var allOverlays = []; @@ -71,14 +71,25 @@ EntityIconOverlayManager = function(entityTypes, getOverlayPropertiesFunc) { }; - this.setIconsSelectable = function(isIconsSelectable) { - if (iconsSelectable !== isIconsSelectable) { - iconsSelectable = isIconsSelectable; + this.setIconsSelectable = function(arrayOfSelectedEntityIDs, isIconsSelectable) { + if (arrayOfSelectedEntityIDs === null) { for (var id in entityOverlays) { Overlays.editOverlay(entityOverlays[id], { - ignoreRayIntersection: iconsSelectable + ignoreRayIntersection: isIconsSelectable }); } + } else { + for (var id in entityOverlays) { + if (arrayOfSelectedEntityIDs.indexOf(id) !== -1) { // in the entityOverlays array and selectable + Overlays.editOverlay(entityOverlays[id], { + ignoreRayIntersection: isIconsSelectable + }); + } else { + Overlays.editOverlay(entityOverlays[id], { + ignoreRayIntersection: !isIconsSelectable + }); + } + } } }; From 1d333a24c17db824386f6b438294809eeab920f2 Mon Sep 17 00:00:00 2001 From: 1P-Cusack <1p-cusack@1stplayable.com> Date: Mon, 10 Jul 2017 11:51:42 -0400 Subject: [PATCH 04/30] Add point and thumb up gestures to the vive. When the thumb is off the touchpad, trigger the 'thumb up' animation. When on the thumbpad an 75% forward, trigger the 'index point animation'. WL 21362 --- interface/resources/controllers/vive.json | 6 +++++- plugins/openvr/src/ViveControllerManager.cpp | 19 ++++++++++++++++--- 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/interface/resources/controllers/vive.json b/interface/resources/controllers/vive.json index a0e9bd30d4..7795667125 100644 --- a/interface/resources/controllers/vive.json +++ b/interface/resources/controllers/vive.json @@ -64,6 +64,10 @@ { "from": "Vive.Head", "to" : "Standard.Head", "when": [ "Application.InHMD" ] }, { "from": "Vive.RightArm", "to" : "Standard.RightArm", "when": [ "Application.InHMD" ] }, - { "from": "Vive.LeftArm", "to" : "Standard.LeftArm", "when": [ "Application.InHMD" ] } + { "from": "Vive.LeftArm", "to" : "Standard.LeftArm", "when": [ "Application.InHMD" ] }, + { "from": "Vive.LeftThumbUp", "to": "Standard.LeftThumbUp" }, + { "from": "Vive.RightThumbUp", "to": "Standard.RightThumbUp" }, + { "from": "Vive.LeftIndexPoint", "to": "Standard.LeftIndexPoint" }, + { "from": "Vive.RightIndexPoint", "to": "Standard.RightIndexPoint" } ] } diff --git a/plugins/openvr/src/ViveControllerManager.cpp b/plugins/openvr/src/ViveControllerManager.cpp index d914cdcfad..24d49289dd 100644 --- a/plugins/openvr/src/ViveControllerManager.cpp +++ b/plugins/openvr/src/ViveControllerManager.cpp @@ -754,6 +754,12 @@ void ViveControllerManager::InputDevice::handleAxisEvent(float deltaTime, uint32 } _axisStateMap[isLeftHand ? LX : RX] = stick.x; _axisStateMap[isLeftHand ? LY : RY] = stick.y; + + if (stick.y > 0.75f) + { + // Simulate pointing gesture from the oculus controller + _buttonPressedMap.insert(isLeftHand ? LEFT_INDEX_POINT : RIGHT_INDEX_POINT); + } } else if (axis == vr::k_EButton_SteamVR_Trigger) { _axisStateMap[isLeftHand ? LT : RT] = x; // The click feeling on the Vive controller trigger represents a value of *precisely* 1.0, @@ -808,9 +814,11 @@ void ViveControllerManager::InputDevice::handleButtonEvent(float deltaTime, uint } } - if (touched) { - if (button == vr::k_EButton_SteamVR_Touchpad) { - _buttonPressedMap.insert(isLeftHand ? LS_TOUCH : RS_TOUCH); + if (button == vr::k_EButton_SteamVR_Touchpad) { + if (touched) { + _buttonPressedMap.insert(isLeftHand ? LS_TOUCH : RS_TOUCH); + } else { + _buttonPressedMap.insert(isLeftHand ? LEFT_THUMB_UP : RIGHT_THUMB_UP); } } } @@ -1102,6 +1110,11 @@ controller::Input::NamedVector ViveControllerManager::InputDevice::getAvailableI // app button above trackpad. Input::NamedPair(Input(_deviceID, LEFT_APP_MENU, ChannelType::BUTTON), "LeftApplicationMenu"), Input::NamedPair(Input(_deviceID, RIGHT_APP_MENU, ChannelType::BUTTON), "RightApplicationMenu"), + + makePair(LEFT_THUMB_UP, "LeftThumbUp"), + makePair(RIGHT_THUMB_UP, "RightThumbUp"), + makePair(LEFT_INDEX_POINT, "LeftIndexPoint"), + makePair(RIGHT_INDEX_POINT, "RightIndexPoint"), }; return availableInputs; From f5ccf508c93012af95190d5d543f9ccf71c2d677 Mon Sep 17 00:00:00 2001 From: 1P-Cusack <1p-cusack@1stplayable.com> Date: Mon, 10 Jul 2017 14:11:04 -0400 Subject: [PATCH 05/30] Fixing braces dropped in merge conflict edit. --- interface/resources/controllers/vive.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/interface/resources/controllers/vive.json b/interface/resources/controllers/vive.json index fbe65950c4..062a8787ce 100644 --- a/interface/resources/controllers/vive.json +++ b/interface/resources/controllers/vive.json @@ -59,8 +59,8 @@ { "from": "Vive.Head", "to" : "Standard.Head"}, - { "from": "Vive.RightArm", "to" : "Standard.RightArm", - { "from": "Vive.LeftArm", "to" : "Standard.LeftArm", + { "from": "Vive.RightArm", "to" : "Standard.RightArm" }, + { "from": "Vive.LeftArm", "to" : "Standard.LeftArm" }, { "from": "Vive.LeftThumbUp", "to": "Standard.LeftThumbUp" }, { "from": "Vive.RightThumbUp", "to": "Standard.RightThumbUp" }, { "from": "Vive.LeftIndexPoint", "to": "Standard.LeftIndexPoint" }, From 9a2084425da9b0022a4eb78a8b01046b7dfaf54d Mon Sep 17 00:00:00 2001 From: 1P-Cusack <1p-cusack@1stplayable.com> Date: Mon, 10 Jul 2017 14:18:11 -0400 Subject: [PATCH 06/30] Stylistic updates. --- plugins/openvr/src/ViveControllerManager.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/openvr/src/ViveControllerManager.cpp b/plugins/openvr/src/ViveControllerManager.cpp index 871b1a837f..d29f396342 100644 --- a/plugins/openvr/src/ViveControllerManager.cpp +++ b/plugins/openvr/src/ViveControllerManager.cpp @@ -62,6 +62,8 @@ static const int SECOND_FOOT = 1; static const int HIP = 2; static const int CHEST = 3; +static const float POINTING_THRESHOLD = 0.75f; + const char* ViveControllerManager::NAME { "OpenVR" }; const std::map TRACKING_RESULT_TO_STRING = { @@ -810,8 +812,7 @@ void ViveControllerManager::InputDevice::handleAxisEvent(float deltaTime, uint32 _axisStateMap[isLeftHand ? LX : RX] = stick.x; _axisStateMap[isLeftHand ? LY : RY] = stick.y; - if (stick.y > 0.75f) - { + if (stick.y > POINTING_THRESHOLD) { // Simulate pointing gesture from the oculus controller _buttonPressedMap.insert(isLeftHand ? LEFT_INDEX_POINT : RIGHT_INDEX_POINT); } From 2cd10fd459560a6ce52f2935b1c7a36356566ac2 Mon Sep 17 00:00:00 2001 From: 1P-Cusack <1p-cusack@1stplayable.com> Date: Wed, 12 Jul 2017 11:08:50 -0400 Subject: [PATCH 07/30] Move 'index point' logic into json config file. --- interface/resources/controllers/vive.json | 13 ++++++++++--- plugins/openvr/src/ViveControllerManager.cpp | 9 --------- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/interface/resources/controllers/vive.json b/interface/resources/controllers/vive.json index 062a8787ce..349554673d 100644 --- a/interface/resources/controllers/vive.json +++ b/interface/resources/controllers/vive.json @@ -1,6 +1,15 @@ { "name": "Vive to Standard", "channels": [ + { "from": "Vive.LY", "to": "Standard.LeftIndexPoint", + "peek": true, + "filters": [ { "type": "hysteresis", "min": 0.7, "max": 0.75 } ] + }, + { "from": "Vive.RY", "to": "Standard.RightIndexPoint", + "peek": true, + "filters": [ { "type": "hysteresis", "min": 0.7, "max": 0.75 } ] + }, + { "from": "Vive.LY", "when": "Vive.LSY", "filters": ["invert"], "to": "Standard.LY" }, { "from": "Vive.LX", "when": "Vive.LSX", "to": "Standard.LX" }, { @@ -62,8 +71,6 @@ { "from": "Vive.RightArm", "to" : "Standard.RightArm" }, { "from": "Vive.LeftArm", "to" : "Standard.LeftArm" }, { "from": "Vive.LeftThumbUp", "to": "Standard.LeftThumbUp" }, - { "from": "Vive.RightThumbUp", "to": "Standard.RightThumbUp" }, - { "from": "Vive.LeftIndexPoint", "to": "Standard.LeftIndexPoint" }, - { "from": "Vive.RightIndexPoint", "to": "Standard.RightIndexPoint" } + { "from": "Vive.RightThumbUp", "to": "Standard.RightThumbUp" } ] } diff --git a/plugins/openvr/src/ViveControllerManager.cpp b/plugins/openvr/src/ViveControllerManager.cpp index d29f396342..895aff4f03 100644 --- a/plugins/openvr/src/ViveControllerManager.cpp +++ b/plugins/openvr/src/ViveControllerManager.cpp @@ -62,8 +62,6 @@ static const int SECOND_FOOT = 1; static const int HIP = 2; static const int CHEST = 3; -static const float POINTING_THRESHOLD = 0.75f; - const char* ViveControllerManager::NAME { "OpenVR" }; const std::map TRACKING_RESULT_TO_STRING = { @@ -811,11 +809,6 @@ void ViveControllerManager::InputDevice::handleAxisEvent(float deltaTime, uint32 } _axisStateMap[isLeftHand ? LX : RX] = stick.x; _axisStateMap[isLeftHand ? LY : RY] = stick.y; - - if (stick.y > POINTING_THRESHOLD) { - // Simulate pointing gesture from the oculus controller - _buttonPressedMap.insert(isLeftHand ? LEFT_INDEX_POINT : RIGHT_INDEX_POINT); - } } else if (axis == vr::k_EButton_SteamVR_Trigger) { _axisStateMap[isLeftHand ? LT : RT] = x; // The click feeling on the Vive controller trigger represents a value of *precisely* 1.0, @@ -1182,8 +1175,6 @@ controller::Input::NamedVector ViveControllerManager::InputDevice::getAvailableI makePair(LEFT_THUMB_UP, "LeftThumbUp"), makePair(RIGHT_THUMB_UP, "RightThumbUp"), - makePair(LEFT_INDEX_POINT, "LeftIndexPoint"), - makePair(RIGHT_INDEX_POINT, "RightIndexPoint"), }; return availableInputs; From af751c8b8c77dd7f522a14771ef438093d759dcd Mon Sep 17 00:00:00 2001 From: 1P-Cusack <1p-cusack@1stplayable.com> Date: Mon, 17 Jul 2017 10:53:37 -0400 Subject: [PATCH 08/30] Add filter to map the boolean negation of a flag. --- .../src/controllers/impl/Filter.cpp | 2 ++ .../controllers/impl/RouteBuilderProxy.cpp | 6 ++++++ .../src/controllers/impl/RouteBuilderProxy.h | 1 + .../controllers/impl/filters/NotFilter.cpp | 10 +++++++++ .../src/controllers/impl/filters/NotFilter.h | 21 +++++++++++++++++++ 5 files changed, 40 insertions(+) create mode 100644 libraries/controllers/src/controllers/impl/filters/NotFilter.cpp create mode 100644 libraries/controllers/src/controllers/impl/filters/NotFilter.h diff --git a/libraries/controllers/src/controllers/impl/Filter.cpp b/libraries/controllers/src/controllers/impl/Filter.cpp index e75465f007..08cba9c296 100644 --- a/libraries/controllers/src/controllers/impl/Filter.cpp +++ b/libraries/controllers/src/controllers/impl/Filter.cpp @@ -22,6 +22,7 @@ #include "filters/DeadZoneFilter.h" #include "filters/HysteresisFilter.h" #include "filters/InvertFilter.h" +#include "filters/NotFilter.h" #include "filters/PulseFilter.h" #include "filters/ScaleFilter.h" #include "filters/TranslateFilter.h" @@ -40,6 +41,7 @@ REGISTER_FILTER_CLASS_INSTANCE(ConstrainToPositiveIntegerFilter, "constrainToPos REGISTER_FILTER_CLASS_INSTANCE(DeadZoneFilter, "deadZone") REGISTER_FILTER_CLASS_INSTANCE(HysteresisFilter, "hysteresis") REGISTER_FILTER_CLASS_INSTANCE(InvertFilter, "invert") +REGISTER_FILTER_CLASS_INSTANCE(NotFilter, "not") REGISTER_FILTER_CLASS_INSTANCE(ScaleFilter, "scale") REGISTER_FILTER_CLASS_INSTANCE(PulseFilter, "pulse") REGISTER_FILTER_CLASS_INSTANCE(TranslateFilter, "translate") diff --git a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp index 581d51ea61..c6abc2d402 100644 --- a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp +++ b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp @@ -24,6 +24,7 @@ #include "filters/DeadZoneFilter.h" #include "filters/HysteresisFilter.h" #include "filters/InvertFilter.h" +#include "filters/NotFilter.h" #include "filters/PulseFilter.h" #include "filters/ScaleFilter.h" #include "filters/TranslateFilter.h" @@ -148,6 +149,11 @@ QObject* RouteBuilderProxy::pulse(float interval) { return this; } +QObject* RouteBuilderProxy::not() { + addFilter(std::make_shared()); + return this; +} + void RouteBuilderProxy::addFilter(Filter::Pointer filter) { _route->filters.push_back(filter); } diff --git a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h index 102e72b3ad..d70bdb649f 100644 --- a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h +++ b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h @@ -53,6 +53,7 @@ class RouteBuilderProxy : public QObject { Q_INVOKABLE QObject* postTransform(glm::mat4 transform); Q_INVOKABLE QObject* rotate(glm::quat rotation); Q_INVOKABLE QObject* lowVelocity(float rotationConstant, float translationConstant); + Q_INVOKABLE QObject* not(); private: void to(const Endpoint::Pointer& destination); diff --git a/libraries/controllers/src/controllers/impl/filters/NotFilter.cpp b/libraries/controllers/src/controllers/impl/filters/NotFilter.cpp new file mode 100644 index 0000000000..73460aed91 --- /dev/null +++ b/libraries/controllers/src/controllers/impl/filters/NotFilter.cpp @@ -0,0 +1,10 @@ +#include "NotFilter.h" + +using namespace controller; + +NotFilter::NotFilter() { +} + +float NotFilter::apply(float value) const { + return (value == 0.0f) ? 1.0f : 0.0f; +} diff --git a/libraries/controllers/src/controllers/impl/filters/NotFilter.h b/libraries/controllers/src/controllers/impl/filters/NotFilter.h new file mode 100644 index 0000000000..ceb7d29de3 --- /dev/null +++ b/libraries/controllers/src/controllers/impl/filters/NotFilter.h @@ -0,0 +1,21 @@ +#pragma once +#ifndef hifi_Controllers_Filters_Not_h +#define hifi_Controllers_Filters_Not_h + +#include "../Filter.h" + +namespace controller { + +class NotFilter : public Filter { + REGISTER_FILTER_CLASS(NotFilter); +public: + NotFilter(); + + virtual float apply(float value) const override; + virtual Pose apply(Pose value) const override { return value; } +}; + +} + +#endif + From 7319998df9cf8a838e8d812bb8ff6a7a6eae7e41 Mon Sep 17 00:00:00 2001 From: 1P-Cusack <1p-cusack@1stplayable.com> Date: Mon, 17 Jul 2017 10:58:30 -0400 Subject: [PATCH 09/30] Move ThumbUp gesture detection into json map file. --- interface/resources/controllers/vive.json | 12 +++++++++--- plugins/openvr/src/ViveControllerManager.cpp | 11 +++-------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/interface/resources/controllers/vive.json b/interface/resources/controllers/vive.json index 349554673d..cc8e2a437a 100644 --- a/interface/resources/controllers/vive.json +++ b/interface/resources/controllers/vive.json @@ -22,6 +22,10 @@ { "from": "Vive.LeftGrip", "to": "Standard.LeftGrip" }, { "from": "Vive.LS", "to": "Standard.LS" }, + { "from": "Vive.LSTouch", "to": "Standard.LeftThumbUp", + "peek": true, + "filters": [ { "type": "not" } ] + }, { "from": "Vive.LSTouch", "to": "Standard.LSTouch" }, { "from": "Vive.RY", "when": "Vive.RSY", "filters": ["invert"], "to": "Standard.RY" }, @@ -36,6 +40,10 @@ { "from": "Vive.RightGrip", "to": "Standard.RightGrip" }, { "from": "Vive.RS", "to": "Standard.RS" }, + { "from": "Vive.RSTouch", "to": "Standard.RightThumbUp", + "peek": true, + "filters": [ { "type": "not" } ] + }, { "from": "Vive.RSTouch", "to": "Standard.RSTouch" }, { "from": "Vive.LSCenter", "to": "Standard.LeftPrimaryThumb" }, @@ -69,8 +77,6 @@ { "from": "Vive.Head", "to" : "Standard.Head"}, { "from": "Vive.RightArm", "to" : "Standard.RightArm" }, - { "from": "Vive.LeftArm", "to" : "Standard.LeftArm" }, - { "from": "Vive.LeftThumbUp", "to": "Standard.LeftThumbUp" }, - { "from": "Vive.RightThumbUp", "to": "Standard.RightThumbUp" } + { "from": "Vive.LeftArm", "to" : "Standard.LeftArm" } ] } diff --git a/plugins/openvr/src/ViveControllerManager.cpp b/plugins/openvr/src/ViveControllerManager.cpp index 895aff4f03..07b3b2f73d 100644 --- a/plugins/openvr/src/ViveControllerManager.cpp +++ b/plugins/openvr/src/ViveControllerManager.cpp @@ -863,11 +863,9 @@ void ViveControllerManager::InputDevice::handleButtonEvent(float deltaTime, uint } } - if (button == vr::k_EButton_SteamVR_Touchpad) { - if (touched) { - _buttonPressedMap.insert(isLeftHand ? LS_TOUCH : RS_TOUCH); - } else { - _buttonPressedMap.insert(isLeftHand ? LEFT_THUMB_UP : RIGHT_THUMB_UP); + if (touched) { + if (button == vr::k_EButton_SteamVR_Touchpad) { + _buttonPressedMap.insert(isLeftHand ? LS_TOUCH : RS_TOUCH); } } } @@ -1172,9 +1170,6 @@ controller::Input::NamedVector ViveControllerManager::InputDevice::getAvailableI // app button above trackpad. Input::NamedPair(Input(_deviceID, LEFT_APP_MENU, ChannelType::BUTTON), "LeftApplicationMenu"), Input::NamedPair(Input(_deviceID, RIGHT_APP_MENU, ChannelType::BUTTON), "RightApplicationMenu"), - - makePair(LEFT_THUMB_UP, "LeftThumbUp"), - makePair(RIGHT_THUMB_UP, "RightThumbUp"), }; return availableInputs; From c56450b986e59270730b1de48df087fa5f35ce39 Mon Sep 17 00:00:00 2001 From: Mike Moody Date: Wed, 19 Jul 2017 01:49:39 -0700 Subject: [PATCH 10/30] Moved function to a differnt location that handles both mouse and controller inputs. --- scripts/system/edit.js | 2 -- scripts/system/libraries/entitySelectionTool.js | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/system/edit.js b/scripts/system/edit.js index e9afc3a167..52b8c8d51e 100644 --- a/scripts/system/edit.js +++ b/scripts/system/edit.js @@ -943,8 +943,6 @@ function mouseClickEvent(event) { selectionManager.addEntity(foundEntity, true); } - entityIconOverlayManager.setIconsSelectable(selectionManager.selections,true); - if (wantDebug) { print("Model selected: " + foundEntity); } diff --git a/scripts/system/libraries/entitySelectionTool.js b/scripts/system/libraries/entitySelectionTool.js index 725803f824..f9081080fd 100644 --- a/scripts/system/libraries/entitySelectionTool.js +++ b/scripts/system/libraries/entitySelectionTool.js @@ -4064,6 +4064,7 @@ SelectionDisplay = (function() { // if another mouse button than left is pressed ignore it return false; } + entityIconOverlayManager.setIconsSelectable(selectionManager.selections,true); var somethingClicked = false; var pickRay = generalComputePickRay(event.x, event.y); From 649b974927e0deff5156d1333555b40206e4773d Mon Sep 17 00:00:00 2001 From: Dante Ruiz Date: Fri, 21 Jul 2017 01:01:23 +0100 Subject: [PATCH 11/30] mods for changes camera views --- interface/src/Application.cpp | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index dbb94cfdae..885663939b 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3020,7 +3020,34 @@ void Application::keyPressEvent(QKeyEvent* event) { break; case Qt::Key_F: { - _physicsEngine->dumpNextStats(); + if (isMeta) { + auto menu = Menu::getInstance(); + if (menu->isOptionChecked(MenuOption::FirstPerson)) { + menu->setIsOptionChecked(MenuOption::ThirdPerson, true); + menu->setIsOptionChecked(MenuOption::FirstPerson, false); + } else { + menu->setIsOptionChecked(MenuOption::FirstPerson, true); + menu->setIsOptionChecked(MenuOption::ThirdPerson, false); + } + cameraMenuChanged(); + } else if (isOption) { + _physicsEngine->dumpNextStats(); + } + break; + } + + case Qt::Key_H: { + if (isOption) { + auto menu = Menu::getInstance(); + if (menu->isOptionChecked(MenuOption::FullscreenMirror)) { + menu->setIsOptionChecked(MenuOption::FullscreenMirror, false); + menu->setIsOptionChecked(MenuOption::FirstPerson, true); + } else { + menu->setIsOptionChecked(MenuOption::FullscreenMirror, true); + menu->setIsOptionChecked(MenuOption::FirstPerson, false); + } + } + cameraMenuChanged(); break; } From 5f3b68d544d6d4e03fd54e6d9a09a28e9dd7840f Mon Sep 17 00:00:00 2001 From: anshuman64 Date: Thu, 20 Jul 2017 17:36:02 -0700 Subject: [PATCH 12/30] Use ctrl+H instead of alt+H --- interface/src/Application.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 885663939b..92199f8774 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3037,7 +3037,7 @@ void Application::keyPressEvent(QKeyEvent* event) { } case Qt::Key_H: { - if (isOption) { + if (isMeta) { auto menu = Menu::getInstance(); if (menu->isOptionChecked(MenuOption::FullscreenMirror)) { menu->setIsOptionChecked(MenuOption::FullscreenMirror, false); From 06b4c53d28f0c843ab8b927bbe8ba94695dc15b3 Mon Sep 17 00:00:00 2001 From: Dante Ruiz Date: Sat, 22 Jul 2017 00:15:26 +0100 Subject: [PATCH 13/30] only desktop mode --- interface/src/Application.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 92199f8774..03f62221ef 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3037,7 +3037,7 @@ void Application::keyPressEvent(QKeyEvent* event) { } case Qt::Key_H: { - if (isMeta) { + if (isMeta && !isHMDMode()) { auto menu = Menu::getInstance(); if (menu->isOptionChecked(MenuOption::FullscreenMirror)) { menu->setIsOptionChecked(MenuOption::FullscreenMirror, false); From 507368726f21561af92fd917c9938a4a8fb5a868 Mon Sep 17 00:00:00 2001 From: Rob Kayson Date: Mon, 24 Jul 2017 14:38:22 -0700 Subject: [PATCH 14/30] added dart scripts --- .../marketplace/dart/createDart.js | 91 +++++++++++++++++++ unpublishedScripts/marketplace/dart/dart.js | 81 +++++++++++++++++ 2 files changed, 172 insertions(+) create mode 100644 unpublishedScripts/marketplace/dart/createDart.js create mode 100644 unpublishedScripts/marketplace/dart/dart.js diff --git a/unpublishedScripts/marketplace/dart/createDart.js b/unpublishedScripts/marketplace/dart/createDart.js new file mode 100644 index 0000000000..ff13a695a8 --- /dev/null +++ b/unpublishedScripts/marketplace/dart/createDart.js @@ -0,0 +1,91 @@ +"use strict"; +// +// createDart.js +// +// Created by MrRoboman on 17/05/04 +// Copyright 2017 High Fidelity, Inc. +// +// Creates five throwing darts. +// +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html + +var MODEL_URL = "https://hifi-content.s3.amazonaws.com/wadewatts/dart.fbx"; +var SCRIPT_URL = Script.resolvePath("./dart.js?v=" + Date.now()); +var START_POSITION = Vec3.sum(MyAvatar.position, Vec3.multiply(Quat.getFront(MyAvatar.orientation), 0.75)); +var START_ROTATION = MyAvatar.orientation +var SCALE_FACTOR = 1; + +var dart = { + type: "Model", + shapeType: "box", + name: "Dart", + description: "Throw it at something!", + script: SCRIPT_URL, + modelURL: MODEL_URL, + position: START_POSITION, + rotation: START_ROTATION, + lifetime: 300, + gravity: { + x: 0, + y: -9.8, + z: 0 + }, + dimensions: { + x: 0.1, + y: 0.1, + z: 0.3 + }, + dynamic: true, + owningAvatarID: MyAvatar.sessionUUID, + userData: JSON.stringify({ + grabbableKey: { + grabbable: true, + invertSolidWhileHeld: true, + ignoreIK: false + } + }) +}; + +var avatarUp = Quat.getUp(MyAvatar.orientation); +var platformPosition = Vec3.sum(START_POSITION, Vec3.multiply(avatarUp, -0.05)); +var platform = { + type: "Box", + name: "Dart Platform", + description: "Holds darts", + position: platformPosition, + rotation: START_ROTATION, + lifetime: 60, + dimensions: { + x: 0.15 * 5, + y: 0.01, + z: 0.3 + }, + color: { + red: 129, + green: 92, + blue: 11 + }, + owningAvatarID: MyAvatar.sessionUUID, + userData: JSON.stringify({ + grabbableKey: { + grabbable: true, + invertSolidWhileHeld: true, + ignoreIK: false + } + }) +}; + + +Entities.addEntity(platform); + +var dartCount = 5; +var avatarRight = Quat.getRight(MyAvatar.orientation); +for (var i = 0; i < dartCount; i++) { + var j = i - Math.floor(dartCount / 2); + var position = Vec3.sum(START_POSITION, Vec3.multiply(avatarRight, 0.15 * j)); + dart.position = position; + Entities.addEntity(dart); +} + +Script.stop(); diff --git a/unpublishedScripts/marketplace/dart/dart.js b/unpublishedScripts/marketplace/dart/dart.js new file mode 100644 index 0000000000..9debe910e3 --- /dev/null +++ b/unpublishedScripts/marketplace/dart/dart.js @@ -0,0 +1,81 @@ +"use strict"; +// +// dart.js +// +// Created by MrRoboman on 17/05/13 +// Copyright 2017 High Fidelity, Inc. +// +// Simple throwing dart. Sticks to static objects. +// +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html + +(function() { + var THROW_FACTOR = 3; + var DART_SOUND_URL = Script.resolvePath('https://hifi-content.s3.amazonaws.com/wadewatts/dart.wav?v=' + Date.now()); + + var Dart = function() {}; + + Dart.prototype = { + + preload: function(entityID) { + this.entityID = entityID; + this.actionID = null; + this.soundHasPlayed = true; + this.dartSound = SoundCache.getSound(DART_SOUND_URL); + }, + + playDartSound: function(sound) { + if (this.soundHasPlayed) { + return; + } + this.soundHasPlayed = true; + var position = Entities.getEntityProperties(this.entityID, 'position').position; + var audioProperties = { + volume: 0.15, + position: position + }; + Audio.playSound(this.dartSound, audioProperties); + }, + + releaseGrab: function() { + this.soundHasPlayed = false; + var velocity = Entities.getEntityProperties(this.entityID, 'velocity').velocity; + + var newVelocity = {}; + Object.keys(velocity).forEach(function(key) { + newVelocity[key] = velocity[key] * THROW_FACTOR; + }); + + Entities.editEntity(this.entityID, { + velocity: newVelocity + }); + + if (this.actionID) { + Entities.deleteAction(this.entityID, this.actionID); + } + this.actionID = Entities.addAction("travel-oriented", this.entityID, { + forward: { x: 0, y: 0, z: 1 }, + angularTimeScale: 0.1, + tag: "throwing dart", + ttl: 3600 + }); + }, + + collisionWithEntity: function(myID, otherID, collisionInfo) { + this.playDartSound(); + + Entities.editEntity(myID, { + velocity: {x: 0, y: 0, z: 0}, + angularVelocity: {x: 0, y: 0, z: 0} + }); + + if (this.actionID) { + Entities.deleteAction(myID, this.actionID); + this.actionID = null; + } + } + }; + + return new Dart(); +}); From 7de164f1ab6804dedec413320415bcde8784da55 Mon Sep 17 00:00:00 2001 From: Mike Moody Date: Mon, 24 Jul 2017 15:06:45 -0700 Subject: [PATCH 15/30] moved below a check that returns. --- scripts/system/libraries/entitySelectionTool.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/system/libraries/entitySelectionTool.js b/scripts/system/libraries/entitySelectionTool.js index f9081080fd..91ddf2a2d1 100644 --- a/scripts/system/libraries/entitySelectionTool.js +++ b/scripts/system/libraries/entitySelectionTool.js @@ -4064,7 +4064,6 @@ SelectionDisplay = (function() { // if another mouse button than left is pressed ignore it return false; } - entityIconOverlayManager.setIconsSelectable(selectionManager.selections,true); var somethingClicked = false; var pickRay = generalComputePickRay(event.x, event.y); @@ -4075,6 +4074,8 @@ SelectionDisplay = (function() { return false; } + entityIconOverlayManager.setIconsSelectable(selectionManager.selections,true); + // before we do a ray test for grabbers, disable the ray intersection for our selection box Overlays.editOverlay(selectionBox, { ignoreRayIntersection: true From e53badf88b01c0d8b69551337a0105e31fddebef Mon Sep 17 00:00:00 2001 From: Seth Alves Date: Mon, 24 Jul 2017 15:56:37 -0700 Subject: [PATCH 16/30] use alt+f for 1st person camera and alt+o for 3rd --- interface/src/Application.cpp | 13 +------------ interface/src/Menu.cpp | 12 ++++++------ 2 files changed, 7 insertions(+), 18 deletions(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 03f62221ef..8113001cda 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3020,20 +3020,9 @@ void Application::keyPressEvent(QKeyEvent* event) { break; case Qt::Key_F: { - if (isMeta) { - auto menu = Menu::getInstance(); - if (menu->isOptionChecked(MenuOption::FirstPerson)) { - menu->setIsOptionChecked(MenuOption::ThirdPerson, true); - menu->setIsOptionChecked(MenuOption::FirstPerson, false); - } else { - menu->setIsOptionChecked(MenuOption::FirstPerson, true); - menu->setIsOptionChecked(MenuOption::ThirdPerson, false); - } - cameraMenuChanged(); - } else if (isOption) { + if (isOption) { _physicsEngine->dumpNextStats(); } - break; } case Qt::Key_H: { diff --git a/interface/src/Menu.cpp b/interface/src/Menu.cpp index c7223be208..f1ed0497c6 100644 --- a/interface/src/Menu.cpp +++ b/interface/src/Menu.cpp @@ -222,14 +222,14 @@ Menu::Menu() { cameraModeGroup->setExclusive(true); // View > First Person - cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash(viewMenu, - MenuOption::FirstPerson, 0, - true, qApp, SLOT(cameraMenuChanged()))); + cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash( + viewMenu, MenuOption::FirstPerson, Qt::ALT | Qt::Key_F, + true, qApp, SLOT(cameraMenuChanged()))); // View > Third Person - cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash(viewMenu, - MenuOption::ThirdPerson, 0, - false, qApp, SLOT(cameraMenuChanged()))); + cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash( + viewMenu, MenuOption::ThirdPerson, Qt::ALT | Qt::Key_O, + false, qApp, SLOT(cameraMenuChanged()))); // View > Mirror cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash(viewMenu, From 82a787a753ddefaa19c3531c37c719a9fcc07320 Mon Sep 17 00:00:00 2001 From: Seth Alves Date: Mon, 24 Jul 2017 16:04:11 -0700 Subject: [PATCH 17/30] use alt+h for mirror-mode --- interface/src/Application.cpp | 31 ++++++++++--------------------- interface/src/Menu.cpp | 6 +++--- 2 files changed, 13 insertions(+), 24 deletions(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 8113001cda..4194ac9ecb 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3025,21 +3025,6 @@ void Application::keyPressEvent(QKeyEvent* event) { } } - case Qt::Key_H: { - if (isMeta && !isHMDMode()) { - auto menu = Menu::getInstance(); - if (menu->isOptionChecked(MenuOption::FullscreenMirror)) { - menu->setIsOptionChecked(MenuOption::FullscreenMirror, false); - menu->setIsOptionChecked(MenuOption::FirstPerson, true); - } else { - menu->setIsOptionChecked(MenuOption::FullscreenMirror, true); - menu->setIsOptionChecked(MenuOption::FirstPerson, false); - } - } - cameraMenuChanged(); - break; - } - case Qt::Key_Asterisk: Menu::getInstance()->triggerOption(MenuOption::DefaultSkybox); break; @@ -4476,27 +4461,31 @@ void Application::cameraModeChanged() { void Application::cameraMenuChanged() { - if (Menu::getInstance()->isOptionChecked(MenuOption::FullscreenMirror)) { - if (_myCamera.getMode() != CAMERA_MODE_MIRROR) { + auto menu = Menu::getInstance(); + if (menu->isOptionChecked(MenuOption::FullscreenMirror)) { + if (isHMDMode()) { + menu->setIsOptionChecked(MenuOption::FullscreenMirror, false); + menu->setIsOptionChecked(MenuOption::FirstPerson, true); + } else if (_myCamera.getMode() != CAMERA_MODE_MIRROR) { _myCamera.setMode(CAMERA_MODE_MIRROR); } - } else if (Menu::getInstance()->isOptionChecked(MenuOption::FirstPerson)) { + } else if (menu->isOptionChecked(MenuOption::FirstPerson)) { if (_myCamera.getMode() != CAMERA_MODE_FIRST_PERSON) { _myCamera.setMode(CAMERA_MODE_FIRST_PERSON); getMyAvatar()->setBoomLength(MyAvatar::ZOOM_MIN); } - } else if (Menu::getInstance()->isOptionChecked(MenuOption::ThirdPerson)) { + } else if (menu->isOptionChecked(MenuOption::ThirdPerson)) { if (_myCamera.getMode() != CAMERA_MODE_THIRD_PERSON) { _myCamera.setMode(CAMERA_MODE_THIRD_PERSON); if (getMyAvatar()->getBoomLength() == MyAvatar::ZOOM_MIN) { getMyAvatar()->setBoomLength(MyAvatar::ZOOM_DEFAULT); } } - } else if (Menu::getInstance()->isOptionChecked(MenuOption::IndependentMode)) { + } else if (menu->isOptionChecked(MenuOption::IndependentMode)) { if (_myCamera.getMode() != CAMERA_MODE_INDEPENDENT) { _myCamera.setMode(CAMERA_MODE_INDEPENDENT); } - } else if (Menu::getInstance()->isOptionChecked(MenuOption::CameraEntityMode)) { + } else if (menu->isOptionChecked(MenuOption::CameraEntityMode)) { if (_myCamera.getMode() != CAMERA_MODE_ENTITY) { _myCamera.setMode(CAMERA_MODE_ENTITY); } diff --git a/interface/src/Menu.cpp b/interface/src/Menu.cpp index f1ed0497c6..c6679f3bf6 100644 --- a/interface/src/Menu.cpp +++ b/interface/src/Menu.cpp @@ -232,9 +232,9 @@ Menu::Menu() { false, qApp, SLOT(cameraMenuChanged()))); // View > Mirror - cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash(viewMenu, - MenuOption::FullscreenMirror, 0, - false, qApp, SLOT(cameraMenuChanged()))); + cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash( + viewMenu, MenuOption::FullscreenMirror, Qt::ALT | Qt::Key_H, + false, qApp, SLOT(cameraMenuChanged()))); // View > Independent [advanced] cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash(viewMenu, From 97756e6140dc1677282c114bc008ae927ac5c5ea Mon Sep 17 00:00:00 2001 From: Seth Alves Date: Mon, 24 Jul 2017 16:12:03 -0700 Subject: [PATCH 18/30] accidently deleted a break --- interface/src/Application.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 4194ac9ecb..1ed6c5078a 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3023,6 +3023,7 @@ void Application::keyPressEvent(QKeyEvent* event) { if (isOption) { _physicsEngine->dumpNextStats(); } + break; } case Qt::Key_Asterisk: From 4c78fba2ccb81c4e29185d40ea7568a250c402a3 Mon Sep 17 00:00:00 2001 From: Mike Moody Date: Mon, 24 Jul 2017 16:50:33 -0700 Subject: [PATCH 19/30] Removed line that caused colflict. --- scripts/system/libraries/entitySelectionTool.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/scripts/system/libraries/entitySelectionTool.js b/scripts/system/libraries/entitySelectionTool.js index 91ddf2a2d1..725803f824 100644 --- a/scripts/system/libraries/entitySelectionTool.js +++ b/scripts/system/libraries/entitySelectionTool.js @@ -4074,8 +4074,6 @@ SelectionDisplay = (function() { return false; } - entityIconOverlayManager.setIconsSelectable(selectionManager.selections,true); - // before we do a ray test for grabbers, disable the ray intersection for our selection box Overlays.editOverlay(selectionBox, { ignoreRayIntersection: true From 036a16c0b384f69cf5949645315f0e266b24a0fc Mon Sep 17 00:00:00 2001 From: Mike Moody Date: Mon, 24 Jul 2017 16:51:23 -0700 Subject: [PATCH 20/30] readded line that caused colflict. --- scripts/system/libraries/entitySelectionTool.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/system/libraries/entitySelectionTool.js b/scripts/system/libraries/entitySelectionTool.js index 2d1853fae2..77b62913bf 100644 --- a/scripts/system/libraries/entitySelectionTool.js +++ b/scripts/system/libraries/entitySelectionTool.js @@ -4060,6 +4060,8 @@ SelectionDisplay = (function() { return false; } + entityIconOverlayManager.setIconsSelectable(selectionManager.selections,true); + // ignore ray intersection for our selection box and yaw/pitch/roll result = Overlays.findRayIntersection(pickRay, true, null, [ yawHandle, pitchHandle, rollHandle, selectionBox ] ); if (result.intersects) { From 766c6f48c3b9acf016aae10b8e342eb8b1d39e61 Mon Sep 17 00:00:00 2001 From: Seth Alves Date: Mon, 24 Jul 2017 17:43:01 -0700 Subject: [PATCH 21/30] third person camera is alt+G rather than alt+O --- interface/src/Menu.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/interface/src/Menu.cpp b/interface/src/Menu.cpp index c6679f3bf6..72a3eb6bfc 100644 --- a/interface/src/Menu.cpp +++ b/interface/src/Menu.cpp @@ -228,7 +228,7 @@ Menu::Menu() { // View > Third Person cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash( - viewMenu, MenuOption::ThirdPerson, Qt::ALT | Qt::Key_O, + viewMenu, MenuOption::ThirdPerson, Qt::ALT | Qt::Key_G, false, qApp, SLOT(cameraMenuChanged()))); // View > Mirror From 9e25c3b7d8d6446b7e678accf06d1da945868de4 Mon Sep 17 00:00:00 2001 From: 1P-Cusack <1p-cusack@1stplayable.com> Date: Tue, 25 Jul 2017 14:47:34 -0400 Subject: [PATCH 22/30] Renaming 'not' route to 'logicalNot'. Build was failing on non-windows platforms because 'not' is a reserved word in C++ (which Visual Studio happily ignores). --- interface/resources/controllers/vive.json | 4 ++-- libraries/controllers/src/controllers/impl/Filter.cpp | 2 +- .../controllers/src/controllers/impl/RouteBuilderProxy.cpp | 2 +- .../controllers/src/controllers/impl/RouteBuilderProxy.h | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/interface/resources/controllers/vive.json b/interface/resources/controllers/vive.json index cc8e2a437a..73ab5cb2ae 100644 --- a/interface/resources/controllers/vive.json +++ b/interface/resources/controllers/vive.json @@ -24,7 +24,7 @@ { "from": "Vive.LS", "to": "Standard.LS" }, { "from": "Vive.LSTouch", "to": "Standard.LeftThumbUp", "peek": true, - "filters": [ { "type": "not" } ] + "filters": [ { "type": "logicalNot" } ] }, { "from": "Vive.LSTouch", "to": "Standard.LSTouch" }, @@ -42,7 +42,7 @@ { "from": "Vive.RS", "to": "Standard.RS" }, { "from": "Vive.RSTouch", "to": "Standard.RightThumbUp", "peek": true, - "filters": [ { "type": "not" } ] + "filters": [ { "type": "logicalNot" } ] }, { "from": "Vive.RSTouch", "to": "Standard.RSTouch" }, diff --git a/libraries/controllers/src/controllers/impl/Filter.cpp b/libraries/controllers/src/controllers/impl/Filter.cpp index 08cba9c296..b6c3ed4d27 100644 --- a/libraries/controllers/src/controllers/impl/Filter.cpp +++ b/libraries/controllers/src/controllers/impl/Filter.cpp @@ -41,7 +41,7 @@ REGISTER_FILTER_CLASS_INSTANCE(ConstrainToPositiveIntegerFilter, "constrainToPos REGISTER_FILTER_CLASS_INSTANCE(DeadZoneFilter, "deadZone") REGISTER_FILTER_CLASS_INSTANCE(HysteresisFilter, "hysteresis") REGISTER_FILTER_CLASS_INSTANCE(InvertFilter, "invert") -REGISTER_FILTER_CLASS_INSTANCE(NotFilter, "not") +REGISTER_FILTER_CLASS_INSTANCE(NotFilter, "logicalNot") REGISTER_FILTER_CLASS_INSTANCE(ScaleFilter, "scale") REGISTER_FILTER_CLASS_INSTANCE(PulseFilter, "pulse") REGISTER_FILTER_CLASS_INSTANCE(TranslateFilter, "translate") diff --git a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp index c6abc2d402..bc1ef55725 100644 --- a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp +++ b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.cpp @@ -149,7 +149,7 @@ QObject* RouteBuilderProxy::pulse(float interval) { return this; } -QObject* RouteBuilderProxy::not() { +QObject* RouteBuilderProxy::logicalNot() { addFilter(std::make_shared()); return this; } diff --git a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h index d70bdb649f..75f3747566 100644 --- a/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h +++ b/libraries/controllers/src/controllers/impl/RouteBuilderProxy.h @@ -53,7 +53,7 @@ class RouteBuilderProxy : public QObject { Q_INVOKABLE QObject* postTransform(glm::mat4 transform); Q_INVOKABLE QObject* rotate(glm::quat rotation); Q_INVOKABLE QObject* lowVelocity(float rotationConstant, float translationConstant); - Q_INVOKABLE QObject* not(); + Q_INVOKABLE QObject* logicalNot(); private: void to(const Endpoint::Pointer& destination); From 65192aa620c13d1fe65c4dc032a42d6f5e9da148 Mon Sep 17 00:00:00 2001 From: utkarshgautamnyu Date: Tue, 25 Jul 2017 15:17:15 -0700 Subject: [PATCH 23/30] added additional collision types to asset browser and new model dialog --- interface/resources/qml/AssetServer.qml | 17 +++++++++++++++++ .../qml/hifi/tablet/NewModelDialog.qml | 5 ++++- scripts/system/edit.js | 15 +++++++++++++++ 3 files changed, 36 insertions(+), 1 deletion(-) diff --git a/interface/resources/qml/AssetServer.qml b/interface/resources/qml/AssetServer.qml index eb47afc951..11cab8b8de 100644 --- a/interface/resources/qml/AssetServer.qml +++ b/interface/resources/qml/AssetServer.qml @@ -151,12 +151,20 @@ ScrollingWindow { var SHAPE_TYPE_SIMPLE_HULL = 1; var SHAPE_TYPE_SIMPLE_COMPOUND = 2; var SHAPE_TYPE_STATIC_MESH = 3; + var SHAPE_TYPE_BOX = 4; + var SHAPE_TYPE_SPHERE = 5; + var SHAPE_TYPE_COMPOUND = 6; + var SHAPE_TYPES = []; SHAPE_TYPES[SHAPE_TYPE_NONE] = "No Collision"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_HULL] = "Basic - Whole model"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_COMPOUND] = "Good - Sub-meshes"; SHAPE_TYPES[SHAPE_TYPE_STATIC_MESH] = "Exact - All polygons"; + SHAPE_TYPES[SHAPE_TYPE_BOX] = "Box"; + SHAPE_TYPES[SHAPE_TYPE_SPHERE] = "Sphere"; + SHAPE_TYPES[SHAPE_TYPE_COMPOUND] = "Compound"; + var SHAPE_TYPE_DEFAULT = SHAPE_TYPE_STATIC_MESH; var DYNAMIC_DEFAULT = false; @@ -196,6 +204,15 @@ ScrollingWindow { case SHAPE_TYPE_STATIC_MESH: shapeType = "static-mesh"; break; + case SHAPE_TYPE_BOX: + shapeType = "box"; + break; + case SHAPE_TYPE_SPHERE: + shapeType = "sphere"; + break; + case SHAPE_TYPE_COMPOUND: + shapeType = "compound"; + break; default: shapeType = "none"; } diff --git a/interface/resources/qml/hifi/tablet/NewModelDialog.qml b/interface/resources/qml/hifi/tablet/NewModelDialog.qml index d47c981440..f0c9c3c14a 100644 --- a/interface/resources/qml/hifi/tablet/NewModelDialog.qml +++ b/interface/resources/qml/hifi/tablet/NewModelDialog.qml @@ -145,7 +145,10 @@ Rectangle { model: ["No Collision", "Basic - Whole model", "Good - Sub-meshes", - "Exact - All polygons"] + "Exact - All polygons", + "Box", + "Sphere", + "Compound"] } Row { diff --git a/scripts/system/edit.js b/scripts/system/edit.js index 6bb0675bc8..fbd1732b0b 100644 --- a/scripts/system/edit.js +++ b/scripts/system/edit.js @@ -337,6 +337,9 @@ var toolBar = (function () { var SHAPE_TYPE_SIMPLE_HULL = 1; var SHAPE_TYPE_SIMPLE_COMPOUND = 2; var SHAPE_TYPE_STATIC_MESH = 3; + var SHAPE_TYPE_BOX = 4; + var SHAPE_TYPE_SPHERE = 5; + var SHAPE_TYPE_COMPOUND = 6; var DYNAMIC_DEFAULT = false; function handleNewModelDialogResult(result) { @@ -353,6 +356,15 @@ var toolBar = (function () { case SHAPE_TYPE_STATIC_MESH: shapeType = "static-mesh"; break; + case SHAPE_TYPE_BOX: + shapeType = "box"; + break; + case SHAPE_TYPE_SPHERE: + shapeType = "sphere"; + break; + case SHAPE_TYPE_COMPOUND: + shapeType = "compound"; + break; default: shapeType = "none"; } @@ -450,6 +462,9 @@ var toolBar = (function () { SHAPE_TYPES[SHAPE_TYPE_SIMPLE_HULL] = "Basic - Whole model"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_COMPOUND] = "Good - Sub-meshes"; SHAPE_TYPES[SHAPE_TYPE_STATIC_MESH] = "Exact - All polygons"; + SHAPE_TYPES[SHAPE_TYPE_BOX] = "Box"; + SHAPE_TYPES[SHAPE_TYPE_SPHERE] = "Sphere"; + SHAPE_TYPES[SHAPE_TYPE_COMPOUND] = "Compound"; var SHAPE_TYPE_DEFAULT = SHAPE_TYPE_STATIC_MESH; // tablet version of new-model dialog From 24f4468fd5be0811ceea4d95436110467c9fc6f5 Mon Sep 17 00:00:00 2001 From: utkarshgautamnyu Date: Tue, 25 Jul 2017 17:09:46 -0700 Subject: [PATCH 24/30] added additional collision types to asset browser in tablet mode --- .../qml/hifi/dialogs/TabletAssetServer.qml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml b/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml index 0256805422..15f72cfbcb 100644 --- a/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml +++ b/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml @@ -152,12 +152,19 @@ Rectangle { var SHAPE_TYPE_SIMPLE_HULL = 1; var SHAPE_TYPE_SIMPLE_COMPOUND = 2; var SHAPE_TYPE_STATIC_MESH = 3; + var SHAPE_TYPE_BOX = 4; + var SHAPE_TYPE_SPHERE = 5; + var SHAPE_TYPE_COMPOUND = 6; + var SHAPE_TYPES = []; SHAPE_TYPES[SHAPE_TYPE_NONE] = "No Collision"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_HULL] = "Basic - Whole model"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_COMPOUND] = "Good - Sub-meshes"; SHAPE_TYPES[SHAPE_TYPE_STATIC_MESH] = "Exact - All polygons"; + SHAPE_TYPES[SHAPE_TYPE_BOX] = "Box"; + SHAPE_TYPES[SHAPE_TYPE_SPHERE] = "Sphere"; + SHAPE_TYPES[SHAPE_TYPE_COMPOUND] = "Compound"; var SHAPE_TYPE_DEFAULT = SHAPE_TYPE_STATIC_MESH; var DYNAMIC_DEFAULT = false; @@ -197,6 +204,15 @@ Rectangle { case SHAPE_TYPE_STATIC_MESH: shapeType = "static-mesh"; break; + case SHAPE_TYPE_BOX: + shapeType = "box"; + break; + case SHAPE_TYPE_SPHERE: + shapeType = "sphere"; + break; + case SHAPE_TYPE_COMPOUND: + shapeType = "compound"; + break; default: shapeType = "none"; } From 29e778323d2584b04e6c68e3912da07a35b9812d Mon Sep 17 00:00:00 2001 From: utkarshgautamnyu Date: Tue, 25 Jul 2017 17:24:06 -0700 Subject: [PATCH 25/30] Update AssetServer.qml --- interface/resources/qml/AssetServer.qml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/interface/resources/qml/AssetServer.qml b/interface/resources/qml/AssetServer.qml index 11cab8b8de..dc2c7bc8f6 100644 --- a/interface/resources/qml/AssetServer.qml +++ b/interface/resources/qml/AssetServer.qml @@ -154,8 +154,7 @@ ScrollingWindow { var SHAPE_TYPE_BOX = 4; var SHAPE_TYPE_SPHERE = 5; var SHAPE_TYPE_COMPOUND = 6; - - + var SHAPE_TYPES = []; SHAPE_TYPES[SHAPE_TYPE_NONE] = "No Collision"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_HULL] = "Basic - Whole model"; From 71ddf1e7c11ffa17c5065bd7a0446dc9daaa6dc4 Mon Sep 17 00:00:00 2001 From: utkarshgautamnyu Date: Wed, 26 Jul 2017 10:20:17 -0700 Subject: [PATCH 26/30] Removed Compound Collision type --- interface/resources/qml/AssetServer.qml | 11 ++--------- .../resources/qml/hifi/dialogs/TabletAssetServer.qml | 8 +------- .../resources/qml/hifi/tablet/NewModelDialog.qml | 3 +-- scripts/system/edit.js | 5 ----- 4 files changed, 4 insertions(+), 23 deletions(-) diff --git a/interface/resources/qml/AssetServer.qml b/interface/resources/qml/AssetServer.qml index 11cab8b8de..a400897276 100644 --- a/interface/resources/qml/AssetServer.qml +++ b/interface/resources/qml/AssetServer.qml @@ -153,9 +153,7 @@ ScrollingWindow { var SHAPE_TYPE_STATIC_MESH = 3; var SHAPE_TYPE_BOX = 4; var SHAPE_TYPE_SPHERE = 5; - var SHAPE_TYPE_COMPOUND = 6; - - + var SHAPE_TYPES = []; SHAPE_TYPES[SHAPE_TYPE_NONE] = "No Collision"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_HULL] = "Basic - Whole model"; @@ -163,9 +161,7 @@ ScrollingWindow { SHAPE_TYPES[SHAPE_TYPE_STATIC_MESH] = "Exact - All polygons"; SHAPE_TYPES[SHAPE_TYPE_BOX] = "Box"; SHAPE_TYPES[SHAPE_TYPE_SPHERE] = "Sphere"; - SHAPE_TYPES[SHAPE_TYPE_COMPOUND] = "Compound"; - - + var SHAPE_TYPE_DEFAULT = SHAPE_TYPE_STATIC_MESH; var DYNAMIC_DEFAULT = false; var prompt = desktop.customInputDialog({ @@ -210,9 +206,6 @@ ScrollingWindow { case SHAPE_TYPE_SPHERE: shapeType = "sphere"; break; - case SHAPE_TYPE_COMPOUND: - shapeType = "compound"; - break; default: shapeType = "none"; } diff --git a/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml b/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml index 15f72cfbcb..55c2c71c61 100644 --- a/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml +++ b/interface/resources/qml/hifi/dialogs/TabletAssetServer.qml @@ -154,9 +154,7 @@ Rectangle { var SHAPE_TYPE_STATIC_MESH = 3; var SHAPE_TYPE_BOX = 4; var SHAPE_TYPE_SPHERE = 5; - var SHAPE_TYPE_COMPOUND = 6; - var SHAPE_TYPES = []; SHAPE_TYPES[SHAPE_TYPE_NONE] = "No Collision"; SHAPE_TYPES[SHAPE_TYPE_SIMPLE_HULL] = "Basic - Whole model"; @@ -164,8 +162,7 @@ Rectangle { SHAPE_TYPES[SHAPE_TYPE_STATIC_MESH] = "Exact - All polygons"; SHAPE_TYPES[SHAPE_TYPE_BOX] = "Box"; SHAPE_TYPES[SHAPE_TYPE_SPHERE] = "Sphere"; - SHAPE_TYPES[SHAPE_TYPE_COMPOUND] = "Compound"; - + var SHAPE_TYPE_DEFAULT = SHAPE_TYPE_STATIC_MESH; var DYNAMIC_DEFAULT = false; var prompt = tabletRoot.customInputDialog({ @@ -210,9 +207,6 @@ Rectangle { case SHAPE_TYPE_SPHERE: shapeType = "sphere"; break; - case SHAPE_TYPE_COMPOUND: - shapeType = "compound"; - break; default: shapeType = "none"; } diff --git a/interface/resources/qml/hifi/tablet/NewModelDialog.qml b/interface/resources/qml/hifi/tablet/NewModelDialog.qml index f0c9c3c14a..47d28486a9 100644 --- a/interface/resources/qml/hifi/tablet/NewModelDialog.qml +++ b/interface/resources/qml/hifi/tablet/NewModelDialog.qml @@ -147,8 +147,7 @@ Rectangle { "Good - Sub-meshes", "Exact - All polygons", "Box", - "Sphere", - "Compound"] + "Sphere"] } Row { diff --git a/scripts/system/edit.js b/scripts/system/edit.js index fbd1732b0b..390bd5beb3 100644 --- a/scripts/system/edit.js +++ b/scripts/system/edit.js @@ -339,7 +339,6 @@ var toolBar = (function () { var SHAPE_TYPE_STATIC_MESH = 3; var SHAPE_TYPE_BOX = 4; var SHAPE_TYPE_SPHERE = 5; - var SHAPE_TYPE_COMPOUND = 6; var DYNAMIC_DEFAULT = false; function handleNewModelDialogResult(result) { @@ -362,9 +361,6 @@ var toolBar = (function () { case SHAPE_TYPE_SPHERE: shapeType = "sphere"; break; - case SHAPE_TYPE_COMPOUND: - shapeType = "compound"; - break; default: shapeType = "none"; } @@ -464,7 +460,6 @@ var toolBar = (function () { SHAPE_TYPES[SHAPE_TYPE_STATIC_MESH] = "Exact - All polygons"; SHAPE_TYPES[SHAPE_TYPE_BOX] = "Box"; SHAPE_TYPES[SHAPE_TYPE_SPHERE] = "Sphere"; - SHAPE_TYPES[SHAPE_TYPE_COMPOUND] = "Compound"; var SHAPE_TYPE_DEFAULT = SHAPE_TYPE_STATIC_MESH; // tablet version of new-model dialog From 9c9cfad4c483ad8d626c2721ad8fb245ec76cfff Mon Sep 17 00:00:00 2001 From: Seth Alves Date: Wed, 26 Jul 2017 15:56:08 -0700 Subject: [PATCH 27/30] use ctrl rather than alt to activate camera-mode shortcuts --- interface/src/Menu.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/interface/src/Menu.cpp b/interface/src/Menu.cpp index 72a3eb6bfc..56bd3eb749 100644 --- a/interface/src/Menu.cpp +++ b/interface/src/Menu.cpp @@ -223,17 +223,17 @@ Menu::Menu() { // View > First Person cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash( - viewMenu, MenuOption::FirstPerson, Qt::ALT | Qt::Key_F, + viewMenu, MenuOption::FirstPerson, Qt::CTRL | Qt::Key_F, true, qApp, SLOT(cameraMenuChanged()))); // View > Third Person cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash( - viewMenu, MenuOption::ThirdPerson, Qt::ALT | Qt::Key_G, + viewMenu, MenuOption::ThirdPerson, Qt::CTRL | Qt::Key_G, false, qApp, SLOT(cameraMenuChanged()))); // View > Mirror cameraModeGroup->addAction(addCheckableActionToQMenuAndActionHash( - viewMenu, MenuOption::FullscreenMirror, Qt::ALT | Qt::Key_H, + viewMenu, MenuOption::FullscreenMirror, Qt::CTRL | Qt::Key_H, false, qApp, SLOT(cameraMenuChanged()))); // View > Independent [advanced] From c57660c82d3f17b8759f6dd3271d584c361f72f4 Mon Sep 17 00:00:00 2001 From: nimisha20 Date: Wed, 26 Jul 2017 16:52:00 -0700 Subject: [PATCH 28/30] Update BUILD_WIN.md --- BUILD_WIN.md | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/BUILD_WIN.md b/BUILD_WIN.md index 818a176f75..7587cf4512 100644 --- a/BUILD_WIN.md +++ b/BUILD_WIN.md @@ -1,20 +1,25 @@ This is a stand-alone guide for creating your first High Fidelity build for Windows 64-bit. ## Building High Fidelity +Note: We are now using Visual Studio 2017 and Qt 5.9.1. If you are upgrading from Visual Studio 2013 and Qt 5.6.2, do a clean uninstall of those versions before going through this guide. -### Step 1. Installing Visual Studio 2013 +Note: The prerequisites will require about 10 GB of space on your drive. -If you don't already have the Community or Professional edition of Visual Studio 2013, download and install [Visual Studio Community 2013](https://www.visualstudio.com/en-us/news/releasenotes/vs2013-community-vs). You do not need to install any of the optional components when going through the installer. +### Step 1. Visual Studio 2017 -Note: Newer versions of Visual Studio are not yet compatible. +If you don’t have Community or Professional edition of Visual Studio 2017, download [Visual Studio Community 2017](https://www.visualstudio.com/downloads/). + +When selecting components, check "Desktop development with C++." Also check "Windows 8.1 SDK and UCRT SDK" and "VC++ 2015.3 v140 toolset (x86,x64)" on the Summary toolbar on the right. In the end, your screen should look like this: ### Step 2. Installing CMake -Download and install the [CMake 3.8.0 win64-x64 Installer](https://cmake.org/files/v3.8/cmake-3.8.0-win64-x64.msi). Make sure "Add CMake to system PATH for all users" is checked when going through the installer. +Download and install the latest version of CMake 3.9. Download the file named win64-x64 Installer from the [CMake Website](https://cmake.org/download/). Make sure to check "Add CMake to system PATH for all users" when prompted during installation. ### Step 3. Installing Qt -Download and install the [Qt 5.6.2 for Windows 64-bit (VS 2013)](http://download.qt.io/official_releases/qt/5.6/5.6.2/qt-opensource-windows-x86-msvc2013_64-5.6.2.exe). +Download and install the [Qt Online Installer](https://www.qt.io/download-open-source/?hsCtaTracking=f977210e-de67-475f-a32b-65cec207fd03%7Cd62710cd-e1db-46aa-8d4d-2f1c1ffdacea). While installing, deselect components so that your window looks like this: + +Note: Installing the Sources is optional but recommended if you have room for them (~2GB). Keep the default components checked when going through the installer. From 081d8fbec442745aeb14acba95fa05e66bdfbc83 Mon Sep 17 00:00:00 2001 From: anshuman64 Date: Wed, 26 Jul 2017 17:00:48 -0700 Subject: [PATCH 29/30] More changes --- BUILD_WIN.md | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/BUILD_WIN.md b/BUILD_WIN.md index 7587cf4512..e9a4a5fd3b 100644 --- a/BUILD_WIN.md +++ b/BUILD_WIN.md @@ -9,7 +9,7 @@ Note: The prerequisites will require about 10 GB of space on your drive. If you don’t have Community or Professional edition of Visual Studio 2017, download [Visual Studio Community 2017](https://www.visualstudio.com/downloads/). -When selecting components, check "Desktop development with C++." Also check "Windows 8.1 SDK and UCRT SDK" and "VC++ 2015.3 v140 toolset (x86,x64)" on the Summary toolbar on the right. In the end, your screen should look like this: +When selecting components, check "Desktop development with C++." Also check "Windows 8.1 SDK and UCRT SDK" and "VC++ 2015.3 v140 toolset (x86,x64)" on the Summary toolbar on the right. ### Step 2. Installing CMake @@ -17,31 +17,29 @@ Download and install the latest version of CMake 3.9. Download the file named w ### Step 3. Installing Qt -Download and install the [Qt Online Installer](https://www.qt.io/download-open-source/?hsCtaTracking=f977210e-de67-475f-a32b-65cec207fd03%7Cd62710cd-e1db-46aa-8d4d-2f1c1ffdacea). While installing, deselect components so that your window looks like this: +Download and install the [Qt Online Installer](https://www.qt.io/download-open-source/?hsCtaTracking=f977210e-de67-475f-a32b-65cec207fd03%7Cd62710cd-e1db-46aa-8d4d-2f1c1ffdacea). While installing, you only need to have the following components checked under Qt 5.9.1: "msvc2017 64-bit", "Qt WebEngine", and "Qt Script (Deprecated)". Note: Installing the Sources is optional but recommended if you have room for them (~2GB). -Keep the default components checked when going through the installer. - ### Step 4. Setting Qt Environment Variable Go to `Control Panel > System > Advanced System Settings > Environment Variables > New...` (or search “Environment Variables” in Start Search). * Set "Variable name": `QT_CMAKE_PREFIX_PATH` -* Set "Variable value": `%QT_DIR%\5.6\msvc2013_64\lib\cmake` +* Set "Variable value": `C:\Qt\5.9.1\msvc2017_64\lib\cmake` ### Step 5. Installing OpenSSL -Download and install the [Win64 OpenSSL v1.0.2L Installer](https://slproweb.com/download/Win64OpenSSL-1_0_2L.exe). +Download and install the Win64 OpenSSL v1.0.2 Installer[https://slproweb.com/products/Win32OpenSSL.html]. ### Step 6. Running CMake to Generate Build Files Run Command Prompt from Start and run the following commands: -```` +``` cd "%HIFI_DIR%" mkdir build cd build -cmake .. -G "Visual Studio 12 Win64" -```` +cmake .. -G "Visual Studio 15 Win64" +``` Where `%HIFI_DIR%` is the directory for the highfidelity repository. @@ -87,4 +85,4 @@ If not, add the directory where nmake is located to the PATH environment variabl #### Qt is throwing an error -Make sure you have the correct version (5.6.2) installed and `QT_CMAKE_PREFIX_PATH` environment variable is set correctly. +Make sure you have the correct version (5.9.1) installed and `QT_CMAKE_PREFIX_PATH` environment variable is set correctly. From 560cccb0df94d61987395bf178cb7f69070b6366 Mon Sep 17 00:00:00 2001 From: anshuman64 Date: Wed, 26 Jul 2017 17:01:45 -0700 Subject: [PATCH 30/30] Remove nmake troubleshooting step --- BUILD_WIN.md | 8 -------- 1 file changed, 8 deletions(-) diff --git a/BUILD_WIN.md b/BUILD_WIN.md index e9a4a5fd3b..3e93656d45 100644 --- a/BUILD_WIN.md +++ b/BUILD_WIN.md @@ -75,14 +75,6 @@ For any problems after Step #6, first try this: Remove `CMakeCache.txt` found in the `%HIFI_DIR%\build` directory. -#### nmake cannot be found - -Make sure nmake.exe is located at the following path: - - C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin - -If not, add the directory where nmake is located to the PATH environment variable. - #### Qt is throwing an error Make sure you have the correct version (5.9.1) installed and `QT_CMAKE_PREFIX_PATH` environment variable is set correctly.