[Gdal-dev] pct2rgb.py

Dobmeyer, Todd tdobmeye at ball.com
Tue Oct 19 09:30:26 EDT 2004


Frank

> Had you edited the setfw.bat to reflect the path to where you unpacked
it?
> Had you then run setfw.bat in the shell?

I hadn't set the path, but I have now and have run the setfw.bat file
with no problem. Should I run the openev.bat file? I tried to and it
complained that python22.dll was not found.

> I'm a bit surprised you could run gdal_merge.py directly.  Normally
the 
> WinXP command shell does not know how to launch them with python.  Are
you > running this from Cygwin or do you have a regular python
installation on 
> your system?

I don't know what Cygwin is, so I am not running from that. I did
install python onto my machine, but have done nothing with it yet. Now
when I try the gdal_merge.py command that I tried before, I get a pop-up
box saying dynamic link library gdal12.dll could not be located.

> Also, I see you have a space in a parent directory.  This could
possibly
> be a problem, so you might want to try moving the tree temporarily to
the
> root (ie. C:\OpenEV_FW) and see if that works better.  If there is an 
> issue with spaces in the path I will dig into it at my end, but I
would
> appreciate hearing about it.

I get the same error no matter if it is in the C:\OpenEv_Fw or in my
other folder with a space.

I am running everything through Command Prompt. I go to Run and type in
CMD, so I believe I am doing that stuff correctly. Thanks again for your
help.

Todd


-----Original Message-----
From: Frank Warmerdam [mailto:warmerdam at pobox.com] 
Sent: Tuesday, October 19, 2004 9:14 AM
To: Dobmeyer, Todd
Cc: gdal-dev at xserve.flids.com
Subject: Re: [Gdal-dev] pct2rgb.py

Dobmeyer, Todd wrote:
> Frank
> 
> I downloaded the OPENEV_FW zip file that you recommended. I unzipped
it
> into the same folder that has the gdal folder. So both OpenEV_FW and
> gdal are in their own folders inside the same "parent" folder. I typed
> in the command:
> 
> gdal_merge.py -o rgb.tif blue.tif green.tif red.tif -separate
> 
> With the proper filenames of course. When I press Enter in command
> prompt, I receive the following errors. What do they mean?
> 
> Traceback (most recent call last):
>   File "C:\Support Libraries\OpenEV_FW\pymod\gdal_merge.py", line 76,
in
> ?
>     import gdal
>   File "C:\Support Libraries\OpenEV_FW\pymod\gdal.py", line 152, in ?
>     import _gdal
> ImportError: DLL load failed: The specified procedure could not be
> found.

Todd,

Had you edited the setfw.bat to reflect the path to where you unpacked
it?
Had you then run setfw.bat in the shell?

Also, I see you have a space in a parent directory.  This could possibly
be a problem, so you might want to try moving the tree temporarily to
the
root (ie. C:\OpenEV_FW) and see if that works better.  If there is an
issue
with spaces in the path I will dig into it at my end, but I would
appreciate
hearing about it.

Hmm, the other thing I see is that you are running it as gdal_merge.py.
With
the OpenEV_FW package there is a .bat file in the bin directory that
should
normally be used instead of running the python scripts directly.  In
fact, I'm
a bit surprised you could run gdal_merge.py directly.  Normally the
WinXP
command shell does not know how to launch them with python.  Are you
running
this from Cygwin or do you have a regular python installation on your
system?
To ensure that everything in OpenEV_FW works properly it is best to only
run
stuff from the regular CMD.EXE shell, and to ensure you get the
environment
setup by setfw.bat.  This is intended to ensure that the OpenEV_FW
versions of
everything get used, and that the environment is setup properly to find
everything.

Best regards,
-- 
---------------------------------------+--------------------------------
------
I set the clouds in motion - turn up   | Frank Warmerdam,
warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent




More information about the Gdal-dev mailing list