Commit Graph

634 Commits

Author SHA1 Message Date
kovacsv
12537cdac8 Enable camera mode setting during embedding. 2022-09-18 14:35:06 +02:00
kovacsv
14b0863d64 Add orthographic mode to the viewer class. 2022-09-18 13:01:51 +02:00
kovacsv
19b81d0b4c Fix field of view during embedding. 2022-09-18 11:11:23 +02:00
kovacsv
73417f2a90 Store field of view in engine's camera. 2022-09-18 10:43:20 +02:00
kovacsv
1b82ef4320 Reset progress dialog to the original one. 2022-07-10 19:02:29 +02:00
kovacsv
36957d3fbe Feature flag for download progress. 2022-07-05 18:08:53 +02:00
kovacsv
f43327ddd8 Support IGES format #279 2022-07-03 17:34:34 +02:00
kovacsv
f806549e9c Code formatting. 2022-07-02 23:36:17 +02:00
kovacsv
71958671bc Add function to check if there is a listener for an event. 2022-07-02 22:47:55 +02:00
kovacsv
2a80468276 Rename EventSource to EventNotifier. 2022-07-02 22:34:43 +02:00
kovacsv
bd6c2b5114 Add EventSource class. 2022-07-02 22:25:34 +02:00
kovacsv
235149c325 Rename callback. 2022-07-02 22:14:10 +02:00
kovacsv
784715e89c Show progress bar for file download #288 2022-07-02 13:07:14 +02:00
kovacsv
e0b046d1b7 Add callbacks for file loading progress. 2022-07-02 09:16:45 +02:00
kovacsv
6158280bd6 Fix measured values visibility in case of transparent or image background. 2022-06-25 19:55:03 +02:00
kovacsv
d296302a37 Fix measured values visibility in case of transparent or image background. 2022-06-25 13:52:50 +02:00
kovacsv
79595fcdf9 Transparent background color #286 2022-06-25 12:02:36 +02:00
kovacsv
62af23cafc Use RGBAColor for background. 2022-06-25 11:36:53 +02:00
kovacsv
c168f944f6 Rename Color to RGBColor. 2022-06-25 10:20:58 +02:00
kovacsv
d85d3c336f Minor modification. 2022-06-18 16:25:46 +02:00
kovacsv
2593bbba4e Calculate the volume of a model by calculating the sum of volumes of all meshes. 2022-06-18 16:24:15 +02:00
kovacsv
7e9a191671 OFF mesh file import with colors #278 2022-06-17 19:14:28 +02:00
kovacsv
a7a76cec4b Fix svg importer. 2022-06-16 19:02:16 +02:00
kovacsv
97b51ca3ec Remove embedding event handler. 2022-06-15 22:04:49 +02:00
kovacsv
a4ec93ebcd Use ColorToMaterialConverter in ifc importer. 2022-06-14 22:30:43 +02:00
kovacsv
006e5aafc2 Use ColorToMaterialConverter where possible. 2022-06-14 21:15:20 +02:00
kovacsv
ef5c710245 Add the possibility to switch between environment maps #161 2022-06-12 13:25:09 +02:00
kovacsv
6a0148b66b Update environment map previews. 2022-06-12 13:12:10 +02:00
kovacsv
d34c710c0a Minor modification. 2022-06-06 16:58:09 +02:00
kovacsv
15dcf8b44d Do not fit model to window when camera parameters are provided. 2022-06-06 10:17:38 +02:00
kovacsv
41b65010f2 Rename filelist.js to importerfiles.js. 2022-06-05 21:08:53 +02:00
kovacsv
316c8e7293 Introduce InputFile class that can specify the name and the url as well (#202). 2022-06-05 14:44:05 +02:00
kovacsv
61c98e6f2e Environment and background improvements. 2022-06-04 14:32:50 +02:00
kovacsv
bf49f7d77f Add embedded event. 2022-06-04 09:29:06 +02:00
kovacsv
d5e33c00f0 Build fix. 2022-05-29 11:30:19 +02:00
kovacsv
6f54184dc6 Escape html special characters in properties. 2022-05-29 11:26:58 +02:00
kovacsv
dc60397102 Implement face colors for dotbim #270 2022-05-28 19:20:04 +02:00
kovacsv
48fc88cb70 Do not show empty property group. 2022-05-28 00:38:08 +02:00
kovacsv
12c0f7df8d Prepare npm package. 2022-05-20 22:06:02 +02:00
kovacsv
f133ced651 Bundle three.js together with the library. 2022-05-20 18:52:37 +02:00
kovacsv
5843fc3cc8 Fix lint error. 2022-05-18 20:21:51 +02:00
kovacsv
9aff0be5f0 Show assembly structure of step files #265 2022-05-18 20:19:02 +02:00
kovacsv
5dcedf559f Replace tabs with spaces. 2022-05-10 08:04:37 +02:00
kovacsv
b3ab00fbbe Make File Upload Possible in the Embedded Viewer #253 2022-05-05 22:02:56 +02:00
Wojciech Radaczyński
99797e6b09
Creates empty info if there is no properties
Subjective opinion that it makes it easier when all properties are filled 100% of a time, even if it means empty list. To check if after this change it actually creates "info": {} :)
2022-05-02 17:54:53 +02:00
kovacsv
2e93a9b3d4 Select all when the snapshot size field gets focus. 2022-04-30 09:16:40 +02:00
kovacsv
afe6cce6da Remove url from texture, since it's not a core data, and needed only for three.js conversion. 2022-04-27 18:19:55 +02:00
kovacsv
e9a308bcfe Can't calculate the volume on model in the Embedded Viewer #241 2022-04-21 18:11:29 +02:00
kovacsv
104fa9a0ff The list of meshes doesn't have names in the Embedded Viewer #249 2022-04-21 18:09:02 +02:00
kovacsv
d3f930f72c Generate a pseudo-random guid during bim export. 2022-04-19 23:01:41 +02:00
kovacsv
e178e53fbd glB material import not displaying correctly #248 2022-04-19 18:29:28 +02:00
kovacsv
df05dd9a51 Add mandatory fields to bim files. 2022-04-19 17:11:15 +02:00
kovacsv
267aeec79a bim export #246 2022-04-18 18:09:17 +02:00
kovacsv
4f627a7589 Remember export options. 2022-04-18 18:08:53 +02:00
kovacsv
3706ee3ab1 Custom snapshot resolution #244 2022-04-18 10:58:32 +02:00
kovacsv
abeb281c65 Url detection in element properties #235 2022-04-15 08:58:58 +02:00
kovacsv
18acc48e21 Move snapshot dialog to a separate file. 2022-03-25 22:53:13 +01:00
kovacsv
c41ff07def Host occt-import-js locally. 2022-03-24 19:08:51 +01:00
kovacsv
dc19691fa5 Show textures in Rhino files #230 2022-03-14 19:41:56 +01:00
kovacsv
da1c019fd0 Create a separate toolbar button for image export #221 2022-03-07 18:17:46 +01:00
kovacsv
f4f6228426 Move website related code outside of the engine. 2022-03-06 20:16:02 +01:00
kovacsv
43d707ed8e Update engine exports. 2022-03-06 19:54:02 +01:00
kovacsv
76ccea789a Add snapshot dialog skeleton. 2022-03-06 19:50:01 +01:00
kovacsv
0feb232599 Keep track of the currently opened dialog globally. 2022-03-06 18:01:08 +01:00
kovacsv
98706cfceb Temporary measure marker is visible on the snapshot #229 2022-03-06 14:28:19 +01:00
kovacsv
77bfd0d2c8 Hide Flat list/Tree view icons #184 2022-03-06 09:13:40 +01:00
kovacsv
9dda077063 Enable measure tool. 2022-03-05 18:04:12 +01:00
kovacsv
97d9e560d1 When importing STP format file, the model structure has no name and the material information is lost #220 2022-03-05 11:40:39 +01:00
kovacsv
42284ac419 Add placeholder icons for measure tool. 2022-02-26 10:36:42 +01:00
kovacsv
111125ea32 Custom camera position doesn't work during embedding #224 2022-02-24 19:20:51 +01:00
kovacsv
47cb58183a Handle error when occt-import-js is not accessible. 2022-02-24 18:56:55 +01:00
kovacsv
0dd11501aa Load occt-import-js from cdn. 2022-02-23 20:21:40 +01:00
kovacsv
722e8db2e9 Add error messages when external library loading fails. 2022-02-23 17:56:49 +01:00
kovacsv
a5f4d41455 Remove grid code. 2022-02-21 21:21:22 +01:00
kovacsv
7a05c62e50 Adjust text color to canvas background color. 2022-02-20 22:51:57 +01:00
kovacsv
4a363b2d23 Modify marker color. 2022-02-20 18:33:18 +01:00
kovacsv
c165242ad6 Minor code cleanup. 2022-02-20 18:00:08 +01:00
kovacsv
15a3214eea Draw crosshair instead of cone in measure tool. 2022-02-20 17:17:32 +01:00
kovacsv
f18748f5e6 Move measure button to the toolbar. 2022-02-20 14:35:24 +01:00
kovacsv
dd8360fd92 Add bim importer #219 2022-02-19 16:45:31 +01:00
kovacsv
edd6fe43bc glTF import fails when using multiple primitives without indices #218 2022-02-18 18:23:34 +01:00
kovacsv
f043396011 Detailed error message in case of the file is not available. 2022-02-13 19:10:18 +01:00
kovacsv
c531a2c89c Attribute item size is not used when converting a three.js mesh #214 2022-02-09 19:51:40 +01:00
kovacsv
fa7f82e9c2 Minor modification. 2022-02-06 16:43:18 +01:00
kovacsv
686d225aa0 Rename step importer. 2022-02-06 16:35:12 +01:00
kovacsv
7f5b8294e0 Minor modification. 2022-02-06 16:29:33 +01:00
kovacsv
bd10f4f53a STEP file import #50 2022-02-06 16:29:03 +01:00
kovacsv
aa76460ede Add feature toggle for environment settings. 2022-01-22 23:35:54 +01:00
kovacsv
0ec5e8d814 Environment map background option when embedding the engine. 2022-01-22 16:28:31 +01:00
kovacsv
ba22d4d510 Feature Request - Ability to load/toggle environment texture instead of solid color #144 2022-01-22 16:03:11 +01:00
kovacsv
d4d488ad46 Add the possibility to switch between environment maps #161 2022-01-22 14:39:34 +01:00
kovacsv
f1361eed43 Update environment maps. 2022-01-22 11:37:18 +01:00
kovacsv
04120897ac Reorganize settings panel into sections. 2022-01-22 09:04:56 +01:00
kovacsv
c3f75a23b4 Fix deepscan error. 2022-01-21 18:50:58 +01:00
kovacsv
528541cfd4 Store main file name in error if it's present. 2022-01-21 18:46:54 +01:00
kovacsv
0fbebe7893 Use inverse transpose matrix for normal vector calculation. 2022-01-21 17:13:05 +01:00
kovacsv
22124a9992 Simplify cuboid generator. 2022-01-19 17:59:06 +01:00
kovacsv
603d7c8699 Add cone generator. 2022-01-18 23:19:21 +01:00
kovacsv
a68902f33b Update engine main. 2022-01-18 19:55:30 +01:00
kovacsv
968f336a98 Move camera to a separate file. 2022-01-18 19:51:07 +01:00
kovacsv
962a45c5e1 Fix an lgtm alert. 2022-01-18 18:50:49 +01:00
kovacsv
ce9176a58e Fix some DeepScan analysis errors. 2022-01-17 21:07:00 +01:00
kovacsv
7146bc0e2a Fix some DeepScan analysis errors. 2022-01-17 21:01:51 +01:00
kovacsv
aef3994e5c Fix some LGTM issues. 2022-01-17 18:12:17 +01:00
kovacsv
4d9362eb85 Minor modification. 2022-01-16 09:48:43 +01:00
kovacsv
d6c72821de Fix crash when drag&dropping non-file object. 2022-01-15 13:00:49 +01:00
kovacsv
646ca67e7e Create quaternion from x, y, z rotation values. 2022-01-15 12:11:52 +01:00
kovacsv
d4d4c1fad4 Better error reporting. 2022-01-14 18:20:36 +01:00
kovacsv
7dd1b0a201 Event handler shouldn't be a class. 2022-01-14 17:52:50 +01:00
kovacsv
052ef29ac5 Import vertex colors from obj files #201 2022-01-13 22:26:03 +01:00
kovacsv
576cdab3ba Fix typo. 2022-01-13 21:35:00 +01:00
kovacsv
b7b4cca10f Minor modification. 2022-01-12 20:09:18 +01:00
kovacsv
41c459897f Use substring instead of substr since it's deprecated. 2022-01-12 18:27:38 +01:00
kovacsv
211646c874 Remember the last used export file format #208 2022-01-12 17:13:31 +01:00
kovacsv
f21c5b74d0 CookieHandler shouldn't be a class. 2022-01-12 17:06:02 +01:00
kovacsv
1c6423b807 Remove unused class and function exports. 2022-01-10 18:34:31 +01:00
kovacsv
a4d386c521 Use ES modules. 2022-01-10 18:10:51 +01:00
kovacsv
3115e77648 Name clarification in obj importer. 2022-01-08 10:35:37 +01:00
kovacsv
e94cf8e5e5 Fix select menu appearance on firefox and safari. 2022-01-08 10:22:07 +01:00
kovacsv
31f622dede Add utility function for color conversion. 2022-01-07 22:45:43 +01:00
kovacsv
dbf1865c46 Set vertex color for materials only if they have vertex color in all appearances. 2022-01-05 19:10:12 +01:00
kovacsv
671a0cac85 Add the possibility to rotate the model during export #196 2022-01-04 20:32:53 +01:00
kovacsv
a13f82f687 Remove material parameter from mesh. 2022-01-04 19:49:13 +01:00
kovacsv
88f928beae Minor modifications. 2022-01-04 19:37:53 +01:00
kovacsv
b526bea0bb Add mesh material which is inherited to triangles during finalization. 2022-01-03 19:34:08 +01:00
kovacsv
2969050880 Move mesh clone function to the mesh class. 2022-01-03 18:46:16 +01:00
kovacsv
6f8893befc Move client coordinate calculation to dom utils. 2022-01-02 10:03:48 +01:00
kovacsv
d4b3a2e009 Use set or map instead of pure object. 2022-01-02 10:00:13 +01:00
kovacsv
862677bbf7 Move color class to a separate file. 2022-01-01 10:59:36 +01:00
kovacsv
3795b5cacd Get mesh type instead of checking triangle count. 2021-12-31 10:37:16 +01:00
kovacsv
6dc21ae06b Provide only material color for importer. 2021-12-30 16:20:03 +01:00
kovacsv
630f85145b Create model finalizer class. 2021-12-30 14:40:54 +01:00
kovacsv
2d8acfe7da Move mesh utils to a separate file. 2021-12-30 10:16:49 +01:00
kovacsv
3b6e784081 Check vertex color indices in tests. 2021-12-29 17:28:46 +01:00
kovacsv
6b953b790c Change asset order in glTF exporter. 2021-12-29 13:53:53 +01:00
kovacsv
36c3cd5405 Don't try to read vertex colors from draco compressed models. 2021-12-29 12:18:43 +01:00
kovacsv
7000368040 Fix glTF component type handling for vertex colors. 2021-12-29 12:00:15 +01:00
kovacsv
6a022775a4 Prevent material modification if vertex colors are present. 2021-12-29 09:50:31 +01:00
kovacsv
df5ad1e6be Hack in case of invalid color component range. 2021-12-29 09:40:09 +01:00
kovacsv
c6b2dbb95a Do not show default material popup when there are vertex colors. 2021-12-29 09:39:50 +01:00
kovacsv
f57d31eca8 Add test for exporting vertex colors to glTF. 2021-12-29 08:41:36 +01:00
kovacsv
10f7df63bc Export vertex colors to glTF. 2021-12-28 21:55:53 +01:00
kovacsv
0eee801446 Store vertex colors for triangles. 2021-12-28 21:15:33 +01:00
kovacsv
53d30d0b64 Add helper function for color conversion. 2021-12-28 17:25:25 +01:00
kovacsv
5c40815a7d Add helper function for color conversion. 2021-12-28 17:22:38 +01:00
kovacsv
1213bbee22 Add helper function for color conversion. 2021-12-28 17:19:26 +01:00
kovacsv
53a7193d4c Import vertex colors with three.js importers. 2021-12-28 17:12:20 +01:00
kovacsv
e5a2839c18 Minor modification. 2021-12-28 17:00:27 +01:00
kovacsv
28b1edbfad Function to convert between gltf and internal colors. 2021-12-28 16:51:38 +01:00
kovacsv
3a5c65bdc8 Store vertex colors in mesh. 2021-12-28 16:44:00 +01:00