/// <summary> /// Creates an InstanceFactory used to create new InstanceEntity instances. /// </summary> /// <param name="source">The mesh data information used to create InstanceEntity instances.</param> /// <param name="shader">The shader shared accross all instances</param> /// <returns></returns> public InstanceFactory CreateInstanceFactory(IInstanceSource source, Effect shader) { var instanceFactory = new InstanceFactory(SunBurnCoreSystem.Instance.GraphicsDeviceManager.GraphicsDevice, source, shader); _instanceFactories.Add(instanceFactory); return instanceFactory; }
/// <summary> /// Creates an InstanceFactory used to create new InstanceEntity instances. /// </summary> /// <param name="source">The mesh data information used to create InstanceEntity instances.</param> /// <param name="shader">The shader shared accross all instances</param> /// <returns></returns> public InstanceFactory CreateInstanceFactory(IInstanceSource source, Effect shader) { var instanceFactory = new InstanceFactory(SunBurnCoreSystem.Instance.GraphicsDeviceManager.GraphicsDevice, source, shader); _instanceFactories.Add(instanceFactory); return(instanceFactory); }
/// <summary> /// Creates a new instance of the class /// </summary> /// <param name = "graphicsDevice">The GraphicsDevice instance</param> /// <param name = "source">The mesh data information used to create instances</param> /// <param name = "shader">The shader shared accross all instances</param> /// <remarks> /// The provided shader should be either LightingEffect or DeferredObjectEffect and set is Skinned property to true /// </remarks> protected internal InstanceFactory(GraphicsDevice graphicsDevice, IInstanceSource source, Effect shader) { _graphicsDevice = graphicsDevice; _source = source; _shader = shader; }
public PuttyInstance(IInstanceSource source, string name) { Name = name; Source = source; }
/// <summary> /// Creates a new instance of the class /// </summary> /// <param name = "graphicsDevice">The GraphicsDevice instance</param> /// <param name = "source">The mesh data information used to create instances</param> /// <param name = "shader">The shader shared accross all instances</param> /// <remarks> /// The provided shader should be either LightingEffect or DeferredObjectEffect and set is Skinned property to true /// </remarks> protected internal InstanceFactory(GraphicsDevice graphicsDevice, IInstanceSource source, Effect shader) { _graphicsDevice = graphicsDevice; _source = source; _shader = shader; }