/// <summary> /// Displays Texture3D Mask Area /// </summary> private void DisplayTexture3DMaskArea() { EditorGUILayout.BeginVertical(GuiStyles.Background); GuiHelpers.DrawToggleChecker(ref _texture3DMaskBoolProperty, new GUIContent("Texture3D Mask", Aura.ResourcesCollection.texture3DIconTexture, "The \"Texture Mask\" allows to assign a texture mask to the volume.\nRGB -> Will multiply the \"Strength\" parameter of the Color Injection.\nA -> Will multiply the \"Strength\" parameter of the Density and Scattering Injection"), true, true); if (_texture3DMaskBoolProperty.boolValue) { //EditorGUI.BeginDisabledGroup(!_texture3DMaskBoolProperty.boolValue); EditorGUILayout.BeginVertical(GuiStyles.EmptyMiddleAligned); GUILayout.Label(new GUIContent(" Experimental Feature (PREVIEW)", Aura.ResourcesCollection.experimentalIconTexture), GuiStyles.LabelBoldCentered); EditorGUILayout.BeginHorizontal(); GUILayout.Label("Texture3D Mask", GuiStyles.Label, GUILayout.MaxWidth(100)); EditorGUILayout.PropertyField(_texture3DMaskTextureProperty, new GUIContent("")); EditorGUILayout.EndHorizontal(); Texture3D textureMask = (Texture3D)_texture3DMaskTextureProperty.objectReferenceValue; if (textureMask != null) { if (textureMask.width != VolumesCommonDataManager.texture3DMaskSize || textureMask.height != VolumesCommonDataManager.texture3DMaskSize || textureMask.depth != VolumesCommonDataManager.texture3DMaskSize) { GuiHelpers.DrawHelpBox("The Texture3D mask \"" + textureMask.name + "\" of \"" + _currentVolume.name + "\" volume is not of the required size, which is " + VolumesCommonDataManager.texture3DMaskSize + "³", HelpBoxType.Warning); } } EditorGUILayout.Separator(); EditorGUILayout.Separator(); GuiHelpers.DrawTransformField(ref _texture3DMaskTransformProperty); EditorGUILayout.EndVertical(); //EditorGUI.EndDisabledGroup(); } EditorGUILayout.EndVertical(); }
/// <summary> /// Displays Noise Mask Area /// </summary> private void DisplayNoiseMaskArea() { EditorGUILayout.BeginVertical(GuiStyles.Background); GuiHelpers.DrawContextualHelpBox("The \"Noise Mask\" parameter allows you to assign a dynamic morphing noise mask to the volume.\nThis noise will be used for masking the data injected."); GuiHelpers.DrawToggleChecker(ref _noiseMaskBoolProperty, new GUIContent("Noise Mask", Aura.ResourcesCollection.noiseIconTexture), true, true); if (_noiseMaskBoolProperty.boolValue) { //EditorGUI.BeginDisabledGroup(!_noiseMaskBoolProperty.boolValue); EditorGUILayout.BeginVertical(GuiStyles.EmptyMiddleAligned); GuiHelpers.DrawFloatField(ref _noiseMaskSpeedProperty, new GUIContent("Speed", "Speed of the morph")); EditorGUILayout.Separator(); EditorGUILayout.Separator(); GuiHelpers.DrawTransformField(ref _noiseMaskTransformProperty); EditorGUILayout.EndVertical(); //EditorGUI.EndDisabledGroup(); } EditorGUILayout.EndVertical(); }