Hi I am working on some POV Poi code and would like to make

Hi I am working on some POV Poi code and would like to make some changes. The code pasted works but only partly. I want to repeat an image down the LEDS multiple times. The current setup has the image in the first half display and the second half is lacking the correct timing or slicing. This code is slightly modified from the teensy forums by mortonkopf
https://forum.pjrc.com/threads/30020-Teensy-APA102-POV-Poi-Pixel-Poi-Build-Tutorial
Anyway, any help? It would be awesome to have this modified so if you use a 88 pixel image, or a 1616 image, it would repeat until the NUM_LEDS is met.

http://pastebin.com/AMJ1vyCG

Looking around here I found Mark Kriegsmans post about dividing the strip into sections and doing animations on two parts. I used this with the POV code and found it works initially, but then it shifts the two images and the second image math is wrong. I am not sure what is going on. Daniel Garcia maybe you can explain? Does the right strip/left strip functions do some sort of switching of the two sides in the fastled library?

http://pastebin.com/t7Rv09me

What do you mean by “wrong math”? My guess by looking into the code is that you have a delay in PoiSonic function. What you want is a function which does only image generation and THEN call in main loop fastLED.show() and some sort of delay. (It is written in the example, by the way).
Right now you calling delays twice - first for upper half and then for lower half. That causes the shift.
P.S. Don’t expect great result from WS2811s in POI field - they are slow and refresh scheme is oldColor->black->newColor.

Meaning I thought maybe the image was being displayed with the wrong number of slices or pixel definition in the pov processing code.
It seems the dual images work now okay using the right and left strip. I would rather figure out how to have the images repeated down the strip multiple times so if its a 16 pixel image it can be repeated over 64 pixels, etc.

Wrong post, oops

http://pastebin.com/pmycpvb1
I attached a new version that clears up what is going on a bit. I am wondering if anyone can help still. The sketch attached displays a POV star. I want to make the star repeat down the line of LEDS. @Daniel_Garcia do you have any ideas? I know using apa102 strips is best for POV. I will change over but I dont think that will effect the code processing will it?

@Ashley_M_Kirchner_No I looked at your poi and wonder if you can help. Your code is to process the image is different and I dont think it has anything like what I am asking about but maybe you can help? POV hoops would need to have images repeated and I am able to get colors repeating above the first image but the time/slice is not correct and Im not sure why.

The simplest method is to simply copy the data. Using your example of 16 pixel image on a 64 pixel string, the first 16 pixels are set from wherever that data comes from. The next 48 pixels are identical, so pixel[16] = pixel[0], pixel[31] = pixel[0], pixel[47] = pixel[0]. Programatically, you can do something like this untested code:

// figure out how many times the image would repeat on a length of strip
repeat = STRIP_LENGTH / IMG_WIDTH; // or height depending on how you’re displaying it
for (i = 0; i < IMG_HEIGHT; i++) {
pixel[i] = IMG_DATA;
// now repeat it
for (r = 1; r < repeat; r++) {
pixel[i + (IMG_HEIGHT * r)] = pixel[i];
}
}
FastLED.show();

That should get you started. Disclaimer, I haven’t had coffee yet nor turned the computer on, so the above code may work, or it may cause your house to go up in flames. Test at your own risk.