Skip to content

Commit

Permalink
[Examples] Make OPC example runnable again
Browse files Browse the repository at this point in the history
  • Loading branch information
hyazinthh committed Aug 1, 2024
1 parent 5e63b00 commit 5b52a1d
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 39 deletions.
2 changes: 2 additions & 0 deletions paket.dependencies
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ nuget Silk.NET.Direct3D9 = 2.15.0

nuget SharpZipLib ~> 1.4.1

nuget Aardvark.PixImage.Pfim ~> 0.9.2

group Test
framework: net6.0
source https://api.nuget.org/v3/index.json
Expand Down
51 changes: 28 additions & 23 deletions paket.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10,58 +10,62 @@ NUGET
Aardvark.Base.Runtime (>= 5.2.7 < 5.3)
FSharp.Core (>= 5.0)
FSharp.Data.Adaptive (>= 1.2.13 < 1.3)
Aardvark.Base (5.2.28)
Aardvark.Base.Telemetry (5.2.28)
Aardvark.Base (5.2.32)
Aardvark.Base.Telemetry (5.2.32)
System.Collections.Immutable (>= 5.0)
System.Reflection.Metadata (>= 5.0) - restriction: || (== net471) (&& (== net6.0) (< netcoreapp3.1)) (&& (== net6.0-windows7.0) (< netcoreapp3.1)) (== netstandard2.0)
System.Text.Json (>= 4.7.2)
Aardvark.Base.Essentials (5.2.28)
Aardvark.Base (5.2.28)
Aardvark.Base.Essentials (5.2.32)
Aardvark.Base (5.2.32)
System.Collections.Immutable (>= 5.0)
Aardvark.Base.FSharp (5.2.28)
Aardvark.Base (5.2.28)
Aardvark.Base.FSharp (5.2.32)
Aardvark.Base (5.2.32)
Aardvark.Base.TypeProviders (>= 4.5.15 < 4.6)
FSharp.Core (>= 5.0)
FSharp.Data.Adaptive (>= 1.2 < 1.3)
FsPickler (>= 5.3.2 < 5.4)
System.Dynamic.Runtime (>= 4.3 < 4.4)
Aardvark.Base.Incremental (5.2.28)
Aardvark.Base (5.2.28)
Aardvark.Base.FSharp (5.2.28)
Aardvark.Base.Incremental (5.2.32)
Aardvark.Base (5.2.32)
Aardvark.Base.FSharp (5.2.32)
Aardvark.Base.TypeProviders (>= 4.5.15 < 4.6)
FSharp.Core (>= 5.0)
FSharp.Data.Adaptive (>= 1.2 < 1.3)
FsPickler (>= 5.3.2 < 5.4)
Aardvark.Base.IO (5.2.28)
Aardvark.Base (5.2.28)
Aardvark.Base.Tensors (5.2.28)
Aardvark.Base.IO (5.2.32)
Aardvark.Base (5.2.32)
Aardvark.Base.Tensors (5.2.32)
System.Dynamic.Runtime (>= 4.3 < 4.4)
Aardvark.Base.Runtime (5.2.28)
Aardvark.Base.FSharp (5.2.28)
Aardvark.Base.Incremental (5.2.28)
Aardvark.Base.Runtime (5.2.32)
Aardvark.Base.FSharp (5.2.32)
Aardvark.Base.Incremental (5.2.32)
Aardvark.Base.TypeProviders (>= 4.5.15 < 4.6)
FSharp.Core (>= 5.0)
FSharp.Data.Adaptive (>= 1.2 < 1.3)
FsPickler (>= 5.3.2 < 5.4)
Aardvark.Base.Telemetry (5.2.28)
Aardvark.Base.Tensors (5.2.28)
Aardvark.Base (5.2.28)
Aardvark.Base.FSharp (5.2.28)
Aardvark.Base.Telemetry (5.2.32)
Aardvark.Base.Tensors (5.2.32)
Aardvark.Base (5.2.32)
Aardvark.Base.FSharp (5.2.32)
FSharp.Core (>= 5.0)
SixLabors.ImageSharp (>= 2.1.3 < 2.2)
Aardvark.Base.TypeProviders (4.5.15)
FSharp.Core (>= 3.1.2.5) - restriction: || (== net471) (&& (== net6.0) (>= net45)) (&& (== net6.0-windows7.0) (>= net45)) (&& (== netstandard2.0) (>= net45))
FSharp.Core (>= 4.2.3) - restriction: || (&& (== net471) (< net45)) (== net6.0) (== net6.0-windows7.0) (== netstandard2.0)
Aardvark.Build (1.0.21)
Aardvark.Geometry (5.2.28)
Aardvark.Base (5.2.28)
Aardvark.Base.FSharp (5.2.28)
Aardvark.Base.Tensors (5.2.28)
Aardvark.Geometry (5.2.32)
Aardvark.Base (5.2.32)
Aardvark.Base.FSharp (5.2.32)
Aardvark.Base.Tensors (5.2.32)
Aardvark.Base.TypeProviders (>= 4.5.15 < 4.6)
FSharp.Core (>= 5.0)
FSharp.Data.Adaptive (>= 1.2 < 1.3)
FsPickler (>= 5.3.2 < 5.4)
Unofficial.LibTessDotNet (>= 2.0.2 < 2.1)
Aardvark.PixImage.Pfim (0.9.2)
Aardvark.Base.Tensors (>= 5.2.32 < 5.3)
FSharp.Core (>= 5.0.1)
Pfim (>= 0.11.2 < 0.12)
AssimpNet (5.0.0-beta1)
NETStandard.Library (>= 1.6.1) - restriction: || (&& (== net471) (< net35)) (== net6.0) (== net6.0-windows7.0) (== netstandard2.0)
CommonMark.NET (0.15.1)
Expand Down Expand Up @@ -142,6 +146,7 @@ NUGET
FSharp.Core (>= 4.7)
FSys (>= 0.0.1 < 0.1)
Newtonsoft.Json (>= 12.0.3)
Pfim (0.11.2)
SharpZipLib (1.4.2)
System.Memory (>= 4.5.4) - restriction: || (== net471) (&& (== net6.0) (< netstandard2.1)) (&& (== net6.0-windows7.0) (< netstandard2.1)) (== netstandard2.0)
System.Threading.Tasks.Extensions (>= 4.5.2) - restriction: || (== net471) (&& (== net6.0) (< netstandard2.1)) (&& (== net6.0-windows7.0) (< netstandard2.1)) (== netstandard2.0)
Expand Down
1 change: 1 addition & 0 deletions src/Examples (netcore)/33 - Opc/33 - Opc.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
<OutputPath>..\..\..\bin\Release</OutputPath>
</PropertyGroup>
<ItemGroup>
<None Include="paket.references" />
<Compile Include="Overlay.fs" />
<Compile Include="Program.fs" />
</ItemGroup>
Expand Down
8 changes: 6 additions & 2 deletions src/Examples (netcore)/33 - Opc/Program.fs
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,11 @@ type PatchLodTree(globalCenter : V3d, opc : OpcPaths, root : option<ILodTreeNode

let img =
let path = Patch.extractTexturePath opc patch.info 0
try PixImage.Load(path).ToPixImage<byte>(Col.Format.RGBA)
with _ -> DefaultTextures.checkerboardPix
try
PixImage.Load(path).ToPixImage<byte>(Col.Format.RGBA)
with e ->
Log.error "[Opc] %s" e.Message
DefaultTextures.checkerboardPix

let tex =
{ new INativeTexture with
Expand Down Expand Up @@ -475,6 +478,7 @@ let main argv =
|> Sg.uniform "ProjTrafo" proj
|> Sg.uniform "MipMaps" mipMaps
|> Sg.uniform "Anisotropic" anisotropic
|> Sg.diffuseTexture' nullTexture
|> Sg.viewTrafo views
|> Sg.projTrafo proj

Expand Down
15 changes: 1 addition & 14 deletions src/Examples (netcore)/33 - Opc/paket.references
Original file line number Diff line number Diff line change
@@ -1,15 +1,2 @@
Aardvark.Base.Essentials
Aardvark.Base.Incremental
Aardvark.Base.Runtime
AssimpNet
FShade.Core
FShade.GLSL
FSharp.Core
Unofficial.Typography
Unofficial.LibTessDotNet
Unofficial.OpenTK

Unofficial.OpenVR
FShade.Debug
SixLabors.ImageSharp
Aardvark.Build
Aardvark.PixImage.Pfim

0 comments on commit 5b52a1d

Please sign in to comment.