forked from MoonsideGames/MoonWorks
remove Bit from flags enum
parent
ce27a4bc4c
commit
66e0fe9924
|
@ -85,8 +85,8 @@ namespace MoonWorks.Graphics
|
||||||
[Flags]
|
[Flags]
|
||||||
public enum TextureUsageFlags : uint
|
public enum TextureUsageFlags : uint
|
||||||
{
|
{
|
||||||
SamplerBit = 1,
|
Sampler = 1,
|
||||||
ColorTargetBit = 2
|
ColorTarget = 2
|
||||||
}
|
}
|
||||||
|
|
||||||
public enum SampleCount
|
public enum SampleCount
|
||||||
|
|
|
@ -20,8 +20,8 @@ namespace MoonWorks.Graphics
|
||||||
uint levelCount = 1
|
uint levelCount = 1
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
var flags = TextureUsageFlags.ColorTargetBit;
|
var flags = TextureUsageFlags.ColorTarget;
|
||||||
if (canBeSampled) { flags |= TextureUsageFlags.SamplerBit; }
|
if (canBeSampled) { flags |= TextureUsageFlags.Sampler; }
|
||||||
|
|
||||||
var texture = Texture.CreateTexture2D(
|
var texture = Texture.CreateTexture2D(
|
||||||
device,
|
device,
|
||||||
|
@ -41,8 +41,8 @@ namespace MoonWorks.Graphics
|
||||||
public ColorTarget(GraphicsDevice device, SampleCount sampleCount, ref TextureSlice textureSlice) : base(device)
|
public ColorTarget(GraphicsDevice device, SampleCount sampleCount, ref TextureSlice textureSlice) : base(device)
|
||||||
{
|
{
|
||||||
Handle = Refresh.Refresh_CreateColorTarget(
|
Handle = Refresh.Refresh_CreateColorTarget(
|
||||||
device.Handle,
|
device.Handle,
|
||||||
(Refresh.SampleCount) sampleCount,
|
(Refresh.SampleCount) sampleCount,
|
||||||
textureSlice.ToRefreshTextureSlice()
|
textureSlice.ToRefreshTextureSlice()
|
||||||
);
|
);
|
||||||
TextureSlice = textureSlice;
|
TextureSlice = textureSlice;
|
||||||
|
|
|
@ -30,7 +30,7 @@ namespace MoonWorks.Graphics
|
||||||
textureCreateInfo.IsCube = false;
|
textureCreateInfo.IsCube = false;
|
||||||
textureCreateInfo.LevelCount = 1;
|
textureCreateInfo.LevelCount = 1;
|
||||||
textureCreateInfo.SampleCount = SampleCount.One;
|
textureCreateInfo.SampleCount = SampleCount.One;
|
||||||
textureCreateInfo.UsageFlags = TextureUsageFlags.SamplerBit;
|
textureCreateInfo.UsageFlags = TextureUsageFlags.Sampler;
|
||||||
|
|
||||||
var texture = new Texture(device, textureCreateInfo);
|
var texture = new Texture(device, textureCreateInfo);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue