Skip to content

Commit b6b10f1

Browse files
committed
Blob storage loader for glTF
0 parents  commit b6b10f1

28 files changed

+2264
-0
lines changed

.gitignore

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# Unity
2+
[Ll]ibrary/
3+
[Tt]emp/
4+
[Oo]bj/
5+
[Bb]uild/
6+
7+
# Windows
8+
UWP/
9+
Assets/*.pfx
10+
11+
# Builds
12+
*.unitypackage
13+
14+
# Android
15+
*.apk
16+
17+
# Autogenerated VS/MD solution and project files
18+
*.csproj
19+
*.unityproj
20+
*.sln
21+
*.suo
22+
*.tmp
23+
*.user
24+
*.userprefs
25+
*.pidb
26+
*.booproj
27+
*.svd
28+
29+
# Source control temp files
30+
*.orig
31+
32+
# Unity3D generated meta files in directories
33+
*.pidb.meta
34+
*.meta
35+
36+
# Save all .meta files in Assets folder and sub directories
37+
#!Assets/**/*.meta
38+
39+
# Save only .meta files referenced in Unity Editor to prevent missing scripts, prefabs and resources
40+
!Assets/[Pp]refabs/**/*.meta
41+
!Assets/[Rr]esources/**/*.meta
42+
!Assets/[Ss]cenes/**/*.meta
43+
!Assets/[Ss]cripts/**/*.meta
44+
!Assets/TSTableView/**/*.meta
45+
46+
# Unity3D Generated File On Crash Reports
47+
sysinfo.txt
48+
49+
# OS generated
50+
.DS_Store
51+
52+
# IDE
53+
.vs/

.gitmodules

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[submodule "Assets/Dependencies/UnityGLTFLib"]
2+
path = Assets/Dependencies/UnityGLTFLib
3+
url = https://github.com/deadlyfingers/UnityGLTFLib.git
4+
[submodule "Assets/Dependencies/RESTClient"]
5+
path = Assets/Dependencies/RESTClient
6+
url = https://github.com/Unity3dAzure/RESTClient.git
7+
[submodule "Assets/Dependencies/StorageServices"]
8+
path = Assets/Dependencies/StorageServices
9+
url = https://github.com/Unity3dAzure/StorageServices.git

Assets/BlobStorageConfig.cs

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
using Azure.StorageServices;
2+
using System.Collections;
3+
using System.Collections.Generic;
4+
using UnityEngine;
5+
using UnityGLTF;
6+
7+
namespace Azure.StorageServices
8+
{
9+
public class BlobStorageConfig : MonoBehaviour
10+
{
11+
12+
[Header("Azure config")]
13+
[SerializeField]
14+
private string azureAccount;
15+
[SerializeField]
16+
private string azureAppKey;
17+
//
18+
private StorageServiceClient client;
19+
public BlobService Service { get; private set; }
20+
private bool ready = false;
21+
public bool Ready {
22+
get
23+
{
24+
return ready;
25+
}
26+
}
27+
28+
// Use this for initialization
29+
void Awake()
30+
{
31+
if (string.IsNullOrEmpty(azureAccount) ||
32+
string.IsNullOrEmpty(azureAppKey))
33+
{
34+
Debug.LogError("Azure account and key required");
35+
return;
36+
}
37+
// setup blob service
38+
client = new StorageServiceClient(azureAccount, azureAppKey);
39+
Service = new BlobService(client);
40+
ready = true;
41+
}
42+
43+
}
44+
}

Assets/Dependencies/RESTClient

Submodule RESTClient added at 4f985e0

Assets/Dependencies/StorageServices

Submodule StorageServices added at f1321b3

Assets/Dependencies/UnityGLTFLib

Submodule UnityGLTFLib added at f8e859f

0 commit comments

Comments
 (0)