This commit is contained in:
2025-11-15 16:27:19 +08:00
parent 8db6f7b115
commit a0beb9eac7
35 changed files with 886 additions and 128 deletions
@@ -4,6 +4,7 @@
#include "dvc_pre_declare.h"
#include "math/dvc_vector2.h"
#include "math/dvc_vector4.h"
#include "asset/dvc_material.h"
DV_CORE_BEGIN_NAMESPACE
@@ -30,7 +31,7 @@ public:
return (a < b) ? a : b;
}
static DV_CORE_API fVector4 texture2D(const RenderPipe& pipe, const char* textName, const fVector2& uv, const fVector4& defaultValue);
static DV_CORE_API fVector4 texture2D(const RenderPipe& pipe, const Material::TextureInfo& texturePtr, const fVector2& uv, const fVector4& defaultValue);
};
DV_CORE_END_NAMESPACE
@@ -26,8 +26,7 @@ class PixelShaderInterface
public:
virtual const char* getName(void) const = 0;
typedef std::function<size_t(const std::string&)> SetInputAttributeFunc;
virtual void prepare(const RenderPipe* pipe, SetInputAttributeFunc setInputAttributeFunc) = 0;
virtual void prepare(const RenderPipe* pipe, MaterialConstPtr material) = 0;
virtual void process(const VertexDesc& veretexDesc, const float32_t* pixelData, fVector4& color) = 0;
};