载入中...
搜索中...
未找到
#include "graphics/Shader.h"#include <cstdint>#include <string>#include <vector>#include <glm/glm.hpp>类 | |
| struct | eve::graphics::grass::Point |
| struct | eve::graphics::grass::SampleParams |
| struct | eve::graphics::grass::BillboardMesh |
| struct | eve::graphics::grass::PackedAtlasInfo |
| Layout of a packed 2x2-per-variant sway atlas (4 grass + 2 leaf typical). 更多... | |
| class | eve::graphics::GrassField |
| Dense grass + sparse dark tufts on a mesh. Caller owns GrassField*; GPU Mesh / Shader / Texture are owned by Graphics. 更多... | |
| struct | eve::graphics::GrassField::BakeParams |
命名空间 | |
| namespace | eve |
| namespace | eve::graphics |
| 卡牌游戏 UI 工具模块:工厂 + 脚本绑定入口。 功能参考 ycarowr/UiCard:扇形手牌布局、抽牌/洗牌、悬浮放大、拖拽到落牌区、 敌方手牌(背面/偷看)、费用不足置灰,以及可实时调节的布局参数。 数据模型与渲染/交互逻辑见 CardTypes.h。 | |
| namespace | eve::graphics::grass |
| t3ssel8r-style stylized grass. | |
函数 | |
| std::vector< Point > | eve::graphics::grass::samplePoisson (const float *posXYZ, const float *nrmXYZ, int vertexCount, const uint32_t *indices, int indexCount, const SampleParams ¶ms={}) |
| Fast Poisson-disk / dart-throwing blue noise on a triangle mesh. | |
| std::vector< Point > | eve::graphics::grass::sampleHalton (const float *posXYZ, const float *nrmXYZ, int vertexCount, const uint32_t *indices, int indexCount, int count, uint32_t seed=1, float minSlopeDot=0.25f) |
| Area-weighted Halton samples (deterministic, evenly spread). | |
| BillboardMesh | eve::graphics::grass::buildBillboards (const std::vector< Point > &points, float width=0.62f, float height=0.95f, bool alwaysDark=false) |
| Expand a unit rectangle per point. Vertex layout: pos = grass root uv = quad corner in [0,1]^2 (0.5, 0) is the root normal.x = instance id, normal.y = scale, normal.z = alwaysDark (0/1) | |
| int | eve::graphics::grass::swayFrame (float time, float frameDuration, uint32_t instanceId, int frameCount=4) |
| Discrete 4-frame index with a per-instance phase offset. | |
| void | eve::graphics::grass::makeSwayAtlasRGBA (int frameW, int frameH, int frames, std::vector< uint8_t > &rgbaOut) |
| Procedural 4-frame fallback atlas (horizontal strip). GPU paths should load authored 2x2 PNG masks via packSwayAtlasRGBA / createSwayAtlasFromFiles. | |
| int | eve::graphics::grass::swayAtlasWidth (int frameW, int frames) |
| int | eve::graphics::grass::swayAtlasHeight (int frameH) |
| Texture * | eve::graphics::grass::createSwayAtlas (Graphics *gfx, int frameW, int frameH, int frames) |
| void | eve::graphics::grass::packSwayAtlasRGBA (const std::vector< std::string > &grassFiles, const std::vector< std::string > &leafFiles, std::vector< uint8_t > &rgbaOut, PackedAtlasInfo &info) |
| Load white-on-black (or RGBA) 2x2 sway PNGs and pack them into one atlas. | |
| Texture * | eve::graphics::grass::createSwayAtlasFromFiles (Graphics *gfx, const std::vector< std::string > &grassFiles, const std::vector< std::string > &leafFiles, PackedAtlasInfo *infoOut) |
| Shader * | eve::graphics::grass::createShader (Graphics *gfx) |
| void | eve::graphics::grass::bindDefaults (Shader *shader) |
| void | eve::graphics::grass::bindLayer (Shader *shader, bool alwaysDark) |
| void | eve::graphics::grass::bindAtlasLayout (Shader *shader, const PackedAtlasInfo &info) |
| void | eve::graphics::grass::setTime (Shader *shader, float seconds) |
| void | eve::graphics::grass::setFrameDuration (Shader *shader, float seconds) |
| int | eve::graphics::grass::paramCount () |
| std::string | eve::graphics::grass::paramName (int index) |
| void | eve::graphics::grass::makePlane (float sizeX, float sizeZ, int segX, int segZ, std::vector< float > &posXYZ, std::vector< float > &nrmXYZ, std::vector< uint32_t > &indices) |
| Unit XZ plane (Y-up) for tests / demos. | |