zimg: fix build using std::size_t where required
This commit is contained in:
parent
92145ef873
commit
588dc8cc95
1 changed files with 50 additions and 0 deletions
50
srcpkgs/zimg/patches/fix-size_t.patch
Normal file
50
srcpkgs/zimg/patches/fix-size_t.patch
Normal file
|
@ -0,0 +1,50 @@
|
|||
--- src/zimg/colorspace/matrix3.cpp 2020-03-02 05:50:02.000000000 +0100
|
||||
+++ src/zimg/colorspace/matrix3.cpp 2020-08-23 20:46:14.298311898 +0200
|
||||
@@ -17,7 +17,7 @@
|
||||
{
|
||||
Vector3 ret;
|
||||
|
||||
- for (size_t i = 0; i < 3; ++i) {
|
||||
+ for (std::size_t i = 0; i < 3; ++i) {
|
||||
ret[i] = v1[i] * v2[i];
|
||||
}
|
||||
return ret;
|
||||
@@ -27,10 +27,10 @@
|
||||
{
|
||||
Vector3 ret;
|
||||
|
||||
- for (size_t i = 0; i < 3; ++i) {
|
||||
+ for (std::size_t i = 0; i < 3; ++i) {
|
||||
double accum = 0;
|
||||
|
||||
- for (size_t k = 0; k < 3; ++k) {
|
||||
+ for (std::size_t k = 0; k < 3; ++k) {
|
||||
accum += m[i][k] * v[k];
|
||||
}
|
||||
ret[i] = accum;
|
||||
@@ -42,11 +42,11 @@
|
||||
{
|
||||
Matrix3x3 ret;
|
||||
|
||||
- for (size_t i = 0; i < 3; ++i) {
|
||||
- for (size_t j = 0; j < 3; ++j) {
|
||||
+ for (std::size_t i = 0; i < 3; ++i) {
|
||||
+ for (std::size_t j = 0; j < 3; ++j) {
|
||||
double accum = 0;
|
||||
|
||||
- for (size_t k = 0; k < 3; ++k) {
|
||||
+ for (std::size_t k = 0; k < 3; ++k) {
|
||||
accum += a[i][k] * b[k][j];
|
||||
}
|
||||
ret[i][j] = accum;
|
||||
@@ -98,8 +98,8 @@
|
||||
{
|
||||
Matrix3x3 ret;
|
||||
|
||||
- for (size_t i = 0; i < 3; ++i) {
|
||||
- for (size_t j = 0; j < 3; ++j) {
|
||||
+ for (std::size_t i = 0; i < 3; ++i) {
|
||||
+ for (std::size_t j = 0; j < 3; ++j) {
|
||||
ret[i][j] = m[j][i];
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue