[GRASS-dev] [GRASS GIS] #1788: r.viewshed binary flag (-b) not working correctly

#1788: r.viewshed binary flag (-b) not working correctly
-------------------------+--------------------------------------------------
Reporter: cmbarton | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 7.0.0
Component: Raster | Version: svn-trunk
Keywords: r.viewshed | Platform: Unspecified
      Cpu: Unspecified |
-------------------------+--------------------------------------------------
The binary flag for r.viewshed makes viewed areas = 1 but unviewed areas =
null(). Unviewed areas are supposed to be = 0.

For example:

{{{

r.viewshed -b input=elevation@PERMANENT output=a_view
coordinate=634681,221947
GRASS 7.0.svn (nc_spm_08):~ > r.info -r a_view
min=1
max=1

}}}

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1788&gt;
GRASS GIS <http://grass.osgeo.org>

#1788: r.viewshed binary flag (-b) not working correctly
-------------------------+--------------------------------------------------
Reporter: cmbarton | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 7.0.0
Component: Raster | Version: svn-trunk
Keywords: r.viewshed | Platform: Unspecified
      Cpu: Unspecified |
-------------------------+--------------------------------------------------

Comment(by annakrat):

I attached a patch for this. If there are no objections, I will commit it.

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1788#comment:1&gt;
GRASS GIS <http://grass.osgeo.org>

#1788: r.viewshed binary flag (-b) not working correctly
-------------------------+--------------------------------------------------
Reporter: cmbarton | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 7.0.0
Component: Raster | Version: svn-trunk
Keywords: r.viewshed | Platform: Unspecified
      Cpu: Unspecified |
-------------------------+--------------------------------------------------

Comment(by annakrat):

Replying to [comment:1 annakrat]:
> I attached a patch for this. If there are no objections, I will commit
it.

Done in r62467. The failing tests should be fixed tomorrow, I will
backport it then.

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1788#comment:2&gt;
GRASS GIS <http://grass.osgeo.org>

#1788: r.viewshed binary flag (-b) not working correctly
--------------------------+-------------------------------------------------
  Reporter: cmbarton | Owner: grass-dev@…
      Type: defect | Status: closed
  Priority: normal | Milestone: 7.0.0
Component: Raster | Version: svn-trunk
Resolution: fixed | Keywords: r.viewshed
  Platform: Unspecified | Cpu: Unspecified
--------------------------+-------------------------------------------------
Changes (by annakrat):

  * status: new => closed
  * resolution: => fixed

Comment:

Replying to [comment:2 annakrat]:
> Replying to [comment:1 annakrat]:
> > I attached a patch for this. If there are no objections, I will commit
it.
>
> Done in r62467. The failing tests should be fixed tomorrow, I will
backport it then.

Done in 62497. Tests are running fine, so I take it as fixed.

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1788#comment:3&gt;
GRASS GIS <http://grass.osgeo.org>

#1788: r.viewshed binary flag (-b) not working correctly
--------------------------+-------------------------
  Reporter: cmbarton | Owner: grass-dev@…
      Type: defect | Status: reopened
  Priority: normal | Milestone: 7.0.0
Component: Raster | Version: svn-trunk
Resolution: | Keywords: r.viewshed
       CPU: Unspecified | Platform: Unspecified
--------------------------+-------------------------
Changes (by annakrat):

* status: closed => reopened
* resolution: fixed =>

Comment:

Reopened because it works only when using internal memory. When using
external memory mode, binary output gives 1 and nulls. It doesn't seem to
be so easily fixable as the in-memory case, because I can't find an easy
way to find out which cell should be 0 and which should be null.

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1788#comment:4&gt;
GRASS GIS <http://grass.osgeo.org>