Commit graph

61006 commits

Author SHA1 Message Date
Stephen Birarda
a28f2f19e0 Merge pull request #11674 from utkarshgautamnyu/fix/JSBaker
Fixed issue with QTextStream in JSBaker
2017-10-25 14:06:43 -05:00
Andrew Meadows
2d0b94817c Merge pull request #11336 from 1P-Cusack/21389_PR2
WL21389 PR2: Representation of collision shapes need updating (details below).
2017-10-25 10:41:21 -07:00
Seth Alves
66e38af1b3 Merge pull request #11671 from ElderOrb/case8553
8380 Mouse Disappears when switching between HMD and Desktop Mode while in Create
2017-10-25 10:31:31 -07:00
Seth Alves
815f680475 Merge pull request #11675 from ZappoMan/fixRayPick
fix ray pick in cases where origin is inside of outer bounding box
2017-10-25 07:07:36 -07:00
Brad Hefta-Gaub
18a74cea91 Merge pull request #11659 from zfox23/mergeRC57IntoMaster_20171023
2017-10-23: Merge RC57 into Master
2017-10-24 21:19:01 -07:00
Brad Hefta-Gaub
bcad2302c4 Merge pull request #11667 from druiz17/crash-keyboard
Fix keyboard related crash.
2017-10-24 21:17:49 -07:00
Brad Hefta-Gaub
ef78711b7b Merge pull request #11663 from AndrewMeadows/shape-sharing
fix incorrect collision shape sharing for some ModelEntityItem configurations
2017-10-24 21:04:57 -07:00
Brad Hefta-Gaub
2a865f3a45 Merge pull request #11666 from SamGondelman/mirrorMode
Fix backwards HUD in mirror mode
2017-10-24 21:03:29 -07:00
ZappoMan
9b94f33304 fix ray pick in cases where origin is inside of outer bounding box 2017-10-24 20:48:59 -07:00
utkarshgautamnyu
ff0af9f5cc Fixed issue with QTextStream 2017-10-24 20:14:02 -07:00
Brad Hefta-Gaub
41b637bc79 Merge pull request #11668 from ZappoMan/cleanupVersions
Cleanup versions
2017-10-24 16:24:01 -07:00
beholder
39b2c0f83a fix for FB 8553 & FB 8380 2017-10-25 01:59:56 +03:00
Seth Alves
75f8699bcc Merge pull request #11665 from NissimHadar/hazeZone
Changed blend range from 32,000 m to 30,000m
2017-10-24 15:22:24 -07:00
ZappoMan
aad91edba2 actually remove all those defines 2017-10-24 14:45:33 -07:00
ZappoMan
3ded26b0e9 Merge branch 'master' of https://github.com/highfidelity/hifi into cleanupVersions 2017-10-24 14:44:06 -07:00
Brad Hefta-Gaub
ecf8d35f5f Merge pull request #11664 from ZappoMan/callEntityClientMethod
implement callEntityClientMethod
2017-10-24 14:43:39 -07:00
ZappoMan
275fff4609 more CR feedback 2017-10-24 14:02:47 -07:00
Dante Ruiz
f29937fb88 Merge branch 'master' of github.com:highfidelity/hifi into crash-keyboard 2017-10-24 13:54:21 -07:00
Dante Ruiz
92f765fe52 property set echomode for keyboard for wallet and webviews 2017-10-24 13:53:50 -07:00
ZappoMan
5901d1a311 clean up VERSION_ENTITIES stuff 2017-10-24 13:48:27 -07:00
SamGondelman
046e5ca716 fix backwards HUD in mirror mode 2017-10-24 13:24:09 -07:00
Andrew Meadows
27f4d182d9 fix scale of rendered collision geometry 2017-10-24 13:23:46 -07:00
Andrew Meadows
29efe53f74 repair debug rendering of collision shapes 2017-10-24 13:23:46 -07:00
Andrew Meadows
996b71fa9a avoid incorrect ShapeManager dupes for compound shapes 2017-10-24 13:23:46 -07:00
Nissim Hadar
f81675e3b4 Changed blend range from 32,000 m to 30,000m 2017-10-24 13:17:09 -07:00
ZappoMan
12c32d5834 bump protocol version 2017-10-24 13:08:48 -07:00
ZappoMan
ed408e09d0 remove some log spam 2017-10-24 11:50:25 -07:00
Sam Gateau
fad0dde550 Merge pull request #11662 from Zvork/zoneshadow
BUG FIX : Shadows cast by top zone key light
2017-10-24 11:49:53 -07:00
ZappoMan
a1885926b5 some cleanup 2017-10-24 11:46:42 -07:00
LaShonda Hopper
d1ab1c5e26 [WL21389] Fixes issue with the ShapeData vert buffer offset (details below).
When computing the buffer view offset for ShapeData the vertex vector
size should be scaled by a single vec3 size as opposed to 2.

This fix is taken from PR discussion:
 https://github.com/1P-Cusack/hifi/pull/10

 Proposed by: Andrew Meadows <andrew@highfidelity.io>

Changes Committed:
    modified:   libraries/render-utils/src/GeometryCache.cpp
2017-10-24 14:16:25 -04:00
LaShonda Hopper
226d51b8f5 [WL21389] Fix scaling issue when computing hull point list (details below).
The entity dimensions should be scaled by 1 as opposed to 0.5.

Changes Committed:
    modified:   interface/src/Util.cpp
    modified:   libraries/render-utils/src/GeometryCache.cpp
    modified:   libraries/render-utils/src/GeometryCache.h
2017-10-24 14:16:25 -04:00
LaShonda Hopper
d027993ac0 [WL21389] Address code review feedback (details below).
* Renamed squared var to be consistent with format of others in the code base.
* Removed fabsf() that was accidentally left in.
* Reduced squared distance filter within GeometryCache::computeSimpleHullPointListForShape
  as suggested from 0.0025f to recommended 1.0e-6f (1mm^2).

Feedback Link:  https://github.com/highfidelity/hifi/pull/11336#pullrequestreview-70060918

Changes Committed:
    modified:   libraries/render-utils/src/GeometryCache.cpp
2017-10-24 14:16:25 -04:00
LaShonda Hopper
070660eb04 [WL21389] Switch to _positionView & filter dupe verts for ShapeInfo (details below).
* Adjusts GeometryCache::computeSimpleHullPointListForShape to utilize
  ShapeData::_positionView as opposed to _normalView.
** Also filters out duplicate points or points close enough to be considered
   duplicate vertices.  This provides ShapeFactory with better point data
   and should reduce hits to the dedupe pass within createConvexHull.

Tested:
* Octagon & Tetrahedron
** They looked better than the prior commit, behaved closer to their shape as opposed
   to cone or narrow cylinder like.

Note:
* These changes are based on debug info observations using the Octagon and
  discussion with Andrew Meadows via Slack & https://github.com/highfidelity/hifi/pull/11336#pullrequestreview-69939120

Changes Committed:
    modified:   libraries/render-utils/src/GeometryCache.cpp
    modified:   libraries/render-utils/src/GeometryCache.h
2017-10-24 14:16:25 -04:00
LaShonda Hopper
d3e4d22ce1 [WL21389] Resolve ShapeInfo todos (details below).
* Added remaining cylinder/capsule shapes to computeVolume
* Point lists are generated during computeShapeInfo, so shouldn't
  need to be cleared within setParams.
** setSphere/setBox appear to be clear as they're used in tests or
   in local scopes without using point data.

Reviewed-by: Leander Hasty <leander@1stplayable.com>

Changes Committed:
    modified:   libraries/shared/src/ShapeInfo.cpp
2017-10-24 14:16:25 -04:00
LaShonda Hopper
5c8e73bb54 [WL21389] Minor: Fix size_t vs int comparison warning.
Changes Committed:
    modified:   libraries/shared/src/ShapeInfo.cpp
2017-10-24 14:16:24 -04:00
LaShonda Hopper
0ad95806e3 [WL21389] Update point list function in line with GeometryCache::ShapeData update.
Changes Committed:
    modified:   libraries/render-utils/src/GeometryCache.cpp
2017-10-24 14:16:24 -04:00
LaShonda Hopper
e74ebd53c6 [WL21389] Add SHAPE_TYPE_SIMPLE_HULL case to ShapeInfo::getHash (details below).
Generates hashes for Simple Hull instances by incorporating their
point list into the hash as opposed to the extents.

Reviewed-by: Leander Hasty <leander@1stplayable.com>

Changes Committed:
    modified:   libraries/shared/src/ShapeInfo.cpp
2017-10-24 14:16:24 -04:00
LaShonda Hopper
9d64a3b991 [WL21389] Fixes warnings from last commit (details below).
* Fixes int vs size_t comparison warning within ShapeInfo.
* Fixes unused var warning for shapeVerts local var within GeometryCache.

This should fix the mac & ubuntu builds.

Changes Committed:
    modified:   libraries/render-utils/src/GeometryCache.cpp
    modified:   libraries/shared/src/ShapeInfo.cpp
2017-10-24 14:16:24 -04:00
LaShonda Hopper
8cc20e6b71 Minor: Fixes comment typo.
Changes to be committed:
    modified:   libraries/physics/src/ObjectMotionState.h
2017-10-24 14:16:24 -04:00
LaShonda Hopper
a9fea4c7d3 [WL21389] Minor fix to RenderableShapeEntityItem::doRender (details below).
Shape isn't guaranteed to be permanent and thus the triangle count isn't
guaranteed to be the same since inception, so grab it each time.

Changes to be committed:
    modified:   libraries/entities-renderer/src/RenderableShapeEntityItem.cpp
2017-10-24 14:16:24 -04:00
LaShonda Hopper
dbd1a80046 [WL21389] Set Simulation::DIRTY_SHAPE flag when entity::Shape changes (details below).
* Fixes an issue where ShapeEntityItem's collisionShapeType wasn't updated when its
  entity::Shape type was changed.
* Adds getNameForShapeType static method to ShapeInfo.
** Moves shapeTypeNames[] from EntityItemProperties.cpp to ShapeInfo.cpp
* Adds collisionShapeType to ShapeEntityItem::debugDump

* Tested creating shapes within the Creation Menu:
** Create Menu -> (Box/Sphere)
*** Observe Properties tab auto-focus
** From Properties tab elect alternate shape type from the Shape Dropdown list.

NOTE:  While this fixes an issue with the collision shape, it doesn't completely
       resolve the issues seen with the polyhedra or polygonal shapes noticed on
       RELEASE-7130 rebase.

Reviewed-by: Leander Hasty <leander@1stplayable.com>

Changes Committed:
    modified:   libraries/entities/src/EntityItemProperties.cpp
    modified:   libraries/entities/src/ShapeEntityItem.cpp
    modified:   libraries/shared/src/ShapeInfo.cpp
    modified:   libraries/shared/src/ShapeInfo.h
2017-10-24 14:16:24 -04:00
LaShonda Hopper
7f9ce5a4cd [WL21389][BuildFix] Minor refactor due to render-utils lib change (details below).
As of Commit b93e91b9, render-utils no longer knows about entity lib.
This commit adjusts for that by altering the signature of
GeometryCache::computeSimpleHullPointListForShape to take in portions
of ShapeEntityItem data as opposed to the entity pointer.

Fixes build failure mentioned in:
 https://github.com/highfidelity/hifi/pull/11336#issuecomment-333635794

Reviewed-by: Leander Hasty <leander@1stplayable.com>

Changes Committed:
	modified:   interface/src/Util.cpp
	modified:   libraries/render-utils/src/GeometryCache.cpp
	modified:   libraries/render-utils/src/GeometryCache.h
2017-10-24 14:16:23 -04:00
LaShonda Hopper
789b850846 [WL21389] Addresses feedback from PR #11336.
* Removes todos from ShapeEntityItem::shapeCalculator stub commit.
* Removes defined out debugging, as requested, from GeometryCache::computeSimpleHullPointListForShape.
* Moves cone handling to its own section for better contextual flow.

Changes Committed:
	modified:   libraries/entities/src/ShapeEntityItem.cpp
	modified:   libraries/render-utils/src/GeometryCache.cpp
2017-10-24 14:16:23 -04:00
LaShonda Hopper
8a4ac9ebc4 [WL21389] Resolves size_t vs int warnings in GeometryCache.
Reviewed-by: Kris Pivin <krispivin@1stplayable.com>

Changes Committed:
	modified:   libraries/render-utils/src/GeometryCache.cpp
2017-10-24 14:16:23 -04:00
LaShonda Hopper
070c664ff2 [WL21389] Add out of bounds safeguard to computeShapeInfo helper (details below).
* Switched direct map indexing to helper function which has out of bounds safeguard.
* Also updated GeometryCache::getShapeForEntityShape default fallback return from
  GeometryCache::NUM_SHAPES to GeometryCache::Sphere inline with general preference
  to act as if a shape is a sphere in the event of an error.

Changes Committed:
	modified:   libraries/render-utils/src/GeometryCache.cpp
2017-10-24 14:16:23 -04:00
LaShonda Hopper
d2350974b5 [WL21389] Avoid vector copy within shapeInfoCalculator.
Reviewed-by: Leander Hasty <leander@1stplayable.com>

Changes Committed:
	modified:   interface/src/Util.cpp
2017-10-24 14:16:23 -04:00
LaShonda Hopper
5b50b362f1 [WL21389] WL21389 PR2: Representation of collision shapes need updating (details below).
This commit adds support for the polyhedrons and polygons sans
Torus and Quad which aren't currently supported within GeometryCache.

* Moves GeometryCache::_shapes from public to private scope
    * Nothing aside from the class should be directly altering this, only querying
    * Updated instances of direct referencing which looks to have been limited to prior
      testing of instancing and shapes.
* Adds an accessor function for ShapeData to GeometryCache
* Consolidates point list generation to helper function
    * GeometryCache::computeSimpleHullPointListForShape
* Moves GeometryCache::Shape to entity::Shape mapping to GeometryCache from
  RenderableShapeEntityItem
    * Adds conversion accessor to GeometryCache, GeometryCache::Shape getShapeForEntityShape
* Sets ShapeEntityItem::ShapeInfoCalculator callback committed earlier.
    * This helps circumvent the issue with library inclusion.  entity-render knows about
      entity; however, entity doesn't know about entity-renderer; however, GeometryCache
      data is needed within entity::ShapeEntityItem to compose the ShapeInfo point list data.
    * This callback is set up within Application::init of the Interface as it knows about
      both halves of the equation, and the callback needs to be setup prior to any entities
      collision data getting generated.
* Removes _type reset within ShapeInfo::setPointCollection
    * This should avoid any issues due to subversively setting the type or
      incorrectly setting the type as a tangential operation.
        * Audited instances of ShapeInfo::setPointCollection and all seemed to be
          calling the function immediately after having set the type via
          ShapeInfo::setParams
* Adds new ShapeType: SHAPE_TYPE_CIRCLE
    * This type is reserved for the circle which is now treated as a special
      type of Cylinder_Y with regard to collision as opposed to a simple hull.
    * Fixes the issue where jumping on a circle, at times, would
      result in the avatar sliding off towards an edge as if atop a
      squished cone.
* Also updates ShapeInfo::getType() to return ShapeType as opposed to int
    * Auditing calls showed that majority of places were comparing against ShapeType
    * ShapeType::_type is a ShapeType so returning the type explicitly
      is more consistent.
        * ShapeInfo file houses ShapeType enum so any file aware of ShapeInfo is aware of
          ShapeType enumeration.
* entity::Quad defaults to SHAPE_TYPE_ELLIPSOID
    * Like entity::Shape::Torus, entity::Shape::Quad is currently unsupported within
      GeometryCache::buildShapes.
    * Also it appears that a Quad shape can't be created within world via the creation menu.
        * There's no explicit option at present to create one.
        * Trying subvert the Cube/Box creation option to generate one results in an enforced
          stubby box as opposed to a quad.
    * Given the aforementioned points, entity::Shape::Quad will default to
      SHAPE_TYPE_ELLIPSOID as opposed to SHAPE_TYPE_BOX.
        * Added Todo regarding the shape being unsupported along with a notation to create
          a special ShapeType, SHAPE_TYPE_QUAD, for it should it be added in the future.
* Adds some comments and has some minor clean up.

Reviewed-by: Leander Hasty <leander@1stplayable.com>

Changes Committed:
	modified:   interface/src/Application.cpp
	modified:   interface/src/Util.cpp
	modified:   interface/src/Util.h
	modified:   libraries/entities-renderer/src/RenderableShapeEntityItem.cpp
	modified:   libraries/entities/src/ShapeEntityItem.cpp
	modified:   libraries/entities/src/ShapeEntityItem.h
	modified:   libraries/physics/src/ShapeFactory.cpp
	modified:   libraries/render-utils/src/GeometryCache.cpp
	modified:   libraries/render-utils/src/GeometryCache.h
	modified:   libraries/shared/src/ShapeInfo.cpp
	modified:   libraries/shared/src/ShapeInfo.h
	modified:   tests/gpu-test/src/TestInstancedShapes.cpp
2017-10-24 14:16:17 -04:00
ZappoMan
1128a98e88 implement callEntityClientMethod 2017-10-24 11:15:57 -07:00
Andrew Meadows
9981a44b71 add hook for ShapeInfo calculator 2017-10-24 14:15:08 -04:00
Seth Alves
58501bd0b0 Merge pull request #11661 from Delanir/Gizmos
FogBugz 7425 - Billboard orientation and grabber move up tool are now dependent on the Avatar referential.
2017-10-24 10:32:29 -07:00