We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpOther Libraries › Displaying JPG from raw data
Page Index Toggle Pages: 1
Displaying JPG from raw data (Read 383 times)
Displaying JPG from raw data
Apr 30th, 2008, 11:42pm
 
Hello,

I am communicating with a device via a Client connection (TCP/IP) that returns a stream of JPEG data. I know the beginning and end of this data.. So imagine I have a string with the data of a JPEG inside of it.

How do i display this image on the field?

It isn't a pixel for pixel map, rather the bits of a compressed image format.


Thanks-
-Jordan
Re: Displaying JPG from raw data
Reply #1 - May 1st, 2008, 10:58pm
 
Check out the source for loadImage() inside PApplet, which handles exactly this situation internally.
Page Index Toggle Pages: 1