示例#1
0
        internal static Shader3D GenerateShader3D(swig.Shader3D o, GenerationType type)
        {
            if (o == null)
            {
                return(null);
            }
            var p = o.GetPtr();

            var existing = GC.Shader3Ds.GetObject(p);

            existing = GenerateInternal(existing, o, type);
            if (existing != null)
            {
                return(existing);
            }

            var ret = new Shader3D(o);

            GC.Shader3Ds.AddObject(p, ret);
            return(ret);
        }
示例#2
0
        /// <summary>
        /// マテリアル(3D)を生成する。
        /// </summary>
        /// <param name="shader">シェーダー</param>
        /// <returns>マテリアル(3D)</returns>
        public Material3D CreateMaterial3D(Shader3D shader)
        {
            var material = CoreInstance.CreateMaterial3D_(shader.CoreInstance);

            return(GC.GenerateMaterial3D(material, GenerationType.Create));
        }
示例#3
0
 /// <summary>
 /// マテリアル(3D)を生成する。
 /// </summary>
 /// <param name="shader">シェーダー</param>
 /// <returns>マテリアル(3D)</returns>
 public Material3D CreateMaterial3D(Shader3D shader)
 {
     var material = graphics.CreateMaterial3D_(shader.CoreInstance);
     return GC.GenerateMaterial3D(material, GC.GenerationType.Create);
 }
示例#4
0
 public void SetShader2D(string name, Shader3D value)
 {
     CoreInstance.SetShader3D(value.CoreInstance);
 }
示例#5
0
 public void SetShader2D(string name, Shader3D value)
 {
     CoreInstance.SetShader3D(value.CoreInstance);
 }