RenderCloudCubemap.cs 942 B

1234567891011121314151617181920212223242526272829
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. namespace Funly.SkyStudio {
  5. [RequireComponent(typeof(Camera))]
  6. public class RenderCloudCubemap : MonoBehaviour {
  7. public enum CubemapTextureFormat
  8. {
  9. RGBColor,
  10. RGBAColor,
  11. RGBALit
  12. };
  13. public const string kDefaultFilenamePrefix = "CloudCubemap";
  14. [Tooltip("Filename of the final output cubemap asset. It will be written to the same directory as the current scene.")]
  15. public string filenamePrefix = kDefaultFilenamePrefix;
  16. [Tooltip("Resolution of each face of the cubemap.")]
  17. public int faceWidth = 1024;
  18. [Tooltip("Format for the exported cubemap. RGBColor (Additive texture), RGBAColor (Color with alpha channel), RGBANormal (Normal lighting data encoded).")]
  19. public CubemapTextureFormat textureFormat = CubemapTextureFormat.RGBALit;
  20. public bool exportFaces;
  21. }
  22. }