Hi IOhannes,
Thanks for your quick reply.
i'm pretty suzre, that the resolution of the image does not change, even on OSX. with chnaged "color space", do you mean that the colors are stored in the wrong order? or do you mean that your YUV pix ends up as an ARGB image?
The attached picture named "test.jpg" is what I saved using the attached patch. The original pict in a buffer is like right hand side of another attached picture "screenshot_gemwin.jpg". Somehow colors are changed, the width become half and a picture itself is doubled. This is what I meant changing "color space" and "resolution". Is this not happening on your OSX? With my machine, this phenomena happens not only on OSX lion but also 10.6.8 Snow Leopard.
are you only told that it is CPU-consumptive, or do you experience any actual problems?
In my case this time, I don't face the CPU-consumptive problem yet, because I need to play back and save only 16 frimes from buffers of pix_buffer. Your suggestion patch is one of solutions if I only save few specific frames. However in my another future project, I would like to record longer movie from pix_video and save all frames, it would be more than 1000 to 2000 frames. I am just wondering it would work fine with [pix_rgba] conversion beside regarding the help file description and the past articles on ML as; http://lists.puredata.info/pipermail/gem-dev/2009-03/003895.html
so, which version of Gem are you using?
I am using GEM: ver: 0.92.3.
which image-writing backends are installed (Gem should printout something like "Image saving support: QuickTime")
The printout should be come out on Pd window? There is no printout when saving a frame of pix_buffer. How can I get it?
Cheers,
Sei
-- __/__/__/__/__/__/__/__/__/__/__/__/__/__/__/__/__/ Seiichiro Matsumura
sei@low-tech-ism.com http://low-tech-ism.com/ __/__/__/__/__/__/__/__/__/__/__/__/__/__/__/__/__/
2012/7/10 IOhannes m zmoelnig zmoelnig@iem.at:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 2012-07-10 05:53, Seiichiro MATSUMURA wrote:
Hi,
I try to do the similar thing, capturing from pix_video, saving a specific frame of [pix_buffer] to jpg files. However, the color space and the resolution of saved jpg file is changed. Even saving tiff is the same result.
i'm pretty suzre, that the resolution of the image does not change, even on OSX. with chnaged "color space", do you mean that the colors are stored in the wrong order? or do you mean that your YUV pix ends up as an ARGB image? the latter is not a bug, the former is.
I know one of the ways is converting Gemlist from YUV to RGBA using [pix_rgba] before inputing [pix_buffer_write], but it is told "CPU-consumptive".
are you only told that it is CPU-consumptive, or do you experience any actual problems?
if the conversion is indeed too CPU intensive and you only take snapshots every now and then (not every frame), you could put the [pix_rgba] in a branch that is only executed when needed.
e.g.
gemlist | [r spigot] | | [spigot ] | [t a b] | | | [; spigiot 0( | [pix_rgba] | [r writer] | | [pix_buffer_write foo] | [save /tmp/foo.jpg 0( | [pix__buffer foo[
and click this to capture an image: [; spigot 1; writer 0(
So, is there any solutions to save YUV data in pix_buffer directly to jpg file with keeping colorspace and resolution. I am using Mac OS 10.7.4 and pd-extended 0.42.5.
sorry, i cannot keep track of all the various distributions of Gem.
so, which version of Gem are you using? which image-writing backends are installed (Gem should printout something like "Image saving support: QuickTime")
mfgds IOhannes
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAk/702AACgkQkX2Xpv6ydvQT/QCg1pqNQkZ6XRuhR+PYOWAnt6Lu QHkAoKgfftr7nCytv7dkrZfDC2uRaAUb =W6zJ -----END PGP SIGNATURE-----
Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list