comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » CALL_EXTERNAL Problem
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
CALL_EXTERNAL Problem [message #1299] Mon, 09 August 1993 15:01 Go to next message
dean is currently offline  dean
Messages: 55
Registered: March 1993
Member
I am attempting to use IDL to call a FORTRAN subroutine with IDL's
CALL_EXTERNAL to read an raster image on a VAX/VMS system. However, I
continue to get a "writable shareable images must be installed" error.
Could you tell me what I maybe doing wrong?

********************************************************** \ *****
Kelly Dean \
Cooperative Institute for Research in the Atmosphere ___\
Foothills Campus /|
Colorado State University / |\
Fort Collins, CO 80523 / | \
E-MAIL: DEAN%SOL.DNET@SIRIUS.CIRA.COLOSTATE.EDU | \
ph: 301-491-8408 | \
************************************************************ **************



========================= IDL error =======================================

%LIB-E-ACTIMAGE, error activating image $15$DIA2:[DEAN.IDL.EXTERNAL]IMX_IO.EXE;2
-SYSTEM-F-NOTINSTALL, writable shareable images must be installed
% CALL_EXTERNAL: Error in called routine.
%

========================= FORTRAN code IMX_IO ===========================

SUBROUTINE IMAGE_I(FILENAME,IMX,IXI,IYI,STATUS)
C
C This routine uses IMX IPL routines ( C code ) to read an IMX formatted
C raster image and passes it out as a 2x2 byte array.
C
INCLUDE 'IPL.INC'
CHARACTER*(*) FILENAME
CHARACTER*1 NULL
INTEGER I,IXI,IYI,STATUS
BYTE IMAGE(IPL_RASTER)
BYTE BUFFI(1024),IMX(1024,1024)
NULL = CHAR(0)
C
C----CONVERT IMAGE
C
CALL IPL_READ_IMAGE (%REF(FILENAME//NULL), IMAGE, STATUS)
IF (STATUS .NE. 0) RETURN
C
C Open IMX image file
C
CALL IPL_GET_IMAGE_SIZE(IMAGE,IXI,IYI)
C
C Move data into another binary array.
C
DO I = 1, IYI
CALL IPL_READ_IMAGE_REC(IMAGE, (I - 1), 1, BUFFI, STATUS)
IF (STATUS .NE. 0) RETURN
CALL LIB$MOVC3(IXI,BUFFI,IMX(1,I)) ! VAX/VMS Call !
ENDDO
C
C
RETURN
END

===============================Command file to compile and link ==========

$ for imx_io
$ link/map imx_io, ipl_lib, sys$input/opt/share
universal = image_i

============================== Procedure that calls the FORTRAN Code =====

PRO display_imx, filename, colorname
iostat = CALL_EXTERNAL('imx_io', $
DEFAULT='ud2:[dean.idl.external].exe', $
'IMAGE_I',filename,image,imx_x,imx_y,ISTATUS)
PRINT, ISTATUS
PRINT, imx_x,imx_y
window, 0, xsize = imx_x, ysize = imx_y, TITLE = filename
TV, image, /ORDER
END
Re: call_external problem [message #5581 is a reply to message #1299] Fri, 05 January 1996 00:00 Go to previous message
zdv131 is currently offline  zdv131
Messages: 1
Registered: January 1996
Junior Member
In article <DKK2w7.GME@Yuri.CC.Uni-Augsburg.DE>, ralfu@Physik.Uni-Augsburg.DE
(Ralf Utermann) writes:
|> Hi all,
|>
|> I just found, that one of my old programs which used a
|> call_external to a fortran subprogram doesn't work anymore
|> with IDL 4.0. (under AIX3.2.5) I get the error message, that
|> it can't find my library -- although its definetely in the
|> current directory. I also cannot get the example to work, which
|> comes with the 4.0 distribution.
|> It worked fine upto 3.6.
|>
|> Thanks for help, Ralf
|>
|> --
|> Ralf Utermann
|> ____________________________________________________________ _________
|> Universitaet Augsburg (Germany), Institut fuer Physik
|> Memmingerstr.6 "Speaking for me and nobody else"
|> D-86135 Augsburg Phone: +49-821-5977-235
|>
SMTP: Ralf.Utermann@Physik.Uni-Augsburg.DE Fax: -222


Hallo
you will have to give the full filepath of the created shared library
(for example: filter.so is the name of the shared library und filter ist the
Fortran program you call)

spawn,'pwd',directory
directory=directory+'/filter.so'
indicator = Call_External( directory(0),'filter',......





--
------------------------------------------------------------ ----------
Marlene Busch
Institut fuer Angewandte Mathematik ZAM E-Mail:
Forschungszentrum Juelich GmbH Ma.Busch@kfa-juelich.de
D-52425 Juelich
Telefon: 02461-614100
------------------------------------------------------------ ----------
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Multi Plot and OverPlot
Next Topic: Framegrabbers and IDL

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 14:32:44 PDT 2025

Total time taken to generate the page: 0.00656 seconds