Replace textures with QImage.

This commit is contained in:
H. Utku Maden 2024-04-14 22:35:30 +03:00
parent b57d7bed41
commit f07208ebe9

@ -1,3 +1,4 @@
using Quik.Media;
using System;
using System.Collections;
using System.Collections.Generic;
@ -214,7 +215,7 @@ namespace Quik.CommandMachine
}
}
public void Image(QuikTexture texture, in QRectangle rectangle)
public void Image(QImage texture, in QRectangle rectangle)
{
Enqueue(Command.Image);
Enqueue((Frame)(int)ImageCommandFlags.Single);
@ -222,7 +223,7 @@ namespace Quik.CommandMachine
Enqueue(rectangle);
}
public void Image(QuikTexture texture, in QRectangle rectangle, in QRectangle uv)
public void Image(QImage texture, in QRectangle rectangle, in QRectangle uv)
{
Enqueue(Command.Image);
Enqueue((Frame)(int)(ImageCommandFlags.Single | ImageCommandFlags.UVs));
@ -231,7 +232,7 @@ namespace Quik.CommandMachine
Enqueue(uv);
}
public void Image(QuikTexture texture, ReadOnlySpan<QRectangle> rectangles, bool interleavedUV = false)
public void Image(QImage texture, ReadOnlySpan<QRectangle> rectangles, bool interleavedUV = false)
{
int count = rectangles.Length;
ImageCommandFlags flags = ImageCommandFlags.None;
@ -252,7 +253,7 @@ namespace Quik.CommandMachine
}
}
public void Image(QuikTexture texture, ReadOnlySpan<QRectangle> rectangles, ReadOnlySpan<QRectangle> uvs)
public void Image(QImage texture, ReadOnlySpan<QRectangle> rectangles, ReadOnlySpan<QRectangle> uvs)
{
int count = Math.Min(rectangles.Length, uvs.Length);
Enqueue(Command.Image);
@ -266,7 +267,7 @@ namespace Quik.CommandMachine
}
}
public void Image3D(QuikTexture texture, in Image3DCall call)
public void Image3D(QImage texture, in Image3DCall call)
{
Enqueue(Command.Image);
Enqueue(new Frame(ImageCommandFlags.Image3d | ImageCommandFlags.Single));
@ -276,7 +277,7 @@ namespace Quik.CommandMachine
Enqueue(new Frame(call.Layer));
}
public void Image3D(QuikTexture texture, ReadOnlySpan<Image3DCall> calls)
public void Image3D(QImage texture, ReadOnlySpan<Image3DCall> calls)
{
Enqueue(Command.Image);
Enqueue(new Frame((int)ImageCommandFlags.Image3d, calls.Length));