We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fb1d712 commit c0caaecCopy full SHA for c0caaec
sycl/test-e2e/bindless_images/read_sampled.cpp
@@ -59,11 +59,14 @@ struct util {
59
int *x1) {
60
double pixelCoord;
61
62
+ // sycl::fract stores results into a multi_ptr instead of a raw pointer.
63
+ sycl::private_ptr<double> pPixelCoord = &pixelCoord;
64
+
65
// Subtract to align so that pixel center is 0.5 away from origin.
66
coord = coord - 0.5;
67
- double weight = sycl::fract(coord, &pixelCoord);
- *x0 = static_cast<int>(std::floor(pixelCoord));
68
+ double weight = sycl::fract(coord, pPixelCoord);
69
+ *x0 = static_cast<int>(*pPixelCoord);
70
*x1 = *x0 + 1;
71
return weight;
72
}
0 commit comments