summaryrefslogtreecommitdiff
path: root/glitcher
diff options
context:
space:
mode:
authorComment <tim@gray.(none)>2014-03-03 08:26:53 +0000
committerComment <tim@gray.(none)>2014-03-03 08:26:53 +0000
commit8a0124c0853f025555aa21f3190f47b99f419647 (patch)
treefb05b9dc6baec3c42b42b4613bb875d9f5bf261a /glitcher
parent1082e9eed74507b6eb5a3d0d7ab8a6cdecf40e19 (diff)
pretty baffling
Diffstat (limited to 'glitcher')
-rw-r--r--glitcher/src/audioGlitcher.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/glitcher/src/audioGlitcher.h b/glitcher/src/audioGlitcher.h
index 356314b..f8b7e36 100644
--- a/glitcher/src/audioGlitcher.h
+++ b/glitcher/src/audioGlitcher.h
@@ -72,8 +72,8 @@ class audioGlitcher {
for (int j=0;j<srcX.rows;j++){
//srcX.at<float>(j,i)=i*xFactor;
//srcY.at<float>(j,i)=j*yFactor;
- sx[i,j]=i*xFactor;
- sy[i,j]=j*yFactor;
+ sx[j*srcX.cols+i]=i*xFactor;
+ sy[j*srcX.cols+i]=j*yFactor;
}
}
@@ -148,17 +148,18 @@ class audioGlitcher {
}
}
+/*
float* psx = (float*)scaledstX.data;
float* psy = (float*)scaledstY.data;
cerr<<"src: <0,0> "<<sx[0]<<","<<sy[0]<<endl;
- cerr<<"src: <7,5> "<<sx[7*16+5]<<","<<sy[7*16+5]<<endl;
+ cerr<<"src: <7,5> "<<sx[5*16+7]<<","<<sy[5*16+7]<<endl;
cerr<<"src: <8,6> "<<sx[6*16+8]<<","<<sy[6*16+8]<<endl;
- cerr<<"src: <15,11> "<<sx[11*15+11]<<","<<sy[11*15+11]<<endl;
- cerr<<"dest: <7,5> "<<dx[7*16+5]<<","<<dy[7*16+5]<<endl;
+ cerr<<"src: <15,11> "<<sx[11*16+15]<<","<<sy[11*16+15]<<endl;
+ cerr<<"dest: <7,5> "<<dx[5*16+7]<<","<<dy[5*16+7]<<endl;
cerr<<"dest: <8,6> "<<dx[6*16+8]<<","<<dy[6*16+8]<<endl;
cerr<<"Map at <256,192> "<<psx[192*512+256]<<","<<psy[192*512+256]<<endl;
-
+*/
cv::Mat buf = buffer.getCvImage();
cv::Mat dstbuf;