Menu

problem displaying images

Help
2012-06-12
2013-06-03
  • jamie wright

    jamie wright - 2012-06-12

    dear forum,

    I have just installed and configured GDL today. It appears to be working correctly so far. However I have a problem with displaying images. I have wrote this procedure

    PRO get_image
    file = FILEPATH('gray_scale.jpg',ROOT_DIR='/home/jamie/Documents/gdl/gdl_test_scripts')
    read_jpeg,file, image
    window, xsize=500, ysize=500
    tvscl, image
    END

    which I though would display a jpeg. however it only displays a blank window. i have tested tvscl by typing at the gdl prompt
    >> tvscl, dist(200)
    and an image appears. Therefore I think there is something wrong with the way I am using read_jpeg. Could anyone advise on what I am doing wrong

    tia

     
  • Alain C.

    Alain C. - 2012-06-14

    Which version of GDL are you using ? (I strongly recommend the CVS one, because we worked on READ_JPEG during last months)

    Within the CVS version, please run the code testsuite/test_read_standard_images.pro
    (all 6 test cases should be OK)
    Nevertheless I have 2 other gray scale images with problems.

    Please take into account we have problem in current Ubuntu 12.04 and buggy ImageMagick . In that case, I advice to compile GDL using the configure way, deactivating ImageMagick and activating GraphicsMagick

    Alain

     
  • Mario

    Mario - 2012-07-31

    Hello,
    I have installed gdl on my mac os x 10.6. Everything goes well except that read_image doesn't work. I suspected this may be related to the error I received when I ran gdl:
    GDL - GNU Data Language, Version 0.9.2

    - For basic information type HELP,/INFO
    - No startup file read (GDL_STARTUP/IDL_STARTUP env. var. not set).  

    Then I did something and got the following error the next time I ran gdl:
    GDL - GNU Data Language, Version 0.9.2

    - For basic information type HELP,/INFO
    - Please report bugs, feature or help requests and patches at:
      http://sourceforge.net/projects/gnudatalanguage/

    % Error opening startup file: /Users/MATH/.gdl_startup

    Can anyone please help me fix this? (I am really novice with mac and bash)

     
  • Sylwester Arabas

    Hi,

    The message you described as an error ("No startup file read…") is not an error - startup files are generally only used for some custom configuration, or non-standard installation layouts.

    Please describe how you installed GDL and what you mean by  "read_image doesn't work" - otherwise it's hard to help.

    Sylwester

     
  • Alain C.

    Alain C. - 2012-08-07

    Hum, I also two possible causes of problem:
    1/ do you have the right to write on  /Users/MATH/ (are you the owner, is this dir. in 755 mode ?)
    2/ is your OSX system allows Min/Maj diff ? (this can be tested outside GDL) [I had similar problems,
    not solved up to now, see the testsuite]

    Alain

     
  • Mario

    Mario - 2012-08-14

    I installed gdl with fink.
    I am the administrator user so there is no problem there.
    When I type:
    GDL> tvscl,dist(500)
    an image appears, but when I want to use read_image no image appears:
    GDL> image = read_image(filepath('ch.jpg',root_dir='/users/math/desktop'))
    % Function not found: READ_IMAGE
    % Execution halted at: $MAIN$

     
  • Alain C.

    Alain C. - 2012-08-15

    that is strange, because DIST and READ_IMAGE are in the same dir.

    yes, READ_IMAGE is in the CVS under src/pro
    http://gnudatalanguage.cvs.sourceforge.net/viewvc/gnudatalanguage/gdl/src/pro/

    you can copy all these *.pro and put them into the adequate path in your fink installation
    (I don't know where it is, under Linux it is usually in /usr/local/share/gnudatalangage/lib/pro, somethings like
    that, a "find" or a "locate" should help.)

    Alain

     
  • Alain C.

    Alain C. - 2012-08-15

    Hum, I checked the GDL page in fink and it seems that GDL was "packaged" in fink in Feb 13
    but I added READ_IMAGE to the CVS the 15, Feb !

    You can download all the files in the CVS under the src/pro and substitute them to the older versions
    you have, somewhere in a dir. created by fink !

     

Log in to post a comment.