Skip to content

Commit

Permalink
Merge branch 'main' into enhancements/better-bounding-boxes
Browse files Browse the repository at this point in the history
  • Loading branch information
skalarproduktraum authored Apr 17, 2024
2 parents 25f1e45 + bff8571 commit 118fc84
Show file tree
Hide file tree
Showing 146 changed files with 9,447 additions and 2,217 deletions.
44 changes: 25 additions & 19 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,25 @@ jobs:
matrix:
include:
- os: ubuntu-latest
java: 11
- os: ubuntu-latest
java: 17
java: 21
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: gradle/wrapper-validation-action@v1
- name: Setup Gradle
uses: gradle/gradle-build-action@v3
- uses: gradle/wrapper-validation-action@v3
- name: Set up JDK
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '${{ matrix.java }}'
distribution: 'temurin'
cache: 'gradle'
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build scenery
run: ./gradlew build -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon
run: ./gradlew build testClasses -x test -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon
- name: Test scenery
run: ./gradlew test -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon

windows-unittests:
name: 'Windows'
Expand All @@ -43,27 +45,29 @@ jobs:
matrix:
include:
- os: windows-latest
java: 11
- os: windows-latest
java: 17
java: 21
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: gradle/wrapper-validation-action@v1
- name: Setup Gradle
uses: gradle/gradle-build-action@v3
- uses: gradle/wrapper-validation-action@v3
- name: configure Pagefile
uses: al-cheb/configure-pagefile-action@v1.3
uses: al-cheb/configure-pagefile-action@v1.4
with:
minimum-size: 8GB
maximum-size: 32GB
disk-root: "D:"
- name: Set up JDK
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '${{ matrix.java }}'
distribution: 'temurin'
cache: 'gradle'
- name: Build scenery
run: ./gradlew build -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon
run: ./gradlew build testClasses -x test -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon
- name: Test scenery
run: ./gradlew test -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon

mac-unittests:
name: 'macOS'
Expand All @@ -73,20 +77,22 @@ jobs:
matrix:
include:
- os: macos-latest
java: 11
- os: macos-latest
java: 17
java: 21
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: gradle/wrapper-validation-action@v1
- name: Setup Gradle
uses: gradle/gradle-build-action@v3
- uses: gradle/wrapper-validation-action@v3
- name: Set up JDK
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '${{ matrix.java }}'
distribution: 'temurin'
cache: 'gradle'
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build scenery
run: ./gradlew build -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon
run: ./gradlew build testClasses -x test -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon
- name: Test scenery
run: ./gradlew test -x dokkaHtml -x dokkaHtmlJar -x javadoc -x dokkaJavadocJar --no-daemon
81 changes: 27 additions & 54 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,28 @@ cache:
paths:
- pdb-store/
- .gradle-user-home/
- node_modules/
- screenshots/

workflow:
rules:
- if: $CI_COMMIT_MESSAGE =~ /-draft$/
when: never
- if: $CI_COMMIT_MESSAGE =~ /-WIP$/
when: never
- if: $CI_PIPELINE_SOURCE == "push"

variables:
JAVA_HOME: "/usr/lib/jvm/java-11-openjdk-amd64"
JAVA_HOME: "/usr/lib/jvm/java-21-openjdk-amd64"
PDB_CACHE_DIR: "./pdb-store/cache"
PDB_DIR: "./pdb-store"
MODEL_DIR: "./models"
GRADLE_USER_HOME: "./.gradle-user-home"
VALIDATE_VULKAN: "false"

# simple unit tests without requiring GPUs
unit-tests-no-gpu:
image: ubuntu:bionic
image: scenerygraphics/nvidia-vulkan:1.3.261.1-ubuntu20.04-v3
before_script:
- mkdir -p ./pdb-store/cache
- apt-get update -qq --force-yes > /dev/null
- apt-get install -qq -y --allow-downgrades --allow-remove-essential --allow-change-held-packages unzip wget git curl libgl1-mesa-glx sudo sed openjdk-11-jdk-headless > /dev/null
- if [ ! -d "$MODEL_DIR" ]; then wget -q https://ulrik.is/scenery-demo-models.zip && unzip -q scenery-demo-models.zip; fi
- chmod +x gradlew
script:
Expand All @@ -30,15 +35,17 @@ unit-tests-no-gpu:
# base job for running with GPUs
.base-job-gpu: &base-job-gpu
before_script:
# $VULKAN_SDK_VERSION comes from Docker image
- source /opt/vulkan/$VULKAN_SDK_VERSION/setup-env.sh
- mkdir -p ./pdb-store/cache
# Installs Maven, Vulkan development libraries, etc.
- apt-get update -qq --force-yes > /dev/null
- apt-get install -qq -y curl sudo sed > /dev/null
- sudo sed -i -e '/^assistive_technologies=/s/^/#/' /etc/java-*-openjdk/accessibility.properties
# Output Vulkan driver information, but do not fail in case of non-zero
# return (happens e.g. if $DISPLAY is not set)
- echo -e "\e[0Ksection_start:`date +%s`:hw_info_section[collapsed=true]\r\e[0KHardware Information"
- nvidia-smi || true
- vulkaninfo || true
- clinfo || true
- echo -e "\e[0Ksection_end:`date +%s`:hw_info_section\r\e[0K"
- if [ ! -d "$MODEL_DIR" ]; then wget -q https://ulrik.is/scenery-demo-models.zip && unzip -q scenery-demo-models.zip; fi
- chmod +x gradlew
- ./gradlew --stop # stop any deamon https://stackoverflow.com/a/58397542/1047713
Expand All @@ -48,28 +55,28 @@ unit-tests-no-gpu:
- echo -e "\e[0Ksection_end:`date +%s`:build_section\r\e[0K"
# basic group
- echo -e "\e[0Ksection_start:`date +%s`:basic_section[collapsed=true]\r\e[0KBasic Test Group"
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=basic -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842 -Dscenery.ExampleRunner.Blocklist=EdgeBundlerExample
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=basic -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842 -Dscenery.ExampleRunner.Blocklist=EdgeBundlerExample
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=basic -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842 -Dscenery.ExampleRunner.Blocklist=EdgeBundlerExample -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=basic -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842 -Dscenery.ExampleRunner.Blocklist=EdgeBundlerExample -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- echo -e "\e[0Ksection_end:`date +%s`:basic_section\r\e[0K"
# advanced group
- echo -e "\e[0Ksection_start:`date +%s`:advanced_section[collapsed=true]\r\e[0KAdvanced Test Group"
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=advanced -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=advanced -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=advanced -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842 -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=advanced -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842 -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- echo -e "\e[0Ksection_end:`date +%s`:advanced_section\r\e[0K"
# compute group
- echo -e "\e[0Ksection_start:`date +%s`:compute_section[collapsed=true]\r\e[0KCompute Test Group"
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=compute -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=compute -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=compute -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842 -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=compute -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842 -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- echo -e "\e[0Ksection_end:`date +%s`:compute_section\r\e[0K"
# volumes group
- echo -e "\e[0Ksection_start:`date +%s`:volumes_section[collapsed=true]\r\e[0KVolumes Test Group"
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=volumes -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=volumes -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=volumes -Dscenery.ExampleRunner.Configurations=DeferredShading.yml -Dscenery.RandomSeed=13371842 -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- ./gradlew test jacocoTestReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=volumes -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842 -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- echo -e "\e[0Ksection_end:`date +%s`:volumes_section\r\e[0K"
# code coverage reporting
- echo -e "\e[0Ksection_start:`date +%s`:coverage_section[collapsed=true]\r\e[0KCode Coverage and Analysis"
# we keep the same arguments here as in the last test run to not startle Gradle into re-running the test task
- ./gradlew fullCodeCoverageReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=volumes -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842
- ./gradlew fullCodeCoverageReport --build-cache --full-stacktrace -Pgpu=true -Dscenery.ExampleRunner.TestGroup=volumes -Dscenery.ExampleRunner.Configurations=DeferredShadingStereo.yml -Dscenery.RandomSeed=13371842 -Dscenery.VulkanRenderer.EnableValidations=$VALIDATE_VULKAN -Dscenery.VulkanRenderer.StrictValidation=true -Dscenery.VulkanRenderer.DefaultRenderDelay=100
- echo -e "\e[0Ksection_end:`date +%s`:coverage_section\r\e[0K"
artifacts:
when: always
Expand All @@ -79,46 +86,12 @@ unit-tests-no-gpu:
- "hs_err_*"

scenery-nvidia:
image: scenerygraphics/nvidia-vulkan:1.3.216.0-ubuntu20.04-updatedmodels
image: scenerygraphics/nvidia-vulkan:1.3.261.1-ubuntu20.04-v3
<<: *base-job-gpu
after_script:
- nvidia-smi
- tar cvjf results.tar.bz2 screenshots/
- npm install @argos-ci/cli
- ARGOS_COMMIT=$CI_COMMIT_SHA ARGOS_BRANCH=$CI_COMMIT_REF_NAME ./node_modules/\@argos-ci/cli/bin/argos-cli.js upload screenshots/ || true
- ARGOS_COMMIT=$CI_COMMIT_SHA ARGOS_BRANCH=$CI_COMMIT_REF_NAME argos upload screenshots/ || true
tags:
- cuda
- intel

#scenery-amd:
# image: rocm/rocm-terminal
# <<: *base-job
# variables:
# SUDO: "sudo"
# GPURUN: "sudo su -m - rocm-user -c"
# before_script:
# # The rocm docker container requires the user to be in the video group which
# # can usually be set via docker's --group-add option. GitLab-Runner currently
# # has no known option for doing that. Therefore, it manually has to happen in
# # the job description.
# - $SUDO usermod -a -G video rocm-user
# # Installs Maven, Vulkan development libraries, etc.
# - $SUDO apt-get -qq --force-yes update > /dev/null
# - $SUDO apt-get install -qq --force-yes unzip kmod wget git maven openjdk-8-jdk libvulkan1 libvulkan-dev vulkan-utils > /dev/null
# # Installs the AMD GPUopen Vulkan driver
# - wget https://github.com/GPUOpen-Drivers/AMDVLK/releases/download/v-2019.Q3.6/amdvlk_2019.Q3.6_amd64.deb
# - $SUDO dpkg -i amdvlk_2019.Q3.6_amd64.deb
# - $SUDO apt-get -f install
# - $SUDO lsmod
# # Output Vulkan driver information, but do not fail in case of non-zero
# # return (happens e.g. if $DISPLAY is not set)
# - vulkaninfo || true
# - wget -q https://ulrik.is/scenery-demo-models.zip
# - unzip -q scenery-demo-models.zip
# after_script:
# - rocm-smi
# tags:
# - amd
# - rocm
#
#
48 changes: 48 additions & 0 deletions ACKNOWLEDGEMENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# Acknowledgements

## Colormaps
scenery uses colormaps from the NCL project, licensed under the following terms:

> Copyright © 2007-2018 University Corporation for Atmospheric Research (UCAR). All rights reserved. Developed by NCAR's Computational and Information Systems Laboratory, UCAR, www.cisl.ucar.edu, with the following contributions:
> * dcdflib The University of Texas, M.D. Anderson Cancer Center http://www.netlib.org/random/
> * GRIBEX Copyright © 1981-2007
> European Centre for Medium-Range Weather Forecast http://www.ecmwf.int/products/data/software/grib.html
> * LAPACK Copyright © 1999
> Society for Industrial and Applied Mathematics http://www.netlib.org/lapack/lug/lapack_lug.html
> * random The University of Texas, M.D. Anderson Cancer Center http://www.netlib.org/random/
> * RANGS / GSHHS Dr. Rainer Feistel
> Baltic Sea Research Institute Warnemunde https://www.io-warnemuende.de/rangs-en.html
> * Spherepack Copyright © December 2011
> * UCAR http://www2.cisl.ucar.edu/resources/legacy/spherepack/
> * UDUNITS-2 Copyright © 2012 University Corporation for Atmospheric Research
> UCAR/Unidata http://www.unidata.ucar.edu/software/udunits/udunits-2/udunits2.html
> * Udunits extensions from ncview David Pierce, UCSD
> http://meteora.ucsd.edu/~pierce/ncview_home_page.html
> Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
>
> Neither the names of NCAR's Computational and Information Systems Laboratory, the University Corporation for Atmospheric Research, nor the names of its contributors may be used to endorse or promote products derived from this Software without specific prior written permission.
> Redistributions of source code must retain the above copyright notices, this list of conditions, and the disclaimer below.
> Redistributions in binary form must reproduce the above copyright notice, this list of conditions, and the disclaimer below in the documentation and/or other materials provided with the distribution.
> THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE SOFTWARE.
>
## FXAA Implementation

scenery uses an implementation of FXAA based on [Nvidia's original paper](http://developer.download.nvidia.com/assets/gamedev/files/sdk/11/FXAA_WhitePaper.pdf) and [McNopper's FXAA implementation](https://github.com/McNopper/OpenGL/blob/master/Example42/shader/fxaa.frag.glsl).

## Icons

scenery uses icons from the [FontAwesome](https://fontawesome.com) project, licensed under the CC-Attribution 4.0 license:
> Font Awesome Free License
>
> Font Awesome Free is free, open source, and GPL friendly. You can use it for
> commercial projects, open source projects, or really almost whatever you want.
> Full Font Awesome Free license: https://fontawesome.com/license/free.
>
> --------------------------------------------------------------------------------
>
> Icons: CC BY 4.0 License (https://creativecommons.org/licenses/by/4.0/)
>
> The Font Awesome Free download is licensed under a Creative Commons
> Attribution 4.0 International License and applies to all icons packaged
> as SVG and JS file types.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
[![Join the scenery+sciview Zulip chat](https://img.shields.io/badge/zulip-join_chat-brightgreen.svg)](https://imagesc.zulipchat.com/#narrow/stream/327495-scenery.2Bsciview)


[![pipeline status](https://gitlab.com/hzdr/crp/scenery/badges/master/pipeline.svg)](https://gitlab.com/hzdr/crp/scenery/-/commits/master)
[![Build Status](https://github.com/scenerygraphics/scenery/workflows/build/badge.svg)](https://github.com/scenerygraphics/scenery/actions?workflow=build)
[![Gitlab CI Status](https://gitlab.com/hzdr/crp/scenery/badges/master/pipeline.svg)](https://gitlab.com/hzdr/crp/scenery/-/commits/master)
[![Github Actions Status](https://github.com/scenerygraphics/scenery/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/scenerygraphics/scenery/actions/workflows/build.yml)
[![Codacy Badge](https://app.codacy.com/project/badge/Grade/2178c074ae254f3694529bff94528747)](https://www.codacy.com/gh/scenerygraphics/scenery/dashboard?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=scenerygraphics/scenery&amp;utm_campaign=Badge_Grade)

# scenery // Flexible VR Visualisation for Volumetric and Geometric Data on the Java VM
Expand Down Expand Up @@ -98,14 +98,14 @@ The recommended way to use non-release (unstable) builds is to use jitpack. jitp

### Using _scenery_ in a Maven project

Add scenery and ClearGL to your project's `pom.xml`:
Add scenery to your project's `pom.xml`:

```xml
<dependencies>
<dependency>
<groupId>graphics.scenery</groupId>
<artifactId>scenery</artifactId>
<version>0.9.0</version>
<version>0.11.0</version>
</dependency>
</dependencies>
```
Expand Down Expand Up @@ -141,7 +141,7 @@ Add scenery to your project's `build.gradle`:
```kotlin
dependencies {
// ...
api("graphics.scenery:scenery:0.9.0")
api("graphics.scenery:scenery:0.11.0")
}
```

Expand Down
Loading

0 comments on commit 118fc84

Please sign in to comment.