Commit Graph

5886 Commits

Author SHA1 Message Date
ElonOlsson
0aba8a96f3 cleanup my own try, use exsisting function in Tracer 2025-02-03 13:21:59 -05:00
ElonOlsson
7d6baae2e5 first time find closed fieldlines task work 2025-01-31 15:33:22 -05:00
ElonOlsson
afe95d2b2f restored kameleon documentation task 2025-01-31 14:32:22 -05:00
elonolsson
41c3106b0c tests. fail to save to file 2025-01-31 12:04:19 -05:00
ElonOlsson
204e77fdbc test used code from Anders branch to check why i get 0 on y on first position of each line 2025-01-22 16:13:35 -05:00
elonolsson
be1e544952 start finding first and last points on line to varify topology 2025-01-21 17:13:26 -05:00
elonolsson
d2cb7c9083 merge master 2025-01-10 22:37:39 +01:00
elonolsson
44dfb6548a temp before merge master 2025-01-10 17:54:58 +01:00
Emma Broman
2856085724 Use a pointing hand GLFW cursor for the web grab cursor (#3465)
* Use a pointing hand GLFW cursor for the web grab cursor

* Add TODO comment about custom cursor
2024-12-09 17:08:06 +01:00
Andreas Engberg
27e46d8cf5 add openspace lua table to lua transforms 2024-12-04 13:41:28 +01:00
Andreas Engberg
84ad4cf373 Make sure we search the the actual file name and not entire path
Caused an issue where it would not "find" the metadata if there was any '.' in any part of the path e.g., `OpenSpace-0.20.1/..`
2024-11-07 10:16:18 +01:00
Emma Broman
fc93523914 "Fix" invalid geometries before adding them (#3452)
However, they might not actually be completely fixed and still look weird. But at least now they load
2024-10-30 16:40:28 +01:00
Malin E
40578ebc81 Update string versions of distance and time units, start with capital
letter

* Update RenderableModel to better make use of these predefined units
2024-10-29 17:02:48 +01:00
Alexander Bock
390d4a3e50 Fix issue with creating RenderableGlobes with layers 2024-10-22 15:24:35 +02:00
Alexander Bock
438d6e3ddd SessionRecording and KeyframeRecording redesign (#3399) 2024-10-21 15:06:40 +02:00
Emma Broman
304cbb2032 Provide errors when setting exoplanet module file paths 2024-10-21 10:04:35 +02:00
Emma Broman
68c2157dd4 Move Exoplanet creation code from C++ to Lua (#3450)
* Move exoplanet creation code to Lua

* Add more descriptions and handle missing values

* Remove old creation function and move load from CSV to Lua

* Properly document all functions, including a type for the `systemData` return value

* Add `\param` documentation to the scripts

* Cleanup and move helper functions to core scripts

* Throw Lua errors when things go wrong, instead of returning empty objects

This prevents the rest of the code from being run

* Flesh out TODO comments, so future us know why they are there


---------

Co-authored-by: Alexander Bock <alexander.bock@liu.se>
2024-10-21 09:30:18 +02:00
Andreas Engberg
0fc9265837 Feature/assetvalidation (#3396)
# To run the script
Make sure to install the latest Python API version `openspace-api 0.1.2`
The script is located in `OpenSpace/support/assetvalidation`, the main script takes a few command line arguments

`--dir` - specify the OpenSpace directory 
`--filter` - optionally supply a regex string to filter which assets to validate
`--verbose` - flag to print debug info to log and also console (default off), if off only warnings and errors are logged
`--start` - flag to start OpenSpace as a subprocess (default on) if this is off it assumes OpenSpace is already running, useful if you want to run OpenSpace via Visual Studio for example. 
`--at` - specify an index to start at a specific asset

run eg: 
`python main.py --dir="C:/User/Desktop/OpenSpace" --filter="examples" --verbose=True --start=False --at=35`
2024-10-10 15:55:53 +02:00
Alexander Bock
ff345006d1 General code cleanup (#3445) 2024-10-10 09:49:02 +02:00
Alexander Bock
125114cad5 Add documentation for TileProviderByLevel (#3446)
---------

Co-authored-by: Ylva Selling <ylva.selling@gmail.com>
2024-10-10 09:48:39 +02:00
Alexander Bock
56a9d6ae8c Add the ability to query RAM and VRAM usage (#3427) 2024-09-28 13:19:29 +02:00
Emma Broman
326740095f Do not hide requestedUnit of dashboarditem distance in UI (#3435)
* Do not hide requestedUnit of dashboarditem distance in UI

We want to be able to change it during runtime

* Change visiblity of RequestedUnit properties
2024-09-25 11:03:23 +02:00
Alexander Bock
4f58eff235 Make it possible to choose in the asset whether the domain filtering in a fieldline sequence. Apply the change to the Juice fieldlines (closes #3437) 2024-09-25 10:24:15 +02:00
Alexander Bock
5fdc2c4bb8 Add examples for SpiceTranslation (#3413) 2024-09-23 11:35:01 +02:00
Emma Broman
24a2247aa4 Give exoplanets a color based on their size (#3412)
* Add a tag for all exoplanet globes

* Add color to exoplanet globes based on their size

* Update color of terrestrial planets to be more deeply brown

* Change order so that the default texture for planets is shown on top

I.e. only use color if no other texture was provided

* Add descriptions of layer and planet type

* Add descriptions for some more things in the system

* Increase ambient intensity for when a planet is colored (not textured)

* Ignore GlobeBrowsing shader warning when setting camera position (closes #3405)

* Apply suggestions from code review

* Fix new constant names (from review)

---------

Co-authored-by: Alexander Bock <alexander.bock@liu.se>
2024-09-18 11:02:30 +02:00
Ylva Selling
8ad84b6d35 Make useAcceleratedRendering a uniform for screenspace renderables 2024-09-17 17:17:46 +02:00
Alexander Bock
c0ca1acb33 Don't crash when enableing the shadow component on a planet that doesn't have a ring system (closes #3404) 2024-09-16 18:01:10 +02:00
Alexander Bock
06a92620d1 Ignore GlobeBrowsing shader warning when setting camera position (closes #3405) 2024-09-16 17:32:48 +02:00
Gene Payne
67992558e1 Fixes for linux build with most recent CEF update (#3407) 2024-09-12 09:17:24 -06:00
Alexander Bock
e24cff1d19 Handle warnings and coding style adaptations 2024-09-12 16:30:09 +02:00
Emma Broman
77672f0cc4 Fix, cleanup and simplify RenderableGlobe properties (#3408)
* Restructure "general properties" into shadow mapping and regular ones

To better connect to subpropertyowners and avoid having to specify an ordered list in constructor... Hard to keep track of

* Restructure properties in constructor to more easily find errors

* Add values that could not be set from parameters (e.g. from asset or script)

* Apply suggestions from code review

Co-authored-by: Alexander Bock <alexander.bock@liu.se>

* Address review comments

---------

Co-authored-by: Alexander Bock <alexander.bock@liu.se>
2024-09-11 16:40:38 +02:00
Alexander Bock
3024467cbc Prevent crash when requesting a mouse click outside the window borders 2024-09-10 15:05:23 +02:00
Alexander Bock
fd64fe7c96 Improvements to the ScriptLog logging (#3389)
* Restructuring the queueScript function
* Don't log the contents of actions that are triggered.  Add the ability to do verbose logging in the scriptlog
2024-09-09 21:16:57 +02:00
Andreas Engberg
ddbf155e8b fixed return type to tuple 2024-09-04 09:21:59 +02:00
Emma Broman
a7c11b4de9 Make empty dictionary convert into an empty json object and not undefined
Fixes a crash in the GUI when no gui order was set, e.g. in the empty profile
2024-08-29 09:30:33 +02:00
Alexander Bock
16484dc295 Doxygen cleanup and moving functions in SceneGraphNodes 2024-08-28 11:50:39 +02:00
Ylva Selling
aed2c0b0c8 Issue/2244 different mouse cursors (#3388)
* Update CEF version number

* Set OpenSpace_Helper version of C++ to 20

* Update C++ syntax to v 20

* Remove deprecated function (now default)

* Set the cache folder for cef

* Make static function in webbrowsermodule that determines if we can use accelerated rendering

* Add flag for accelerated rendering to webrenderhandler

* Use accelerated rendering

* Implement function to see if gui should absorb click

* Adhere to 80 char linewidth

* Make only the UI GPU accelerated

* Use dirty rects size for the texture to remove crash

* Better comments

* Make has content function work for GPU acceleration

* Make it so all browsers can be accelerated

Tried making it so only the gui was accelerated for simplicity. Performance plummeted, so reverted that

* Tidy up

* Add accelerated rendering flag to the screenspacerenderable shader

* Add temporary fix to make the sky browser work

* Remove flag from gui render handler

* Enable webgl in a nicer way

* Unbind texture in screenspacerenderable

* Add better comments for error handling

* Tidy up

* Address PR comments

* Make the acceleration Windows only

* Remove unnecessary setting of shader dictionary

* Add display handler to browser client

* Make glfw change mouse cursor depending on cef cursor

* formatting

* Add switch to main

* Update modules/webbrowser/src/browserclient.cpp

Co-authored-by: Alexander Bock <alexander.bock@liu.se>

* Address comments on PR

* Update again

* Update modules/webbrowser/src/browserclient.cpp

Co-authored-by: Emma Broman <emma.broman@liu.se>

* Address PR comments

---------

Co-authored-by: Ylva Selling <ylva.selling@liu.se>
Co-authored-by: Alexander Bock <alexander.bock@liu.se>
Co-authored-by: Emma Broman <emma.broman@liu.se>
2024-08-28 10:44:17 +02:00
Ylva Selling
fd586e30a3 Set useAcceleratedRendering flag in skybrowser 2024-08-23 16:46:36 +02:00
Ylva Selling
11bb8e7ac5 GPU accelerate CEF (#3386)
* Update CEF version number

* Set OpenSpace_Helper version of C++ to 20

* Update C++ syntax to v 20

* Remove deprecated function (now default)

* Set the cache folder for cef

* Make static function in webbrowsermodule that determines if we can use accelerated rendering

* Add flag for accelerated rendering to webrenderhandler

* Use accelerated rendering

* Implement function to see if gui should absorb click

* Adhere to 80 char linewidth

* Make only the UI GPU accelerated

* Use dirty rects size for the texture to remove crash

* Better comments

* Make has content function work for GPU acceleration

* Make it so all browsers can be accelerated

Tried making it so only the gui was accelerated for simplicity. Performance plummeted, so reverted that

* Tidy up

* Add accelerated rendering flag to the screenspacerenderable shader

* Add temporary fix to make the sky browser work

* Remove flag from gui render handler

* Enable webgl in a nicer way

* Unbind texture in screenspacerenderable

* Add better comments for error handling

* Tidy up

* Address PR comments

* Make the acceleration Windows only

* Remove unnecessary setting of shader dictionary

* Allow web dev tools to connect to CEF

* Update modules/webbrowser/include/browserinstance.h

Co-authored-by: Emma Broman <emma.broman@liu.se>

* Update modules/webbrowser/include/webrenderhandler.h

Co-authored-by: Emma Broman <emma.broman@liu.se>

* Apply suggestions from code review

Co-authored-by: Emma Broman <emma.broman@liu.se>

---------

Co-authored-by: Ylva Selling <ylva.selling@liu.se>
Co-authored-by: Emma Broman <emma.broman@liu.se>
2024-08-23 09:37:01 +02:00
Emma Broman
6e6f425a0a Issue/3337 Custom UI group ordering (#3363)
* remove code for controlling group sorting in ImGui

We only use this for debug and the sorting here is no longer relevant

* Add feature to add custom ordering to UI groups

* Tiny cleanup

* Add numerical ordering for night sky planets

* Update Lua function name and create an event when ordering updated

* Set top-level ordering

* Add function documentation

* Add a custom ordering that previously was hardcoded in UI

* Apply suggestions from code review

Co-authored-by: Alexander Bock <alexander.bock@liu.se>

* Rename GUI ordering function

* Update GUI hash

---------

Co-authored-by: Alexander Bock <alexander.bock@liu.se>
2024-08-22 16:51:28 +02:00
Alexander Bock
423d409dc8 Always use the alpha blending independent of the renderbin (closes #3304)
It wasn't really clear why the check for the PreDeferredTransparent bin was in here in the first place
2024-08-22 14:00:51 +02:00
Ylva Selling
67965e8844 Issue/3174 update cef (#3383)
* Update CEF version number

* Set OpenSpace_Helper version of C++ to 20

* Update C++ syntax to v 20

* Remove deprecated function (now default)

* Set the cache folder for cef

* Update modules/webbrowser/src/cefhost.cpp

Co-authored-by: Alexander Bock <alexander.bock@liu.se>

* Update version number

---------

Co-authored-by: Ylva Selling <ylva.selling@liu.se>
Co-authored-by: Alexander Bock <alexander.bock@liu.se>
2024-08-21 11:16:17 +02:00
Alexander Bock
d0b3cd6e89 Add example for ConstantRotation (#3384) 2024-08-21 10:34:08 +02:00
Emma Broman
09c192f46e Fix TravelSpeed uniform variables not being set correctly (closes #3381) 2024-08-19 17:47:03 +02:00
Alexander Bock
a01760a3ca Remove remains of visibility voting 2024-08-18 12:55:55 +02:00
Alexander Bock
7ec6b6cfb5 Add examples for GlobeRotation (#3377)
* Add examples for GlobeRotation and make the longitude and latitude defintion non-optional
* Remove old GlobeRotation example
2024-08-16 13:45:24 +02:00
Alexander Bock
ab4023b9fd No longer send the script source of shortcuts via the topic. Don't scripts into the log that are binary blobs 2024-08-14 14:38:46 +02:00
Alexander Bock
43ada7fa1f Add the ability to feather borders of screenspace renderables 2024-08-13 13:37:39 +02:00
Alexander Bock
75b4609c52 Remove explicitly specifying LuaState constructors 2024-08-07 11:34:57 +02:00
Alexander Bock
ca6c14e9b5 Make the SampleInterval for RenderableTrailTrajectory optional and use a sample per 2 days by default 2024-08-07 06:53:05 +02:00