[GRASS-dev] digitize error

2010-06-16 Thread Mohammed Rashad
First I select add vector from menu
and selection digitize from toolbar
when selecting map from combobox, the following error is displayed.

Unable to initialize display driver of vector digitizer. See 'Command output' 
for details.

Reason: message=_(Unable to initialize display driver of vector 

Traceback (most recent call last):
  File /usr/local/grass-6.5.svn/etc/wxpython/gui_modules/toolbars.py, line 
1130, in StartEditing
message=_(Unable to initialize display driver of vector 
DigitError: unprintable DigitError object

 
I think problem is

from gui_modules.toolbars.py
Line:1128
try:
if not self.parent.MapWindow.CheckPseudoDC():

and gui_modules.mapdisp_window.py
self.pdc.SetBackground(wx.Brush(self.GetBackgroundColour()))
Line :277
argument 2 expected of type wx.Brush


--
Rashad



  ___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] (no subject)

2010-06-16 Thread Maris Nartiss
Hello Ken,
--enable-64bit doesn't deal with GRASS 64bitness in direct way. What
You should had looking for was compiling 32bit apps on 64bit OS.

Regarding float overflow - it makes sense. Can You attach a patch to
trac ticket? I (or somebody else) will take a look at it and commit to
SVN.

Thanks for spotting this. Moving conversation to -dev.

Maris.

2010/6/16 Ken Kwasnicki ken.kwasni...@gmail.com:
 Yes, I my slackware can run 32bit apps. I tried recompiling grass without
 the --enable-64bit option but still had the same nviz problem , although i
 expect i'm still compiling to 64bit.

 However, I've looked at the togl_flythrough.c code and found the problem.
 Or at least found a change the fixes this on my system.

 I had added some debug output to mouse_valuator just to show the thisTime
 value, initially I just wanted to see if I would even see the output from a
 printf statement when running nviz.  What I noticed was that the seconds
 value for thisTime was not incrementing, only the decimal part was changing,
 which I guess is why the view would return to its original position after a
 1 second lapse.

 in the function this_time the time values are being cast to float which is
 maxing out so i changed them to double which is the return value anyway.
 so, i changed this line [320]:
 return ((float)tv.tv_sec + ((float)tv.tv_usec / 100.0));
 to:
 return ((double)tv.tv_sec + ((double)tv.tv_usec / 100.0));

 and that appears to have fixed the problem.  the same change may need to be
 made for the MINGW32 version of the code, but I left that alone.

 i've made this change in my download of the 6.4.0RC6 version of the code but
 for now I'll leave it up to you, or others to make this change as I'm
 currently not set up to submit code.

 thanks!
 ken


 On 06/15/2010 12:53 PM, Maris Nartiss wrote:

 Hello,
 at first - You can compile 32bit version on 64bit machine (if it's
 possible on Slackware).

 Second - once I took a look at code. It was not good, still I didn't
 managed to find the root cause.
 Fly mode is TCL/C hybrid.
 TCL part is here:
 http://trac.osgeo.org/grass/browser/grass/branches/develbranch_6/visualization/nviz/scripts
 (flythrough.tcl)
 Some support is located in nviz/src/ (togl_flythrough.c)
 Main rendering is done by OGSF lib/ogsf

 OGSF should be fine, problem is somewhere in nviz part. Probably in
 C/TCL interaction.

 Good luck.
 If You need some help with coding, feel free to as at grass-dev ML. We
 are short on resources and thys any help is wecomed.

 Maris.


 2010/6/15, Ken Kwasnicki ken.kwasni...@gmail.com:


 Hi Maris,
 Thanks for the reply!  Too bad. I guess I'll have to install on a 32bit
 system.  For what it's worth my system is Slackware 13.0 64bit and also
 Nvidia driver, so nothing really new to add to the bug report other than the
 variance in linux distribution.

 Any speculation where this bug might occur in the nviz code?  Just in case
 I'm feeling ambitious enough to take a crack at debugging it.

 Thanks,
 Ken


 On 06/15/2010 12:14 AM, Maris Nartiss wrote:


 Known issue, currently no fix.

 http://trac.osgeo.org/grass/ticket/46

 Maris.


 2010/6/14, Kwas ken.kwasni...@gmail.com:



 Helo,
 I've used NVIZ in the past and not had this problem but after rebuilding
 Grass/Nviz for a new system (Slackware 13 64bit)  I now find when I try
 to
 fly to move the landscape it keeps resetting back to its originall
 position after a few frames.ie: it will start to move in the
 direction
 of my mouse motion but then keeps jumping back so that I am unable to
 zoom
 in or position the view where I want.

 Has anybody seen this problem before or know what I should do to fix it?
 Appreciate any assistance.
 Thanks,
 Ken
 --
 View this message in context:
 http://osgeo-org.1803224.n2.nabble.com/NVIZ-help-fly-keeps-resetting-jumping-back-to-center-tp5178852p5178852.html
 Sent from the Grass - Users mailing list archive at Nabble.com.
 ___
 grass-user mailing list
 grass-u...@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/grass-user







___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev


[GRASS-dev] GRASS startup behaviour on Win differs from Unix

2010-06-16 Thread Benjamin Ducke
Hi all,

when I start GRASS from a Linux shell, going through Init.sh,
I can supply the name of a mapset and GRASS will automatically
log into that.

When I do the same in Windows, from cmd.exe and going through
Init.bat, I always get the interactive login screen. Is that
intented behaviour? Or is there something I am doing wrong with
the mapset path specification?

Linux:

grass64 $HOME/grassdb/test/usr

- logs straight into mapset

Win:

grass64.bat c:\grassdb\test\user

- goes to interactive login


Cheers,

Ben


--
Files attached to this email may be in ISO 26300 format (OASIS Open Document 
Format). If you have difficulty opening them, please visit http://iso26300.info 
for more information.

___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev


[GRASS-dev] Fw: digitize error

2010-06-16 Thread Mohammed Rashad


 Traceback (most recent call last):
  File /home/rashad/data_catalog/mapdisplay.py, line 388, in CheckPseudoDC
self.pdc.SetBackground(b)
  File /usr/local/grass-6.5.svn/etc/wxpython/vdigit/grass6_wxvdigit.py, line 
384, in SetBackground
def SetBackground(self, *args): return 
_grass6_wxvdigit.PseudoDC_SetBackground(self, *args)
TypeError: in method 'PseudoDC_SetBackground', argument 2 of type 'wxBrush 
const '

--
Rashad



- Forwarded Message 
From: Mohammed Rashad rasha...@yahoo.com
To: grass-dev@lists.osgeo.org
Sent: Wed, June 16, 2010 1:23:52 PM
Subject: digitize error


First I select add vector from menu
and selection digitize from toolbar
when selecting map from combobox, the following error is displayed.

Unable to initialize display driver of vector digitizer. See 'Command output' 
for details.

Reason: message=_(Unable to initialize display driver of vector 

Traceback (most recent call last):
  File /usr/local/grass-6.5.svn/etc/wxpython/gui_modules/toolbars.py, line 
1130, in StartEditing
message=_(Unable to initialize display driver of vector 
DigitError: unprintable DigitError object

 
I think problem is

from gui_modules.toolbars.py
Line:1128
try:
if not self.parent.MapWindow.CheckPseudoDC():

and gui_modules.mapdisp_window.py
self.pdc.SetBackground(wx.Brush(self.GetBackgroundColour()))
Line :277
argument 2 expected of type wx.Brush


--
Rashad


  ___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] access to grass (trunk 7.0.svn ) vector map from python

2010-06-16 Thread Fernando Pacheco
I think there is an error in the generation process with ctypesgen for
vector.py. The problem is that dig_estructs.h needs the heading
ogr_api.h which is not found in the path included. The problem is solved
if you add the path to that file (in my case -I/usr/include/gdal). Thank
you. Greetings. Fernando.

Ing. Fernando Pacheco M.S.L.

Ingesur srl
Dirección: Requena 1062 ap.302, Montevideo, Uruguay.
Teléfonos: (+598 2) 408 90 48, (+598 9) 962 79 32
Web: http://ingesur.com.uy/



On Wed, Jun 16, 2010 at 1:12 AM, Fernando Pacheco 
fernando.pach...@ingesur.com.uy wrote:

 Yes of course, after updating the source code to the 42 566 version I ran
 make clean, ./configure ..., make, rm-rf / usr/local/grass-7.0.svn 
 and make install. In this situation is that I get the error mentioned in
 my previous email.
 If you have suggestions or an example that works please send me. I need to
 make a decision about the language used to develop the application (I want
 to use Python!). Thank you very much. Greetings. Fernando.


 Ing. Fernando Pacheco M.S.L.

 Ingesur srl
 Dirección: Requena 1062 ap.302, Montevideo, Uruguay.
 Teléfonos: (+598 2) 408 90 48, (+598 9) 962 79 32
 Web: http://ingesur.com.uy/



 On Tue, Jun 15, 2010 at 7:45 PM, Glynn Clements 
 gl...@gclements.plus.comwrote:


 Fernando Pacheco wrote:

  I modified the code as you have suggested. But I encounter a new
 problem. If
  I run a simple program from the command line like this:
  http://osgeo.pastebin.com/pPqkcvk3 get the following error:

  python: malloc.c:4628: _int_malloc: Assertion `(unsigned long)(size) =
  (unsigned long)(nb)' failed.

 That's the error which I saw before fixing the wrappers.

  I updated the code to the 42566 version but I still have the same
 problem. Any
  suggestions?. I will keep trying!. Thank you. Fernando.

 Did you run make clean after updating? Makefiles aren't treated as
 prerequisites, so an incremental build won't cause the wrappers to be
 regenerated.

 It should suffice to run:

make -C lib/python/ctypes clean
make -C lib/python/ctypes

 --
 Glynn Clements gl...@gclements.plus.com



___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] Re: [GRASS GIS] #1090: Access is denied - r.statistics

2010-06-16 Thread GRASS GIS
#1090: Access is denied - r.statistics
--+-
 Reporter:  nkale |   Owner:  grass-...@…   
   
 Type:  defect|  Status:  new   
   
 Priority:  normal|   Milestone:  6.4.0 
   
Component:  Raster| Version:  6.4.0 RCs 
   
 Keywords:  r.statistics access denied, wingrass  |Platform:  MSWindows 7   
   
  Cpu:  x86-32|  
--+-

Comment(by nkale):

 Didn't really follow anything below note 0_sum.c in gr65..., but as for
 the commands you suggested:

 r.stats a...@permanent - runs fine, no errors, meaningful output
 r.stats h...@permanent - runs fine, no errors, meaningful output
 g.tempfile pid=1234 - no errors, output is:
 {{{
 C:/Users/Nat Kale/Documents/Grass_GIS
 DataBase/Alberts_Landcover/PERMANENT/.tmp/1234.1
 }}}
 That is the correct location  mapset.  Can't think of anything else to
 try.

-- 
Ticket URL: https://trac.osgeo.org/grass/ticket/1090#comment:2
GRASS GIS http://grass.osgeo.org

___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] network analysis

2010-06-16 Thread Mohammed Rashad
Is there any module to do network analysis on gui.
when running v.net.path from grass shell open default menuform as for other 
modules.
does wxgui not have such a module to do network analysis graphically.

 --
Rashad



  ___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] network analysis

2010-06-16 Thread Martin Landa
Hi,

2010/6/16 Mohammed Rashad rasha...@yahoo.com:
 Is there any module to do network analysis on gui.
 when running v.net.path from grass shell open default menuform as for other
 modules.
 does wxgui not have such a module to do network analysis graphically.

no, it would be cool to have at least implementation of d.path for wx
displays (e.g. based on v.net.path and temp vector output), volunteers
welcomed.

Martin

-- 
Martin Landa landa.martin gmail.com * http://gama.fsv.cvut.cz/~landa
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev


Re: [GRASS-dev] access to grass (trunk 7.0.svn ) vector map from python

2010-06-16 Thread Glynn Clements

Fernando Pacheco wrote:

 I think there is an error in the generation process with ctypesgen for
 vector.py. The problem is that dig_estructs.h needs the heading
 ogr_api.h which is not found in the path included. The problem is solved
 if you add the path to that file (in my case -I/usr/include/gdal).

Try r42567.

-- 
Glynn Clements gl...@gclements.plus.com
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev


[GRASS-dev] Re: [GRASS GIS] #46: NVIZ fly mode broken on 64bit systems

2010-06-16 Thread GRASS GIS
#46: NVIZ fly mode broken on 64bit systems
-+--
 Reporter:  marisn   |   Owner:  grass-...@…  
 Type:  defect   |  Status:  new  
 Priority:  major|   Milestone:  6.4.1
Component:  NVIZ | Version:  svn-trunk
 Keywords:  nviz |Platform:  Unspecified  
  Cpu:  Unspecified  |  
-+--

Comment(by kwasnicki):

 looks like the problem is a float overflow in
 togl_flythrough.c:this_time() function.  changing the (float) casts to
 (double) has fixed this on my 64bit slackware install.

 diff attached... although not 100% sure if i created the diff patch
 properly, but this is just a one line change so i'm sure the code
 maintainer can replicate the necessary change if the diff doesn't work.
 ;-)

-- 
Ticket URL: http://trac.osgeo.org/grass/ticket/46#comment:5
GRASS GIS http://grass.osgeo.org

___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] access to grass (trunk 7.0.svn ) vector map from python

2010-06-16 Thread Fernando Pacheco
Everything works correctly now, the problem has been fixed.
I think the interface generated automatically with ctypesgen (like that of
SWIG) isn't  attractive for inexperienced developers. It works very well and
is fast, but the calls to the functions are complex (logically identical to
those of C) and is not what an average developer would expect in Python.
In the coming months we will be developing an interface for finite element
modeling (Fenics project=Dolfin, Tritetmesh, etc.). We will start by making
access to vector layers with Python more friendly, taking as a starting
point what has been generated with ctypesgen. Thank you. Greetings.
Fernando.

Ing. Fernando Pacheco M.S.L.

Ingesur srl
Dirección: Requena 1062 ap.302, Montevideo, Uruguay.
Teléfonos: (+598 2) 408 90 48, (+598 9) 962 79 32
Web: http://ingesur.com.uy/



On Wed, Jun 16, 2010 at 12:13 PM, Glynn Clements
gl...@gclements.plus.comwrote:


 Fernando Pacheco wrote:

  I think there is an error in the generation process with ctypesgen for
  vector.py. The problem is that dig_estructs.h needs the heading
  ogr_api.h which is not found in the path included. The problem is
 solved
  if you add the path to that file (in my case -I/usr/include/gdal).

 Try r42567.

 --
 Glynn Clements gl...@gclements.plus.com

___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] network analysis

2010-06-16 Thread Hamish
Mohammed Rashad:
  Is there any module to do network analysis on gui.
  when running v.net.path from grass shell open default
  menuform as for other modules.
  does wxgui not have such a module to do network analysis
  graphically.
Martin:
 no, it would be cool to have at least implementation of
 d.path for wx displays (e.g. based on v.net.path and temp vector
 output), volunteers welcomed.

d.path in non-interactive mode should have everything you need
already, see the wrapper script used in the tcl/tk GUI. e.g.
AFAIK this works on WinGrass.


Hamish


  
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev