Commit graph

261 commits

Author SHA1 Message Date
Sam Gateau
e2fce12713 Splitting the FBXREader.cpp file into sub files 2015-08-28 09:51:03 -07:00
Sam Gateau
4f7b857130 Merge 2015-08-27 10:01:39 -07:00
Sam Gateau
f6953f8e02 REfining th eTextureMap design but still with the issue of the lightmapped model 2015-08-27 09:52:07 -07:00
Anthony J. Thibault
46c1e008bc Merge branch 'master' into ajt/new-anim-system 2015-08-26 10:37:39 -07:00
Sam Gateau
1e9fce2a61 Drafting the materials for FBXReader 2015-08-25 22:12:51 -07:00
Brad Davis
d311e4f2ea Fixing problems reported by static analysis tool 2015-08-25 19:18:55 -07:00
Anthony J. Thibault
5a73aef1f8 AnimSkeleton more accurate bind pose generation. 2015-08-24 16:19:16 -07:00
Anthony J. Thibault
fa5256eefd Merge branch 'master' into ajt/new-anim-system 2015-08-24 14:32:28 -07:00
Anthony J. Thibault
1b3d7fabc8 ResourceCache, NetworkGeometry and Model refactoring and optimizations.
* Removed validation logic from Resource class, Qt does this internally and is more
  standards compliant.  This should result in more accurate caching and faster resource
  fetching when cache is stale and validation fails.
* Added loaded and failed slots to Resource class, so it does not have to be polled.

* NetworkGeometry now uses multiple Resource objects to download
  the fst/mapping file and the fbx/obj models.
* NetworkGeometry is no longer a subclass of Resource
* NetworkGeometry now has signals for success and failure, you no longer
  have to poll it to determine when loading is complete (except for textures *sigh*)

Some functionality was removed

* NetworkGeometry no longer has a fallback
* NetworkGeometry no longer loads LODs or has lod logic.
* The number of FBXGeometry copies is greatly reduced.

* Model::setURL no supports fallback URL, delayLoad or retainCurrent option.
  This can result in a pop when switching avatars, and there's no longer a default
  if avatar loading fails.
2015-08-20 18:59:51 -07:00
Seth Alves
1c8030472a back out the more controversial changes 2015-08-17 12:40:56 -07:00
Seth Alves
d6322903a2 quiet compiler 2015-08-11 10:12:46 -07:00
Sam Gateau
561a058dc8 cleaning th ecode 2015-08-06 18:53:21 -07:00
Sam Gateau
f0f141a2b4 SImple fix to the case of multiple material in a mesh with different opacity 2015-08-06 18:51:44 -07:00
Anthony J. Thibault
da3d35cdfc Added scaleOffset to FBXJoint::postTransform as it was missing.
Also added some documentation/comments to the FBXJoint struct.
2015-08-04 18:14:50 -07:00
Andrew Meadows
b00d47d62e merge master into cleanup of legacy shapes 2015-08-03 11:19:29 -07:00
Andrew Meadows
acfc907704 Merge pull request #5438 from howard-stearns/rig
Rig: Bottleneck animation management through a Rig class
2015-08-03 11:14:21 -07:00
ZappoMan
05a4a6aa9b implement on-the-fly conversion of FBXMeshParts that are quads, into their triangle equivalents 2015-08-01 13:07:56 -07:00
Andrew Meadows
661a916ebd merge rig into cleanup (removal of legacy shapes)
Conflicts:
	interface/src/avatar/Avatar.h
	tests/physics/src/ShapeColliderTests.cpp
	tests/physics/src/ShapeColliderTests.h
2015-07-31 13:40:51 -07:00
Howard Stearns
06aa107762 Merge branch 'master' of https://github.com/highfidelity/hifi into rig 2015-07-30 09:57:02 -07:00
Brad Hefta-Gaub
b95e4e1e93 Merge pull request #5323 from MarcelEdward/20605
Removed the  line where the directory is stripped off the RelativeFile
2015-07-30 07:30:01 -07:00
Marcel Verhagen
fa6d6a5123 Added the & references to the const variables 2015-07-30 15:08:02 +02:00
Andrew Meadows
c7f367bfd7 removing unnecessary #include <Shape.h> 2015-07-27 15:30:37 -07:00
Howard Stearns
1ec0518d05 Merge branch 'master' of https://github.com/highfidelity/hifi into rig 2015-07-27 09:20:30 -07:00
Marcel Verhagen
d25e09af74 removed the last 2 filename lines, they should not be there. 2015-07-26 00:48:31 +02:00
Andrew Meadows
6657026a12 remove cruft: legacy shapes for skeleton bones 2015-07-23 08:34:44 -07:00
Marcel Verhagen
8f0893ba21 Added fileOnUrl to check if a texture exist at the location. It return the correct filename of where the texture lives.
Added the url of the fix file to extractFBXGeometry and readFBX and updated the calls to readFBX to include the url of the fix file.

So it now does not break existing content.

Found a second place in the FBXReader.cpp where the RelativeFileName stripped out the dir location.
2015-07-22 22:34:45 +02:00
David Rowe
55683e0cd5 Size looking-at-me eye spheres per avatar model dimensions 2015-07-21 18:24:47 -07:00
Marcel Verhagen
fac497dadc Removed the file where the directory is stripped off the RelativeFilename, and replace \ with /.
However this introduces a new problem with the current fbx files who do not have their textures in the original dir but moved it to the dir where the fbx file lives.

Suppose there should be some logic when the texture is not found to look if the texture lives in the dir above the RelativeFilename.
In any case it is not obvious when there is a texture missing on a model, it simply renders black.
2015-07-14 15:31:56 +02:00
Atlante45
7b5a5a339a Use make_shared/create to make shared pointers 2015-07-01 19:46:06 -07:00
Sam Gateau
b0f5990bd7 fix syntax 2015-06-19 17:13:29 +02:00
Sam Gateau
b09991d75b Merge branch 'master' of https://github.com/highfidelity/hifi into daft 2015-06-19 09:35:40 +02:00
Seth Alves
508ae276c6 enable -Wdouble-promotion 2015-06-16 18:23:10 -07:00
Sam Gateau
9be87758fd Improving the design of the Jobs and varying 2015-06-16 15:00:47 +02:00
ZappoMan
aa05d9f67c Merge branch 'master' of https://github.com/highfidelity/hifi into fix-attachments 2015-06-10 08:53:33 -07:00
ZappoMan
ba0cecb356 remove attachments from Model - only supported at avatar layer 2015-06-09 12:32:37 -07:00
Sam Gateau
7de4c2eff7 first take on the materialKey 2015-06-09 12:17:10 -07:00
Seth Alves
1e2e4001b1 don't allow buildModelMesh to spam logs when it encounters flawed models 2015-05-14 10:24:02 -07:00
Seth Alves
0db5ddc5b7 port code from samcake's model branch 2015-05-13 15:43:16 -07:00
Sam Gateau
73177cd81d Merge branch 'master' of https://github.com/highfidelity/hifi into blue 2015-05-04 14:07:59 -07:00
Sam Gateau
ade404a74d getting rid of QSHaredPointer in favor of std::shared_ptr 2015-05-04 13:43:30 -07:00
Stephen Birarda
6cff75f7c1 resolve conflicts on merge with upstream/master 2015-05-04 10:05:44 -07:00
Sam Gateau
1b558e7390 investigating the semi transparent textured bug 2015-05-01 13:37:04 -07:00
Stephen Birarda
94739cf8d3 move number constants out of SharedUtil to NumericalConstants 2015-05-01 10:26:53 -07:00
Seth Alves
0fb1a83e3b quiet compiler, remove some trailing control-Ms 2015-04-25 09:20:00 -07:00
Atlante45
bda72025af Check mesh extend before going through triangles 2015-04-23 16:40:40 +02:00
Atlante45
99b3ef0d75 Move contain function to FBXGeometry 2015-04-22 21:17:12 +02:00
Sam Gateau
f06556ba12 migrate the various list to sort the rendering from explicit names to a more generic key based map 2015-04-16 14:37:39 -07:00
Sam Gateau
f0efade06d Merge branch 'master' of https://github.com/highfidelity/hifi into orange 2015-04-07 12:56:21 -07:00
Sam Gateau
dee651069c adding support for color attribute in FBX, and displaying it correctly 2015-04-06 23:33:13 -07:00
Seth Alves
8bd77fbcc7 separate out logging for fbx and gpu libraries 2015-04-06 16:52:31 -07:00
Seth Alves
420424a5ee make it possible to sort meshes into the same order they appear in the model file 2015-04-01 17:49:49 -07:00
Atlante45
716e9bfe4f Hint order for FST files 2015-03-26 15:40:48 +01:00
Seth Alves
0833fc588b coding standard 2015-03-09 06:56:35 -07:00
ZappoMan
ffab6ffe48 tweaks to hacks for detecting mixamo files 2015-03-06 15:11:02 -08:00
Brad Hefta-Gaub
1827d9f3cd Merge pull request #4256 from samcake/temp1
Getting rid of glLIghts and replacing by the model::Light
2015-02-13 10:49:53 -08:00
Andrew Meadows
123d73783b remove warning about unused variable 2015-02-11 08:42:36 -08:00
Andrew Meadows
e6a6946027 merge upstream/master into andrew/thermonuclear 2015-02-09 12:44:52 -08:00
Sam Gateau
ace6dc4faf Merge branch 'master' of https://github.com/highfidelity/hifi into temp1 2015-02-08 23:23:06 -08:00
Brad Hefta-Gaub
12ab841191 Merge pull request #4248 from samcake/temp0
Remove unneeded texture memory once loaded to GPU and Lightmap control in FBX
2015-02-06 16:52:40 -08:00
Sam Gateau
469ee29f0b Merge branch 'temp0' of https://github.com/samcake/hifi into temp1 2015-02-06 16:30:47 -08:00
Sam Gateau
d4566bb1d7 Adding support for hifi_global light intensity & COlor and use it to adjust the lighmap parameters 2015-02-06 15:51:57 -08:00
Stephen Birarda
11f3161029 resolve conflicts on merge with upstream/master 2015-02-04 10:38:05 -08:00
Sam Gateau
6ad484e13f Merge branch 'master' of https://github.com/highfidelity/hifi into temp1 2015-02-03 17:26:27 -08:00
Sam Gateau
5719e277dd FIx the lightmap not displaying when using the texcoord0 2015-02-03 16:10:31 -08:00
Sam Gateau
d8d0a28d0f FInd a solution for lightmap without 2nd uvset 2015-02-03 14:34:11 -08:00
Andrew Meadows
28a3c3f469 separate new shape types from legacy 2015-02-03 08:34:06 -08:00
Atlante45
bbf6ae7b01 Move Faceshift constants to their own file in shared 2015-01-23 12:11:08 -08:00
Sam Gateau
49dde269a6 experimenting with linear space vs srgb space 2015-01-22 16:27:17 -08:00
Sam Gateau
1e84f260a9 Removing gl calls for texture from TextureCache 2015-01-21 16:53:35 -08:00
Brad Hefta-Gaub
b3b43b4c14 Merge pull request #4093 from samcake/temp0
Factorize the shader code for deferred lighting
2015-01-13 17:11:17 -08:00
Sam Gateau
e639c5a549 playing with the ambient lighting 2015-01-11 11:33:21 -08:00
chris
8bb69d0a90 Update std::string instances to QString 2015-01-09 16:22:52 -08:00
ZappoMan
4ea9bbc309 first major pass at voxelEctomy 2014-12-30 18:08:58 -08:00
Andrzej Kapolka
d402f767c1 Merge branch 'master' of https://github.com/highfidelity/hifi 2014-12-10 15:23:27 -08:00
Andrzej Kapolka
c57fd15bc9 Rather than loading the entire FBX file into a byte array, read it straight
from the QNetworkReply.
2014-12-10 15:22:48 -08:00
Sam Gateau
8617c319d4 Merge branch 'master' of https://github.com/highfidelity/hifi into tot 2014-12-09 17:30:26 -08:00
ZappoMan
a6b86da47a basics of triangle picking working for models 2014-12-05 11:31:27 -08:00
Sam Gateau
5bca90163f Merge branch 'master' of https://github.com/highfidelity/hifi into tot 2014-12-05 10:12:21 -08:00
Sam Gateau
563cd6f7e3 watch your language... 2014-12-05 10:10:21 -08:00
Philip Rosedale
0ad361fd60 Merge pull request #3902 from samcake/tot
Adding detection of a "hifi" global light in a FBX file used to pass information
2014-12-05 10:07:52 -08:00
Andrzej Kapolka
466d99bcbb Removed unused members. 2014-12-04 17:12:06 -08:00
Sam Gateau
4168993ebe Replace c++11 usage of auto by explicit declaration 2014-12-04 14:23:47 -08:00
Sam Gateau
3215957398 better interpretation of the hifi light intensity and fixes for compilation on mac 2014-12-04 12:31:40 -08:00
Sam Gateau
30d87ee026 Trying to capture light information in order to get the one GLobal Light object containg the intensity value 2014-12-04 00:24:08 -08:00
Sam Gateau
913007939b Trying to read the light attribute 2014-12-03 14:12:50 -08:00
Sam Gateau
1aec214138 gabbing the AnbientCOlor value, we will use it as the lighmap global level 2014-12-02 16:23:09 -08:00
Sam Gateau
845e687fc5 Adding a Hack for the apaartment model to boost the lightmaps 2014-12-01 11:45:07 -08:00
Sam Gateau
321d651d77 Hack for avoiding lightmaps loading in starchamber 2014-11-30 12:54:43 -08:00
Sam Gateau
77077f4e9c hack a separate emissive information in the g-buffer 2014-11-25 18:17:28 -08:00
dev
ce103acdf6 More debugging of the FBXReader in order to understand how to interpret the material fields 2014-11-24 18:32:36 -08:00
Sam Gateau
6a63099a0f Fixed syntax issues and review critics, put all the debugging code in a #define block 2014-11-24 15:24:20 -08:00
Sam Gateau
87471df7a1 First version of the lighmap working 2014-11-21 18:08:34 -08:00
Sam Gateau
7daff18101 Merge branch 'master' of https://github.com/highfidelity/hifi into tot 2014-11-20 09:57:59 -08:00
Sam Gateau
764ad72471 adding the light map support from FBX 2014-11-20 09:54:41 -08:00
Atlante45
4d5451fafe Merge branch 'master' of https://github.com/highfidelity/hifi into death_to_dot_f
Conflicts:
	interface/src/avatar/Avatar.cpp
	interface/src/avatar/SkeletonModel.cpp
2014-11-19 17:28:24 -08:00
Atlante45
ae3bcc8f06 No more .f 2014-11-19 16:53:39 -08:00
Andrew Meadows
7f4e0c206c cache indeces to toe joints 2014-11-19 09:13:03 -08:00
Andrzej Kapolka
14eb87aefd Eliminate wacky scales in favor of newfangled "meters." 2014-11-14 12:23:47 -08:00
ZappoMan
c3d1d13fa9 Merge branch 'master' of https://github.com/highfidelity/hifi into rayPickSubMeshes 2014-10-29 11:56:27 -07:00
ZappoMan
6b1dc67883 some cleanup 2014-10-29 08:17:30 -07:00
ZappoMan
a73cad91bc first cut at reading and mapping submeshes to named models 2014-10-29 08:09:10 -07:00
Andrew Meadows
4c3cdf5b7a move stuff out of shared and into physics library 2014-10-28 13:51:45 -07:00
Stephen Birarda
047ee0a513 pipe texture names through to NetworkTexture 2014-10-21 12:20:12 -07:00
AndrewMeadows
2569f70ac3 Merge pull request #3623 from ey6es/master
For FBX files with marked "skeleton" joints, only show those marked nodes in the upload dialog.  Also added some more default node names to look for on upload.
2014-10-20 09:00:06 -07:00
Andrzej Kapolka
c979ace924 Read the unit scale factor and include it in the offset scale. 2014-10-17 17:34:27 -07:00
Andrzej Kapolka
1b9b0f9fc9 Look for and store the "Skeleton" type flag so that we can offer only skeleton
joints in the dropdown.
2014-10-17 16:51:55 -07:00
ZappoMan
e29188bacd fix SVOs to render again 2014-10-17 11:01:25 -07:00
ZappoMan
d1f263ecc5 group materials together when rendering models 2014-10-16 14:05:35 -07:00
Andrzej Kapolka
6c907a9d83 Read the emissive color property and use it to effect glow. 2014-09-19 16:49:51 -07:00
Andrzej Kapolka
37eb40122c Tiny tweak to weight loading: only replace lowest weight if the new weight is
greater.
2014-09-18 13:05:57 -07:00
Andrzej Kapolka
801630e19c Normalize vertex weights if they don't add up to one; replace lowest weight
if we can't find an empty slot.
2014-09-17 13:26:57 -07:00
Andrzej Kapolka
213b4e6ee6 Removed testing code. 2014-09-16 17:53:40 -07:00
Andrzej Kapolka
fbd1efad81 Allow specifying material opacity. 2014-09-16 17:52:39 -07:00
ZappoMan
7db2930d91 remove calls to calculateRotatedExtents() use Extents.rotate() instead 2014-09-11 12:33:38 -07:00
ZappoMan
f88970f8fe moved Extents to shared 2014-09-11 12:32:47 -07:00
ZappoMan
e6fc9d68ff add getUnscaledMeshExtents to FBXGeometry 2014-09-09 17:51:35 -07:00
ZappoMan
1e6b49899a allow FBXReader to parse new format SVO files 2014-09-05 15:12:41 -07:00
Andrew Meadows
3ebd8c1969 use dispatchTable for shape-vs-shape collisions 2014-08-21 16:40:25 -07:00
Stephen Birarda
31488e72fe repairs for interface build to succeed 2014-08-08 13:17:53 -07:00
barnold1953
aba031a125 Proper blendshape JS api. 2014-07-23 16:25:45 -07:00
Andrew Meadows
b21bac25a1 bug fix for broken seams in models
don't hijack the "weight" variable because it's used elsewhere
2014-07-21 13:41:41 -07:00
Andrew Meadows
58e31abf60 improved collision shapes for fingers 2014-07-17 14:31:16 -07:00
Andrew Meadows
53ee5f2340 minor cleanup around measurements of joint radius 2014-07-17 12:42:18 -07:00
Atlante45
c660986480 Merge branch 'master' of https://github.com/highfidelity/hifi into sit_on_a_model 2014-06-25 10:49:51 -07:00
Atlante45
9a6f144da9 Added sitting points metadata for fst 2014-06-24 18:21:57 -07:00
Andrew Meadows
d892a9c00f fixed warning about possible uninitialized variable. 2014-06-23 14:07:31 -07:00
Andrzej Kapolka
a1e208ae3d Simplification. If the normal is zero, then the cross product will also be
zero, so we can just have the one check and postpone normalization until
afterwards.
2014-06-09 11:03:50 -07:00
Andrzej Kapolka
6eac0ee2ae Avoid crash on zero-length normals. 2014-06-09 10:58:56 -07:00
ZappoMan
8ec14568fe support ray picking against the AABB for the rotated model extents 2014-05-27 13:39:32 -07:00
ZappoMan
9188b9ac59 add meshExtents to sub meshes 2014-05-23 09:56:09 -07:00
Andrzej Kapolka
906e082215 If there are no animation frames in the model, treat its default position as
a single frame.
2014-05-21 13:56:20 -07:00
Brad Hefta-Gaub
b4759e02f4 Merge pull request #2888 from Barnold1953/master
Windows audio and mesh crash
2014-05-21 11:01:48 -07:00
barnold1953
661de7c62b Fixed poor coding standard 2014-05-20 17:46:52 -07:00
barnold1953
eccf99c175 Stopped windows crash when FBXMeshPart::triangleIndices.size() is not
divisible by three. There is probably an issue in extractMesh()
2014-05-20 16:20:29 -07:00
ZappoMan
1278470a91 properly handle FSTs that have translations and rotations 2014-05-20 13:31:08 -07:00
Andrzej Kapolka
e415006526 Fixed index of out bounds error, issue with head not being tracked in
PrioVR.
2014-05-15 18:22:57 -07:00
Philip Rosedale
186f7766fc Merge pull request #2856 from ZappoMan/modelserver
Animation Support in Models
2014-05-14 15:03:49 -07:00
Andrzej Kapolka
bca5636f9b Looks like "reflection" can be used as a synonym for "specular." 2014-05-13 15:05:00 -07:00
Andrzej Kapolka
0321821b55 More work on PrioVR integration. 2014-05-13 11:38:24 -07:00
ZappoMan
106c8bffd8 first cut at animations in models 2014-05-09 16:08:06 -07:00
Andrzej Kapolka
03faff359f Fix for certain models with textures not parented to materials. 2014-05-07 14:48:25 -07:00
Andrzej Kapolka
d0537e7ead Specular map support. 2014-05-06 17:32:10 -07:00
Andrzej Kapolka
353b9879b8 Fix for exports from Sketchup. 2014-05-06 15:15:42 -07:00
Andrzej Kapolka
9e6b29951d Whoops! 2014-05-02 19:14:40 -07:00
Andrzej Kapolka
9959d8d73f OK, this time for sure. 2014-05-02 19:06:44 -07:00
Andrzej Kapolka
8ec03979da OK, one more try. 2014-05-02 18:14:17 -07:00
Andrzej Kapolka
3e8b5c8714 Let's try that again. 2014-05-02 18:03:54 -07:00
Andrzej Kapolka
0c8b3eaf1a Yet another check. 2014-05-02 17:56:23 -07:00
Andrzej Kapolka
a1eeef3feb Out-of-bounds check. 2014-05-02 17:52:52 -07:00
Andrzej Kapolka
c08dfc90c3 Add a hack to fix normals on Makehuman exports. 2014-05-02 17:46:11 -07:00