MCPcopy Create free account
hub / github.com/arrayfire/forge / map_range_to_vec_vbo

Function map_range_to_vec_vbo

examples/cpu/bubblechart.cpp:29–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27
28using namespace std;
29void map_range_to_vec_vbo(float range_start, float range_end, float dx,
30 std::vector<float> &vec,
31 float (*map) (float))
32{
33 if(range_start > range_end && dx > 0) return;
34 for(float i=range_start; i < range_end; i+=dx){
35 vec.push_back(i);
36 vec.push_back((*map)(i));
37 }
38}
39
40int main(void)
41{

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected