Commit Graph

49 Commits (a5c5c21b26de65a55b94ef08f5a789a167d418d0)

Author SHA1 Message Date
huxingyi 420a5997ea Optimize render view port
- Fix the bad performance of view port manipulation
- Allow to view the mesh inside
- Fix environment light not enabled in image export
- Fix wireframe not follow the view port setting in image export
2020-04-15 23:35:04 +09:30
Jeremy Hu 76aa261d56 Fix shader camera pos [skip ci] 2020-04-13 22:55:04 +09:30
huxingyi 62e411d4e5 Add a toon shading option box to Preferences Widget [skip ci] 2020-04-08 19:39:16 +09:30
huxingyi 63cbfa83a5 Support importing another Dust3D document as a part
- Add example model: Backpacker
    To demonstrate the importing function
- Add menu: Reverse
    Reverse selected edges. The direction of edge decide the base normal of
    generated mesh.
- Refactor stroke mesh builder
    Remove recursive calls, more consistant generated result
- Add menu: Import
2020-04-08 08:45:20 +09:30
Jeremy Hu 55e657852c Add menu: Export as Image
New feature: Exporting rendered model as png.
A offscreen render been introduced for generating normal and depth maps, which are been generated for toon shader edge detection.
2020-04-02 20:09:57 +09:30
huxingyi 120b59b45f Add tong shader 2020-03-29 19:36:45 +09:30
huxingyi 2800bf7c46 Update cut face model preview
Cut face will show as flat front view
2020-03-25 21:10:44 +09:30
huxingyi 6fcb86a191 Fix shader on win32 2020-03-20 17:11:48 +09:30
huxingyi c84bb14ada Fix IBL shader
Implement DDS cubemap file reader to load the Cedar Bridge environment
cubemap file, and render IBL on core profile.
2020-03-18 23:47:09 +09:30
Jeremy Hu 846270fa80 Add rendered model auto rotation
Toggle rotation from menu view
2020-01-05 08:08:16 +09:30
Jeremy Hu 22373b1ed7 Implement grid mesh builder 2019-12-14 22:58:14 +09:30
Jeremy Hu 1d3c4142d4 Support transparent texture
Add alpha channel support for color texture. The transparency is supported in render preview, export texture preview and glTF exporter.
2019-11-02 12:13:23 +09:30
Jeremy Hu ee94913c62 Limit the zoom size of the rendered widget 2019-08-21 08:29:50 +09:30
Jeremy Hu 95c3607996 Fix paint mode 2019-08-17 21:02:18 +09:30
Jeremy Hu 1d0f2450df Add deforming map painter
- Short cut 'D' changed meaning: from drag mode to paint mode, drag mode icon removed, but still can use space bar to invoke drag mode.
- Brush painter directly paint on part deforming map, use shift key plus mouse wheel to change the brush size, also use shift key to change paint mode(Pull/Push).
2019-08-17 19:43:11 +09:30
Jeremy Hu 13db7ee97b Add check UV 2019-08-10 07:57:26 +09:30
Jeremy Hu bde3c01da0 Add 3d mouse picker 2019-08-08 20:54:33 +09:30
Jeremy HU ab5e53fb54
Fix build error on Raspberry PI 3 Model B+ 2019-07-09 18:12:08 +09:30
Jeremy Hu eb91a8a16c Prepare for cut face offset modifier 2019-07-07 15:57:58 +09:30
Jeremy Hu 1bb14a82a6 Fix PBR material texture glitches 2019-06-02 10:48:03 +09:30
Jeremy Hu 8f5368a43f Add user defined cut face
Extruding shape is totally customizable now, it's not limit to predefined shapes.
2019-05-19 12:51:38 +09:30
Jeremy Hu 84607fba01 Expand the render model mouse control area
Click the middle mouse on the area out of the canvas can also rotate or move the render model.
2018-10-25 15:03:51 +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 71ccb2b71f Fix mouse handling for render model
Before we use a tricky way to share mouse event between model render widget and model edit widget, which forward the event from render widget to edit widget. This will cause some problem, such as the scroll bar of edit widget would not work when it covered by the render model.
Now the mouse event is totally disabled in the render widget, and when there is a need we forward it from edit widget.
2018-10-24 16:54:18 +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 9c0da8f38f Replace the render with PBR
In this commit, another PBR render, come from website: https://learnopengl.com/PBR, also included as shaders/pbr-joey.frag
2018-10-05 15:37:01 +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 87b0f70460 Add mtl export with obj 2018-09-05 11:14:36 +08:00
Jeremy Hu 473fa9f7d9 Add alternative method to zoom rendered model.
- Add "ALT + <Minus | Equal>" combined key to zoom rendred model besides the wheel event.

Special thanks to @glasyalabolas for https://github.com/huxingyi/dust3d/issues/4
2018-05-24 15:08:57 +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 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 d930ceec96 Add alt key to enable rendered model rotate and move.
ALT + LEFT BUTTON: Rotate rendered model
ALT + SHIFT + LEFT BUTTON: Move rendered model

Thanks @Zireael07 and @glasyalabolas for proposing this feature.

Closes #4
2018-04-23 10:14:32 +08:00
Jeremy Hu 71e1a51b43 Fix export y-flipped.
> Another problem is your model seems to have an inverted Z export.
> by https://www.reddit.com/user/Skullfurious

Node coord system: Screen

Mesh generation coord system:
x-axis: --- Main Profile (Red)  --->
z-axis: --- Side Profile (Green) --->
y-axis: UP

Thanks the follow reddit users:
https://www.reddit.com/user/Skullfurious
2018-04-20 20:00:57 +08:00
Jeremy Hu a441c73f55 Add rendered model wireframe toggle action inside view mesh 2018-04-15 20:48:54 +08:00
Jeremy Hu 8c37bc06dc Add group rotation 2018-04-13 08:04:18 +08:00
Jeremy Hu 2d5b6eca9b Add edge break 2018-04-12 20:27:21 +08:00
huxingyi 534c472b53 Fix build error on vc2017 2018-04-12 01:34:00 -07:00
Jeremy Hu e1e4953dec Seperate model render view control and edit view control 2018-04-11 23:06:30 +08:00
Jeremy Hu f0e68d9f7a Change rendered model move button from left to middle 2018-04-11 20:49:00 +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 8ee0dee3db Remove carve and other no-use deps 2018-04-08 16:05:12 +08:00
Jeremy Hu 65b14200a5 Make part list more tidy 2018-04-07 19:51:33 +08:00
Jeremy Hu af451bd5ab Introduce new UI,
Introduce part list,
Add log viewer,
Add QtAwesome icons.
2018-04-07 16:44:39 +08:00
Jeremy Hu b99e0db0b2 Seperate the shader program and mesh binder to seperated source files 2018-04-02 14:05:06 +08:00
Jeremy Hu 01e8abf0cc Fix event conflicts between model and graphics view 2018-03-30 15:41:29 +08:00
Jeremy Hu 94cd279ef3 Render generated model in graphics viewer 2018-03-30 07:32:30 +08:00
Jeremy Hu 4c9767835f Export working model as obj 2018-03-20 15:56:49 +08:00