On Thursday, 3 September 2015 at 10:28:50 UTC, Suliman wrote:
Hi! Is there any progress?

Update, during todays stream.
Instead of adding scew manipulation instead adding range clever support functions (createImageFrom and assignTo).

ImageImpl image1; // input
ImageImpl[2] image2; // buffers

write("myfile.png",
    image1.rangeOf

    .map!(p => {
        p.y += p.x * addY;
        p.height = addY * p.height;
    })

    .createImageFrom!ImageImpl(image2[0], theAllocator())
    .assignTo(image2[0], RGB8(255, 255, 255))

    .rangeOf
    .flipHorizontalRange
    .rotate90Range
    .flipVerticalRange

    .createImageFrom!ImageImpl(image2[1], theAllocator())
    .copyInto(image2[1])

    .asPNG.toBytes()
);

theAllocator().dispose(image[0]);
theAllocator().dispose(image[1]);

Reply via email to