Commit Graph

57 Commits (acb33ab5bf71401dd30af67e7323e53fbf5a1501)

Author SHA1 Message Date
Jeremy Hu 39cfe6537d Speed up document saving
If there are images need to be saved, such as the model turnaround reference sheet and texture images, the document saving may be slow because of image encoding to png, now, all the images are pre encoded when the first load, so the document saving could be speed up by avoid the cost of image encoding.
2018-11-11 21:08:13 +08:00
Jeremy Hu 70f075a36e Rewrite pose editor
This commit include lots of changes for pose editor.
Before, we use buttons to represent the transform controller for bones;
Now, we use nodes and edges to represent the bones, just like the nodes and edges for representing the guide spheres for mesh generating. There are advantages by doing this. Firstly, The edit UI for both mesh and pose are unified, secondly, it is possible to set a reference sheet for pose editing now, this is very important.
This new pose editor is inspired by the Eadweard Muybridge's work.
2018-11-05 23:47:21 +08:00
Jeremy Hu a4aefdd308 Make a abstract class for document: SkeletonDocument
This is mainly for reusing the SkeletonGraphicsEditWidget for other purpose, such as the new pose editor.
2018-11-03 16:09:42 +08:00
Jeremy Hu 208d2a0166 Cleanup
Many source file name and data type are prefixed by "skeleton" before, now all are refactored.
The class MeshResultContext represents the outcome of mesh generation before, now we have material, pose and animation, so we just rename it as Outcome.
2018-10-25 08:19:38 +08:00
Jeremy Hu d663876c5c Rewrite the motion manager
Curve editor has been removed from this commit.
Instead of let user edit customized curve for motion, we provider presets. It's much more easy to add motion than before.
2018-10-23 22:57:47 +08:00
Jeremy Hu eeff771a3b Optimize texture generating time 2018-10-09 21:01:04 +08:00
Jeremy Hu 5f2a46be9c Avoid unnecessary mesh regeneration while only texture map changed 2018-10-09 17:17:44 +08:00
Jeremy Hu 7eb5a325a0 Add MetalicRoughness material manager
Besides adding the PBR material manager, this commit hide some unnecessary features such as toggle wireframes and toggle normal smooth.
Add a regenerate button to indicate mesh is generating by showing a spiner, user can click this button to regenerate if the final result is not good.
Please note that, we generate the texture map by default compared to before we only generate texture map when user export glTF result. Current uvunwrap library cann't handle bad mesh very well, so it will crash on the wires model.
2018-10-09 10:19:12 +08:00
Jeremy Hu f7b5fb1c6a Add PBR support
Now can configure metalness and roughness for parts, however, the PBR render isn't enabled in the code currently.
2018-10-04 20:51:01 +08:00
Jeremy Hu ee92472027 Add motion manager
Added motions tab, hermite curve editor, quaternion overshoot blend and so on.
2018-10-02 12:59:30 +08:00
Jeremy Hu d6b38f5750 Fix part cache not update when add new node 2018-09-23 10:41:47 +08:00
Jeremy Hu 6ffbdc9c7b Add mesh seam combine algorithm
Not enable by default, should enable the weldEnabled in the SkeletonDocument class.
2018-09-22 18:31:02 +08:00
Jeremy Hu e22a6de6cb Add poses list view
Added Add, modify, delete, copy, and paste poses. The paste menu for nodes not show up also got fixed in this commit.
2018-09-21 15:10:18 +08:00
Jeremy Hu 1ab3d16bd4 Fix parts render crash
Before, app crash on some machines as been reported in #15 and #16, and cannot easily be reproduced on other machines, such as a virtual box guest system, which make it very hard to trace the root cause.
Now, the offline render is totally removed from the code base, instead of offline-render to image then show the image, we can directly show the parts model in the parts tree using normal opengl widget, and the result looks better than before.
2018-09-18 14:22:29 +08:00
Jeremy Hu c64743f2f2 Fix rig skinning weights, add pose configure UI. 2018-09-18 11:17:35 +08:00
Jeremy Hu 48bc8df5c3 Add auto-rig
This is the second version of auto-rig, differing from the first version, the user should pick up a rig type, unless no rig will be generated. Currently, only supports Tetrapod without tail. Export as glTF format to test this feature.

This commit also achive better quality quads than before.
2018-09-14 17:45:05 +08:00
Jeremy Hu a9b379a77a Add radius lock 2018-09-08 12:20:31 +08:00
Jeremy Hu 1988118179 Add smooth shading toggle 2018-09-07 20:51:33 +08:00
Jeremy Hu 94d63237e7 Add multiple select on parts tree 2018-09-07 18:13:55 +08:00
Jeremy Hu 3c2d4f7480 Add mesh smooth slider
This feature could be useful for smooth one component and soften the seam of combination,
This commit also include a crash fix about incorrect use of CGAL.
2018-09-06 23:04:59 +08:00
Jeremy Hu 9a3dfb8ff2 Add view rotation 2018-09-03 15:05:05 +08:00
Jeremy Hu df9c8e8e3c Add wrap button to enable use controlled convex hull generation for part.
This feature could be useful to generate complex mesh as part.
2018-08-31 12:54:32 +08:00
Jeremy Hu 623dda6ecf Replace parts list with parts tree and remove immature features 2018-08-27 16:50:40 +08:00
Jeremy Hu 51bf40de01 Add rotate along single node.
If multiple nodes or end effector node been selected and rotate, the behaves remain the same as before, however, if single node in the middle been selected and rotated, all the children of this node will be rotated. This could be useful to rotate the tail or leg from joint.
2018-06-29 14:55:32 +08:00
Jeremy Hu 4679381512 Add XZ switching menu item 2018-06-21 16:24:18 +08:00
Jeremy Hu 22910028e9 Add parts subtract operation.
This is useful for making hole surface. For example, without subtraction, it's difficult to make a bucket like mesh, now, you just need to copy and paste the nodes, invert it from the Parts List Panel Context Menu, then down scale and move up a little bit.
2018-06-16 14:41:52 +08:00
Jeremy Hu d05c43d714 Add animation clip: Idle
This is an experiment test of animation clip generation. Mark leg and spine nodes to enable it or check it with the latest mosquito.ds3 example;
Skeleton offset is been fixed in this commit.
2018-06-15 13:34:41 +08:00
Jeremy Hu 6c10ad1ee2 Add node mark.
User can mark selected nodes as specified body location explictly. This will help the rigging step generating more reasonable result, also prepared for the future animation clip generation.
2018-05-30 09:51:38 +08:00
Jeremy Hu 6268852e59 Fix copy/paste selection state.
In the previous version, the nodes get selected and copied, without lost selection after new nodes pasted.
This commit fix this problem. Now, the old nodes lose selection while new pasted nodes gettting selected.
This feature will make the following use case much easier:

Extrude:
Select some nodes, copy, paste then scale.
2018-05-12 18:07:46 +08:00
Jeremy Hu 429e2c98c1 Fix symmetry.
The symmetry feature is not funtional when there is no turnaround reference sheet loaded.
This should fix the problem by load a empty background image.

Thanks @xtvjxk123456 for addressed this issue, https://github.com/huxingyi/dust3d/issues/6
2018-05-11 23:06:54 +08:00
Jeremy Hu 0cecff71c7 Separate ambient occlusion baker to a different phase.
This is mainly for resolving the baking time consuming issue when running in software OpenGL.
Compare to normal OpenGL which would only take seconds to bake, software OpenGL take minutes to bake a complex model.
Separating the baking phase would allow the user to export the result without baking.
2018-05-11 13:27:29 +08:00
Jeremy Hu 078543b80e Add ambient occlusion baker.
- Add @ands 's lightmapper to generate ambient occlusion image.
- Refactor parts list UI.
- Add interpolated normal to .gltf export result.
- Remove bones preview and texture preview window(Integrated to export preview UI).
- Add export preview UI.
2018-05-10 17:16:22 +08:00
huxingyi d7fb742d7b Fix build 2018-05-07 10:16:58 -07:00
Jeremy Hu 1376af237b Add auto uv unwrapping.
Use https://github.com/Thekla/thekla_atlas to generate the texture.
This commit still have some issues, some faces not satisfy thekla_atlas in some cases.

- Add texture preview widget.
- Fix single node black color issue.
- Export texture in .gltf file.
- Fix node order random issue in mesh generation.
2018-05-08 00:08:19 +08:00
Jeremy Hu 3fef6c4463 Add auto-generated skeleton(skinned mesh) and glTF exporter.
And added a CONTRIBUTORS file to list the users who have done great work to help Dust3D become better, thank you!

@Alistair401
@hdu
@shadowndacorner
@Skullfurious
@RSDuck
@xtvjxk123456
@Zireael07
@glasyalabolas
@dlpatri

PS. please feel free to make a pull request or email me to change the ID or contact info listed in the CONTRIBUTORS file, and if you are mistakenly been missed in the file, please MUST edit this file and make a PR or email me.
2018-04-30 19:31:09 +08:00
Jeremy Hu 331051879d Add parts color configure and round-able configure.
- Add End-Round Type Toggle to Parts List Panel (Thanks @Alistair401 for proposing this feature).
- Add Parts Color Picker to Parts List Panel.
- Add Parts List Panel Context Menu to facilitate multiple parts visible toggle.
- Add Material Export to Export Menu.
- Prepare the source code for the auto skeleton exporter and uv unwrapper.
2018-04-26 10:23:22 +08:00
Jeremy Hu 9643920515 Fix UI too small and crash on bad mesh problem.
The model generating speed may become slightly slower than the previous version because of the extra checks.

This closes #1, and closes #3
2018-04-23 08:10:01 +08:00
Jeremy Hu fe11e097d9 Add check part and show part check status.
Now can check part from part list widget, double click it will check the whole part to graphics view, and also, if the part's node or edge been hovered or checked, the first one's part will be highlighted in the part list.
2018-04-18 09:49:23 +08:00
Jeremy Hu f1b219333f Fix deform 2018-04-18 00:14:31 +08:00
Jeremy Hu ce41e654fb Add thickness parameter for part.
It's showed as mini button on part list widget, this parameter can be use to make fish body like mesh.
2018-04-17 21:13:32 +08:00
Jeremy Hu a1107b5412 Add xyz lock 2018-04-17 06:54:41 +08:00
Jeremy Hu dd976b7fc2 Adjust color theme for part list mini button to make a better visible effect 2018-04-16 20:06:48 +08:00
Jeremy Hu 44a8ca6351 Add part mirror 2018-04-15 20:11:51 +08:00
Jeremy Hu 8a6dd60450 Add editable check when select 2018-04-13 08:19:31 +08:00
Jeremy Hu 2d5b6eca9b Add edge break 2018-04-12 20:27:21 +08:00
Jeremy Hu 5ac8968cee Keep part attributes while been splitted 2018-04-11 17:48:43 +08:00
Jeremy Hu 982ee45a16 Add part enable/disable 2018-04-11 17:19:27 +08:00
Jeremy Hu 38fb0c022a Add main menu.
- Add about window,
- Add acknowlegements window,
- Add multiple documents support.
2018-04-10 15:59:20 +08:00
Jeremy Hu f47148a537 Cleanup and reset initial render angle 2018-04-09 23:10:23 +08:00
Jeremy Hu 62fdcbdced Add flip 2018-04-09 22:24:30 +08:00