[WIP] Desktop live stream from openFrameworks to HTML5 canvas

Tried sending screengrabs to a web page by using node.js via websockets and UDP connection. The output on HTML5 canvas is updated square by square, hence the disjointed image:

Screenshot (196)

Result: Really really slow. I have known that UDP is faster than TCP but there is a size limit to the amount of data sent each time (hence the image made up of smaller pieces).

oF app sends screenshot in pieces:Screenshot (198)

Javascript on web page places the pieces together:

Screenshot (197)

Bottomline: time to find another method.

Posted in CAP

[WIP] Shaders for Digital Manipulation

How can we believe anything we see anymore? With today’s technology, we can literally do anything we want with images.

When photography was first invented, its overwhelming power came from the fact that it recorded nature more realistically than any other art form had ever done before. Because of this, people trusted it and believed it portrayed “reality” and “truth”.

But, just as story telling could portray the “truth” with an accurate accounting of the facts, it could just as easily become fiction. Fake and manipulated photographs – visual fiction – began circulating not long after the invention of photography.

– J. Lodriguss, The Ethics of Digital Manipulation

Using GLSL shaders with oF, I explored a few basic image manipulation techniques. Shaders allowed for the distortion to stay even when the image has changed (see images for Blur):


Screenshot (186)


Screenshot (192)


Screenshot (187)Screenshot (188)Screenshot (189)

Posted in CAP

[WIP] Desktop Streaming in C++ & openFrameworks

I am working on getting a real-time stream of the desktop to display in openFrameworks (for further work).

Using the Windows API, an image of the screen in HBITMAP (handler) is acquired, then a BITMAP byte array from the HBITMAP.

I am currently translating the BITMAP BYTE array to ofPixel array:


I tried saving the screen as a .bmp file and everything looks fine, but when trying to assign values to the ofPixels array (so that further image manipulation can be done in openFrameworks), the resulting image is as shown above.

So, I am trying to get around this by looking at the raw array values and figuring out how I could be assigning the values wrongly.

[Update 7 Feb 2017:]

After realising that bitmap colours are stored as Blue-Green-Red-Alpha in the byte array instead of the usual RGBA, I switched the values appropriately when creating ofColor to set the pixel colour in the ofPixel object.

Just in case there was something wrong with how I calculated the index of the pixel’s location in ofPixel, I tried using the same function with a different set of parameters:

ofPixels::setColor(int x, int y, ofColor newColor)

instead of calculating the index for this function to set the colours of the output image:

ofPixels::setColor(int index, ofColor newColor)

It worked perfectly and I feel stupid now after spending so much time trying to figure out what was wrong. Yay.




Posted in CAP

Mafavuke’s Trial and Other Plant Stories, 2016

Mafavuke’s Trial and Other Plant Stories, 2016
Uriel Orlow and other invited artists

This exhibition presents a major new work by London-based artist Uriel Orlow, commissioned by The Showroom, which looks to the botanical world as a stage for politics at large through film, photography, installation and sound.

Continue reading “Mafavuke’s Trial and Other Plant Stories, 2016”

Posted in CAP