Esempio n. 1
0
        private void OnStarRenderingComplete(BaseStarDataRenderer renderer, Texture2D texture, bool success)
        {
            if (m_IsCancelled)
            {
                m_BusyRenderingCount = 0;
                return;
            }

            texture.name = TextureNameForStarLayer(renderer.layerId);
            SkyEditorUtility.AddSkyResource(profile, texture);

            AssetDatabase.Refresh();

            if (renderer.layerId == "1")
            {
                profile.starLayer1DataTexture = texture;
            }
            else if (renderer.layerId == "2")
            {
                profile.starLayer2DataTexture = texture;
            }
            else if (renderer.layerId == "3")
            {
                profile.starLayer3DataTexture = texture;
            }

            m_BusyRenderingCount -= 1;

            if (completionCallback != null)
            {
                completionCallback(this, true);
            }
        }