MCPcopy Create free account
hub / github.com/RenderKit/embree / get1f

Function get1f

tutorials/common/texture/texture2d.h:39–44  ·  view source on GitHub ↗

! helper function that returns the sampled value for the first channel of the given texture Right now, this function always asks the texture for all four channels, and then discards all but one; later implementations may have specialized 'get1f' methods with the texture \note self may NOT be nullptr! */

Source from the content-addressed store, hash-verified

37 \note self may NOT be nullptr!
38*/
39inline float get1f(const Texture2D *self,
40 const Vec2f where)
41{
42 Vec4f ret = self->get(self, where);
43 return ret.x;
44}
45
46/*! helper function that returns the sampled value for the first three
47 channels of the given texture

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected