MCPcopy Create free account
hub / github.com/axmolengine/axmol / initCustomCommand

Method initCustomCommand

core/navmesh/NavMeshDebugDraw.cpp:62–75  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60}
61
62void NavMeshDebugDraw::initCustomCommand(CustomCommand& command)
63{
64 command.set3D(true);
65 command.setTransparent(true);
66 command.init(0, Mat4::IDENTITY, Node::FLAGS_RENDER_AS_3D);
67 command.setDrawType(CustomCommand::DrawType::ARRAY);
68 auto& pipelineDescriptor = command.getPipelineDescriptor();
69 pipelineDescriptor.programState = _programState;
70
71 auto& blend = pipelineDescriptor.blendDescriptor;
72 blend.blendEnabled = true;
73 blend.sourceRGBBlendFactor = blend.sourceAlphaBlendFactor = BlendFunc::ALPHA_NON_PREMULTIPLIED.src;
74 blend.destinationRGBBlendFactor = blend.destinationAlphaBlendFactor = BlendFunc::ALPHA_NON_PREMULTIPLIED.dst;
75}
76
77void NavMeshDebugDraw::vertex(const float /*x*/,
78 const float /*y*/,

Callers

nothing calls this directly

Calls 2

setTransparentMethod · 0.80
initMethod · 0.45

Tested by

no test coverage detected