<html>
<head>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered)">
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:PMingLiU;
        panose-1:2 2 3 0 0 0 0 0 0 0;}
@font-face
        {font-family:"\@PMingLiU";
        panose-1:2 2 3 0 0 0 0 0 0 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {font-family:Arial;
        color:windowtext;}
@page Section1
        {size:595.3pt 841.9pt;
        margin:56.7pt 42.5pt 56.7pt 85.05pt;}
div.Section1
        {page:Section1;}
/* List Definitions */
ol
        {margin-bottom:0in;}
ul
        {margin-bottom:0in;}
-->
</style>
</head>
<body lang=RU link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>Ok, it sounds a bit
confusing. Let me explain:</span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<ol style='margin-top:0in' start=1 type=1>
<li class=MsoNormal style='color:navy'><font size=2 color=navy face=Arial><span
lang=EN-US style='font-size:10.0pt;font-family:Arial'>I have FOO_PLUGIN
DLL that uses GDAL to read images</span></font><span lang=EN-US> </span></li>
<li class=MsoNormal style='color:navy'><font size=2 color=navy face=Arial><span
lang=EN-US style='font-size:10.0pt;font-family:Arial'>FOO_DLL is located
under PLUGINS/FOO and loaded on-the-fly by the process</span></font><span
lang=EN-US> </span></li>
<li class=MsoNormal style='color:navy'><font size=2 color=navy face=Arial><span
lang=EN-US style='font-size:10.0pt;font-family:Arial'>GDAL13.DLL sits in DGAL_DIR.
PATH variable has GDAL_DIR listed. </span></font></li>
</ol>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>It all works OK for ECW,
TIFF and MrSID. However, when I try to load GIFs, LoadLibrary(FOO_PLUGIN.DLL)
fails with Win32 code 126 (library couldn’t be found) and pop-up appears
– ‘GDAL13.DLL was not found’. </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>When I copy GDAL13.DLL
into my process’ working dir, it starts to complain about HD420M.DLL etc
etc. </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>All these DLLs are in
GDAL_DIR together and yes, GDAL_DIR is listed in PATH. </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>Again, this only happens
when I try to read GIFs. ECW, TIFF and MrSID formats work OK.</span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>I suppose I somehow
should tell GDAL where GDAL13.DLL is located. But how? I couldn’t find
anything in documentation… </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>This is my GDAL
initialization code from FOO_PLUGIN.DLL:</span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-US
style='font-size:10.0pt;font-family:"Courier New"'>
GDALAllRegister();</span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-US
style='font-size:10.0pt;font-family:"Courier New"'>
CPLSetConfigOption("GDAL_PAM_ENABLED", "YES");</span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-US
style='font-size:10.0pt;font-family:"Courier New"'>
CPLSetConfigOption("USE_RRD", "YES");</span></font></p>
<p class=MsoNormal style='text-indent:24.0pt'><font size=2 face="Courier New"><span
lang=EN-US style='font-size:10.0pt;font-family:"Courier New"'>CPLSetConfigOption("HFA_USE_RRD",
"YES");</span></font></p>
<p class=MsoNormal style='text-indent:24.0pt'><font size=2 face="Courier New"><span
lang=EN-US style='font-size:10.0pt;font-family:"Courier New"'> </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>Any help would be greatly
appreciated.</span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>Sergey Malgin</span></font></p>
<p class=MsoNormal><font size=3 color=navy face=Arial><span lang=EN-US
style='font-size:12.0pt;font-family:Arial;color:navy'>ESRI, Inc</span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'> </span></font></p>
</div>
</body>
</html>