Ejemplo n.º 1
0
        /// <summary>
        /// Removes the GameView from being used in the composite render module
        /// and disposes of the CompositeRenderContext for that view.
        /// </summary>
        void TearDownGameView()
        {
            m_MarsSessionCamera = null;

            if (m_SessionRenderContext != null)
            {
                m_SessionRenderContext.Dispose();
                m_SessionRenderContext = null;
            }
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Removes a view from being used in the composite render module
        /// and disposes of the CompositeRenderContext for that view.
        /// </summary>
        /// <param name="scriptableObject">ScriptableObject to be removed.</param>
        /// <param name="compositeRenderContext">The render context to remove.</param>
        /// <param name="removeFromCollection">Should the view be removed from the collection.</param>
        void RemoveView(ScriptableObject scriptableObject, CompositeRenderContext compositeRenderContext, bool removeFromCollection)
        {
            m_SimulationSceneModule?.UnregisterSimulationUser(scriptableObject);

            compositeRenderContext?.Dispose();

            if (!removeFromCollection)
            {
                m_CompositeViewRenderContexts.Remove(scriptableObject);
            }
        }