forked from Unity-Technologies/UnityRenderStreaming
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Add SampleManager to manage global settings for sample (Unity-Te…
…chnologies#772) * Add scenemanager * fix bug * fix
- Loading branch information
Showing
12 changed files
with
196 additions
and
92 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
com.unity.renderstreaming/Samples~/Example/Scripts/SampleManager.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
namespace Unity.RenderStreaming.Samples | ||
{ | ||
|
||
internal class SampleManager | ||
{ | ||
static SampleManager s_instance; | ||
|
||
public static SampleManager Instance | ||
{ | ||
get | ||
{ | ||
if (s_instance == null) | ||
s_instance = new SampleManager(); | ||
return s_instance; | ||
} | ||
} | ||
|
||
public RenderStreamingSettings Settings | ||
{ | ||
get | ||
{ | ||
return m_settings; | ||
} | ||
} | ||
|
||
RenderStreamingSettings m_settings; | ||
|
||
public void Initialize() | ||
{ | ||
if(m_settings == null) | ||
m_settings = new RenderStreamingSettings(); | ||
} | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
com.unity.renderstreaming/Samples~/Example/Scripts/SampleManager.cs.meta
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.