Hello guys,
Please I would like to write a code to translate(shift) an image pixel by pixel in nested loop...
public void Translate(float tx, float ty)
{
for(int i=0;i
{
for(int j=0;j
{
// my code here
}
}
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
FroglegRank #1,020 · 1.9K reputationPosted Feb 3, 2014, 10:12 PM EST
It would be easier to redraw the image in the new location
maher fadi2 reputationPosted Feb 26, 2014, 10:23 PM EST
If you are interested in using a commercial SDK, take a look at leadtools, it has a function to shift the data of an image. Here is a link that might be useful:
http://www.leadtools.com/help/leadtools/v18/dh/pe/leadtools.imageprocessing.effects~leadtools.imageprocessing.effects.offsetcommand.html