Here is a simple command to create an Image[]:
Image@Table[
With[{z = x + I y},
With[{w = (1 + z + z^2 + z^3)/(1 + z + z^2)}, {Re[w],
Im[w]}]], {x, -1, 1, 0.01}, {y, -1, 1, 0.01}]
It displays correctly in Mathematica. Then I attempt to Export[] this image
with:
Export["e:\\t111409A.jpg", %, "JPEG"]
When I look at the image outside of Mathematica, it does not show correctly.
It looks like only the Alpha channel shows. I also tried these other
$ExportFormats:
- GIF
- TIFF
with the same result.
I imagine there is a simple resolution to this problem, but I cannot
find it yet.
Thanks in advance.
Roger Williams
Franklin Laboratory
But the image is not an RGB image? becuase there is only 2 channels in the
image as can be seen by looking at the dimensions of the data
im = Image[Table[With[{z = x + I*y},
With[{w = (1 + z + z^2 + z^3)/(1 + z + z^2)},
{Re[w], Im[w]}]], {x, -1, 1, 0.01},
{y, -1, 1, 0.01}]]
d = ImageData[im];
Dimensions[d]
{201, 201, 2}
--Nasser
what you wrote makes sense but blue definitely shows up in the image,
even though R=data, G=data, B=no data.
Also I guess I would think that an Export[]ed file would show the same
as what I see on the screen in Mathematica. Finally, I would have thought that
I could just Graphics@Image@....
Ohh well, I will just keep digging....
Regards..RogerW
On Nov 15, 5:49 pm, "Nasser M. Abbasi" <n...@12000.org> wrote:
> <snipped/>
>
> But the image is not an RGB image? becuase there is only 2 channels in the
> image as can be seen by looking at the dimensions of the data
>
> im = Image[Table[With[{z = x + I*y},
> With[{w = (1 + z + z^2 + z^3)/(1 + z + z^2)},
> {Re[w], Im[w]}]], {x, -1, 1, 0.01},
> {y, -1, 1, 0.01}]]
> d = ImageData[im];
> Dimensions[d]
>
> {201, 201, 2}
>
> --Nasser- Hide quoted text -
>
> - Show quoted text -
Here is some more info about this issue:
- 2 workarounds are availble: Rasterize@ or Graphics[{Inset@
- the problem has been reported to and re-created by WRI support
Regards..
Roger Williams
Franklin Laboratory
On Nov 17, 2:23 am, divisor <congruentialumina...@yahoo.com> wrote:
> Thanks Nasser...
>
> what you wrote makes sense but blue definitely shows up in the image,
> even though R=data, G=data, B=no data.
>
> Also I guess I would think that an Export[]ed file would show the same
> as what I see on the screen in Mathematica. Finally, I would have thought=
that
> I could just Graphics@Image@....
>
> Ohh well, I will just keep digging....
>
> Regards..RogerW
>
> On Nov 15, 5:49 pm, "Nasser M. Abbasi" <n...@12000.org> wrote:
>
>
>
> > <snipped/>
>
> > But the image is not an RGB image? becuase there is only 2 channels in =
the
> > image as can be seen by looking at the dimensions of the data
>
> > im = Image[Table[With[{z = x + I*y},
> > With[{w = (1 + z + z^2 + z^3)/(1 + z + z^2)},
> > {Re[w], Im[w]}]], {x, -1, 1, 0.01},
> > {y, -1, 1, 0.01}]]
> > d = ImageData[im];
> > Dimensions[d]
>
> > {201, 201, 2}
>
> > --Nasser- Hide quoted text -
>
> > - Show quoted text -- Hide quoted text -