cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X

Importing a JPG file

LHR-disabled
1-Visitor

Importing a JPG file

I�m using MC 2000 Professional, trying to import a color JPG image into a B&W matrix A using A=: READ_IMAGE(�JPGTEST�). But I get error messages: �The image format is not supported� or �Can�t find the data file you�re trying to use�.
The JPG file is in the same directory as the MC files.

I�d appreciate some help

Louis Reynolds
louis_reynolds@msn.com
12 REPLIES 12

It seems to work OK in 2001i.

Jim S.

On 7/2/2009 7:42:26 PM, LHR wrote:
>I�m using MC 2000
>Professional, trying to import
>a color JPG image into a B&W
>matrix A using A=:
>READ_IMAGE(�JPGTEST�). But I
>get error messages: �The image
>format is not supported� or
>�Can�t find the data file
>you�re trying to use�.
>The JPG file is in the same
>directory as the MC files.
>
>I�d appreciate some help
>
>Louis Reynolds
>louis_reynolds@msn.com
_________________________

As a comment to best use Mathcad and especially to evaporate it from the PC and re-install, putting other stuff in the Mathcad install directory is really a bad practice as you can't back up on CD or else media ... do you get my point ?

A=:READ_IMAGE(�JPGTEST�)... is incorrect

A=:READ_IMAGE(�JPGTEST.jpg�)... is correct

jmG

To Jim S.: Thanks. I haven�t moved on from MC 2000 Pro because it does everything I need, and because I read harsh criticisms of the newer versions.

To jmG: Thanks. I�d already tried what you said was correct, to no avail. For example, all the below give an error message.
A:= READ_IMAGE(�DSC04477.JPG�)
A:= READ_IMAGE(�D:\MathCadFiles\DSC04477.JPG�)
file2:= �DSC0477.JPG� A:= READ_IMAGE(file2).

Interestingly, when I added quote marks to the file2 variable, i.e.
A:= READ_IMAGE(�file2�)
I did get a result, but the resulting surface plot was a 3-D �X� , nothing at all like the JPG image I expected.

Would it hurt/help to reload the S/W?

Thanks for your help.

The attached is saved *.jpg, Optimized mode, 100% , i.e: nearly *.bmp quality.

Download in your D\MathcadFiles
it is named BreatherCollab, just leave it as named
then try again Image:=READ_IMAGE("D:\MathcadFiles\BreatherCollab.jpg")

If it does not open, it would indicate your Mathcad 2000 does not read the *.jpg that you had downloaded. The software I used to save jpg is apparently the very basic normalised jpg. There are some jpg format not recognized by Windows , so my IE does not show them on my screen. You may have the opposite situation than mine: your Windows might read non normalised format , you think you have saved them , but scraped by Windows or Mathcad 2000 that does not read the format.

You can do better maybe,

1. capture the screen image
2. paste in Windows Paint, if needed work the image for border, title ...etc
3. from Paint, drag select the image, save as
*.jpg in your MathcadFiles
4. from there try to open.

If could very well be that your Mathcad 2000 does not read the Windows jpg from XP (if you have XP)

jmG

To jmG: Thanks again. Your image files worked for me. I.e,,
A:=READ_IMAGE("D:\MathcadFiles\BreatherCollab.jpg")
and
A:=READ_IMAGE("D:\MathcadFiles\Image29.gif").

As far as I know my 2002 Sony camera saves a normal JPG file. I copy my pictures to my hard drive and can view them, print them myself, print them at Walmart, copy them to a CD, etc., etc. But there is obviously something in the JPG format that MC 2000 Pro can�t handle. I also used Photoshop to convert my JPG file to a BMP file, but again MC wouldn�t read it. (I�m using WIN XP.)

Next I�ll try your Windows Paint procedure.

Louis Reynolds
louis_reynolds@msn.com

On 7/7/2009 8:56:08 PM, LHR wrote:
>As far as I know my 2002 Sony
>camera saves a normal JPG
>file. I copy my pictures to
>my hard drive and can view
>them, print them myself, print
>them at Walmart, copy them to
>a CD, etc., etc. But there is
>obviously something in the JPG
>format that MC 2000 Pro can�t
>handle.

The JPG standard has changed over the years. MC 2000 does not even necessarily implement the JPG standard as it was in 2000; that is the latest possible version of the standard it could implement. I'm sure Walmart is less than 7 years out of date, and can handle a 2002 JPG file.

> I also used Photoshop
>to convert my JPG file to a
>BMP file, but again MC
>wouldn�t read it.

Same problem. Which version of Photoshop? Standards are, in general, actually not very standard.

Richard



http://collab.mathsoft.com/read?125689,20

My understanding is that Mathcad recognizes only the "JPEG Standard", i.e: the entropic part of the coding . But there is lot more with JPEG that Windows recognizes more universally. It seems it does ignore the quantization matrix particular to the camera manufacturers, many have the same .

jmG

Can you post your file? Perhaps there's an encoding that's not correctly supported in Mathcad?


TTFN,
Eden

What does your Mathcad documentation say about supported file formats for that read statement? This is the sort of thing that tends to get updated from release to release (as new formats become popular and time permits). The picture viewer component was added after MC2000, and the supported file formats might well have been expanded at the same time.

If you post a sample file that you cannot read somebody might be able to tell you if it is readable with other Mathcad versions.
__________________
� � � � Tom Gutman

>The picture viewer component was added after MC2000 <<br> _______________________

Oh ! my Mathcad 8 Pro. came c/w the picture viewer.

jmG

To jmG: your Windows Paint procedure worked

Louis Reynolds
louis_reynolds@msn.com

On 7/8/2009 12:08:22 AM, LHR wrote:
>To jmG: your Windows Paint
>procedure worked
>
>Louis Reynolds
>louis_reynolds@msn.com
_______________________

Louis,

I knew it was going to work for you, otherwise I wouldn't dedicate myself so much for helping collabs. Your confirmation is most appreciated and rewarding, thanks.

jmG



Announcements

Top Tags