You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
859 B
29 lines
859 B
using UnityEngine;
|
|
|
|
namespace UnityEditor.VFX.Operator
|
|
{
|
|
[VFXHelpURL("Operator-BufferCount")]
|
|
[VFXInfo(name = "Graphics Buffer Count", category = "Sampling")]
|
|
class BufferCount : VFXOperator
|
|
{
|
|
public override string name { get { return "Graphics Buffer Count"; } }
|
|
|
|
public class InputProperties
|
|
{
|
|
[Tooltip("Sets the Graphics Buffer to retrieve count.")]
|
|
public GraphicsBuffer buffer = null;
|
|
}
|
|
|
|
public class OutputProperties
|
|
{
|
|
[Tooltip("The Graphics Buffer count.")]
|
|
public uint count;
|
|
}
|
|
|
|
protected override sealed VFXExpression[] BuildExpression(VFXExpression[] inputExpression)
|
|
{
|
|
var count = new VFXExpressionBufferCount(inputExpression[0]);
|
|
return new VFXExpression[] { count };
|
|
}
|
|
}
|
|
}
|