annotate Applications/Samples/rt-viewer-demo/build-web.sh @ 685:ea1a5b963798

unit test: VolumeImageGeometry.Basic
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 16 May 2019 17:00:42 +0200
parents 1d9deb4ee84c
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
549
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
1 #!/bin/bash
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
2
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
3 set -e
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
4
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
5 target=${1:-all}
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
6 # this script currently assumes that the wasm code has been built on its side and is availabie in build-wasm/
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
7
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
8 currentDir=$(pwd)
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
9 samplesRootDir=$(pwd)
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
10
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
11 tscOutput=$samplesRootDir/build-tsc-output/
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
12 outputDir=$samplesRootDir/build-web/
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
13 mkdir -p "$outputDir"
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
14
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
15 # files used by all single files samples
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
16 cp "$samplesRootDir/index.html" "$outputDir"
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
17 cp "$samplesRootDir/samples-styles.css" "$outputDir"
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
18
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
19 # build rt-viewer-demo
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
20 cp $samplesRootDir/rt-viewer-demo.html $outputDir
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
21 tsc --project $samplesRootDir/rt-viewer-demo.tsconfig.json --outDir "$tscOutput"
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
22 browserify \
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
23 "$tscOutput/orthanc-stone/Platforms/Wasm/logger.js" \
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
24 "$tscOutput/orthanc-stone/Platforms/Wasm/stone-framework-loader.js" \
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
25 "$tscOutput/orthanc-stone/Platforms/Wasm/wasm-application-runner.js" \
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
26 "$tscOutput/orthanc-stone/Platforms/Wasm/wasm-viewport.js" \
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
27 "$tscOutput/rt-viewer-sample/rt-viewer-demo.js" \
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
28 -o "$outputDir/app-rt-viewer-demo.js"
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
29 cp "$currentDir/build-wasm/RtViewerDemo.js" $outputDir
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
30 cp "$currentDir/build-wasm/RtViewerDemo.wasm" $outputDir
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
31
1d9deb4ee84c Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff changeset
32 cd $currentDir