| 91 | if (comp_ > 3) data[ofs + 3] = c.w; |
| 92 | } |
| 93 | glm::vec4 getPixelFloat(int x, int y) const |
| 94 | { |
| 95 | const int ofs = comp_ * (y * w_ + x); |
| 96 | const float* data = reinterpret_cast<const float*>(data_.data()); |
| 97 | return glm::vec4( |
| 98 | comp_ > 0 ? data[ofs + 0] : 0.0f, |
| 99 | comp_ > 1 ? data[ofs + 1] : 0.0f, |
| 100 | comp_ > 2 ? data[ofs + 2] : 0.0f, |
| 101 | comp_ > 3 ? data[ofs + 3] : 0.0f); |
| 102 | } |
| 103 | |
| 104 | void setPixelUnsignedByte(int x, int y, const glm::vec4& c) |
| 105 | { |
nothing calls this directly
no outgoing calls
no test coverage detected