| 955 | }; |
| 956 | |
| 957 | bool MySprite::setProgramState(backend::ProgramState* programState, bool ownPS/* = false*/) |
| 958 | { |
| 959 | if (Sprite::setProgramState(programState, ownPS)) |
| 960 | { |
| 961 | auto& pipelineDescriptor = _customCommand.getPipelineDescriptor(); |
| 962 | pipelineDescriptor.programState = programState; |
| 963 | |
| 964 | _customCommand.setDrawType(CustomCommand::DrawType::ARRAY); |
| 965 | _customCommand.setPrimitiveType(CustomCommand::PrimitiveType::TRIANGLE_STRIP); |
| 966 | _customCommand.createVertexBuffer(sizeof(V3F_C4B_T2F), 4, CustomCommand::BufferUsage::STATIC); |
| 967 | _customCommand.updateVertexBuffer(&_quad, 4 * sizeof(V3F_C4B_T2F)); |
| 968 | return true; |
| 969 | } |
| 970 | return false; |
| 971 | } |
| 972 | |
| 973 | void MySprite::draw(Renderer* renderer, const Mat4& transform, uint32_t flags) |
| 974 | { |
no test coverage detected