Esempio n. 1
0
    void InitializeSettings()
    {
        if (settingsInitialized == false)
        {
            Debug.Log("Initializing Metallic Settings");
            MS = new MetallicSettings();

            _MetalColorMap = new Texture2D(1, 1, TextureFormat.ARGB32, false, true);
            _MetalColorMap.SetPixel(1, 1, MS.MetalColor);
            _MetalColorMap.Apply();

            settingsInitialized = true;
        }
    }
Esempio n. 2
0
    private void InitializeSettings()
    {
        if (_settingsInitialized)
        {
            return;
        }
        Debug.Log("Initializing Metallic Settings");
        _metallicSettings = new MetallicSettings();

        _metalColorMap = new Texture2D(1, 1, TextureFormat.ARGB32, false, true);
        _metalColorMap.SetPixel(1, 1, _metallicSettings.MetalColor);
        _metalColorMap.Apply();

        _settingsInitialized = true;
    }
Esempio n. 3
0
    public void SetValues(ProjectObject projectObject)
    {
        InitializeSettings();
        if (projectObject.MS != null)
        {
            MS = projectObject.MS;
        }
        else
        {
            settingsInitialized = false;
            InitializeSettings();
        }

        _MetalColorMap.SetPixel(1, 1, MS.MetalColor);
        _MetalColorMap.Apply();

        doStuff = true;
    }
Esempio n. 4
0
    public void SetValues(ProjectObject projectObject)
    {
        InitializeSettings();
        if (projectObject.MetallicSettings != null)
        {
            _metallicSettings = projectObject.MetallicSettings;
        }
        else
        {
            _settingsInitialized = false;
            InitializeSettings();
        }

        _metalColorMap.SetPixel(1, 1, _metallicSettings.MetalColor);
        _metalColorMap.Apply();

        _doStuff = true;
    }