1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-03 17:56:21 +03:00

11 Commits

Author SHA1 Message Date
kgv
a34bddcfd6 0032315: Configuration, CMake - fix building Draw Harness plugins as static libraries
DPLUGIN() macros no more defines exported function PLUGINFACTORY when building static libraries.
DRAWEXE executable now pre-loads a set of plugins when building static libraries.
dversion - added WebAssembly info.
2021-04-23 18:46:13 +03:00
kgv
b8ef513c8f 0032206: Visualization, TKOpenGl - move out OpenGL ES support to dedicated library TKOpenGles
Added TKOpenGles and TKOpenGlesTest toolkits built with HAVE_GLES2 macros.
Added CSF_OpenGlesLibs as alternative to CSF_OpenGlLibs.
2021-03-21 19:15:06 +03:00
kgv
e03a03fdc2 0032122: Samples - handle WASD keys in WebGL sample 2021-02-10 20:44:31 +03:00
kgv
a0073def2d 0032081: Visualization - WebGL sample errors when run in Safari browser with WebGL 1.0
"MAX_WEBGL_VERSION=2" Emscripten option is now used for building sample instead of deprecated "USE_WEBGL2=1".
2021-01-29 19:51:18 +03:00
kgv
5de4b704fe 0032065: Samples - use MODULARIZE within WebGL sample
Fixed multitouch input.

Module is now exported with global functions hidden via MODULARIZE
as global object OccViewerModule created by createOccViewerModule().
Global Module setup has been moved to occt-webgl-viewer.js.

Use EMSCRIPTEN_KEEPALIVE attribute istead of listing C functions via EXTRA_EXPORTED_RUNTIME_METHODS.
WasmOcctView now exports static methods as Module functions using EMSCRIPTEN_BINDINGS.

Standard_ASSERT_DBGBREAK_() is now defined using emscripten_debugger().
2021-01-22 19:03:14 +03:00
kgv
31174e1a58 0031597: Visualization, TKOpenGl - allow disabling Alpha component writes within OpenGl_Context::ColorMask()
Added OpenGl_Caps::buffersOpaqueAlpha option allowing to disable writes
into alpha component of color buffer and keep it opaque.
Added OpenGl_Context::SetColorMaskRGBA() method overriding each color component deliberately.

New option is set within WebGL sample.
2020-12-17 21:05:02 +03:00
luz paz
a110c4a377 0031939: Coding - correction of spelling errors in comments [part 2]
Fix various typos

Fixed via `codespell v2.0.dev`
2020-11-30 14:04:03 +03:00
kgv
a966542b8a 0031866: Documentation - add description to Graphic3d_NameOfMaterial enumeration values
Enumeration values have been renamed to use complete prefix Graphic3d_NOM_ -> Graphic3d_NameOfMaterial_
and to match string names (with old values preserved as aliases).
2020-10-22 17:40:42 +03:00
kgv
7465bfa65e 0031668: Visualization - WebGL sample doesn't work on Emscripten 1.39
OpenGl_Context now skips loading functions related to mapping buffer,
which are required by OpenGL ES 3.0 specs but not provided by WebGL 2.0.
Message_PrinterSystemLog does not use a broken emscripten_log() anymore, which corrupted UNICODE strings.

WasmOcctView::initWindow() - callbacks now set using EMSCRIPTEN_EVENT_TARGET_WINDOW
instead of 0 used by older Emscripten API.

Mouse callbacks now track canvas element and use
EmscriptenMouseEvent::targetX/targetY instead of ::canvasX/canvasY
as the latter was broken.

Added emscripten_set_main_loop() setup to shut up eglSwapInterval() error message.
Fixed missing \0 at the end of string converted by toUtf8Array().
2020-07-22 19:24:38 +03:00
kgv
b380b06c5d 0031206: Foundation Classes, Message_PrinterSystemLog - log messages to Browser console within Emscripten
Message_PrinterOStream::SetConsoleTextColor() skips color tags in case of Emscripten.
Message_PrinterSystemLog now implements log via emscripten_log().
2020-02-17 14:35:46 +03:00
kgv
565baee64b 0031070: Configuration - fix building issues when using Emscripten toolchain
Handled __EMSCRIPTEN__ macros to:
- Workaround atomics (__GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 is undefined, but GCC atomics are provided).
- Suppress non-standard header <sys/signal.h> warning.
- Return OSD_LinuxREDHAT.
- Avoid inclusion of XLib headers.
- Skip fontconfig library.
- Enable EGL+GLES path (translated by Emscripten into WebGL).
- Skip eglCreatePbufferSurface() not implemented by Emscripten EGL.

Fixed Graphic3d_Vec4.hxx usage within Quantity_ColorRGBA.hxx.

OpenGl_ShaderManager::defaultGlslVersion() now prefers GLSL 300 es when WebGL 2.0 is available,
as there no any OpenGL ES greater than 3.0 emulation so far.

Shaders_Declarations.glsl - added workaround for GLSL compilation on WebGL 1.0
by defining Light properties accessors as macros instead of functions
('[]' : Index expression must be constant).

OpenGl_FrameBuffer::Init() - added workaround for initialization of GL_DEPTH24_STENCIL8
depth-stencil attachment on WebGL 1.0 + GL_WEBGL_depth_texture extension.

OpenGl_Context::Vec4FromQuantityColor() now considers myIsSRgbActive flag
to handle use case, when Immediate Layer is drawn directly into window buffer,
which is not sRGB-ready.

Added new sample - OCCT WebGL viewer.
2019-10-27 00:43:07 +03:00