IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Opened 20 years ago

Closed 17 years ago

#729 closed defect (invalid)

psRegionForImage bound switching

Reported by: David.Robbins@… Owned by: eugene
Priority: low Milestone:
Component: PSLib SDRS Version: unspecified
Severity: normal Keywords:
Cc:

Description

psRegionForImage allows the inputted upper bounds to be smaller than the lower
bounds. (or vice-versa). For example, setting x0 = 10 and x1 = 5 is valid and
this routine simply switches the two values. I don't believe that this type of
behaviour is either safe or consistent throughout region/image functions.
This issue was discussed at our meeting today and the resolution was to create
this bug.

Change History (4)

comment:1 by Paul Price, 20 years ago

Owner: changed from Paul Price to eugene

comment:2 by eugene, 20 years ago

before changing the code, can you give an example where this behavior would
cause a problem, assuming that the upper bounds are first adjusted for the
negative number behavior?

comment:3 by David.Robbins@…, 20 years ago

well, my thought was simply that an incorrectly specified boundary set such as:

x0 = 10, y0 = 10
x1 = 9, y0 = 11

would be accepted. Another example after adjusting for negative indexing,

x0 = 10, y0 = 10 (max image includes 14, 14)
x1 = -8, y1 = 12
which translates to: x1 = 7, y1 = 12
would also get swapped with the lower boundary. The output of such would be:
x0 = 7, y0 = 10
x1 = 10, y1 = 12

comment:4 by eugene, 17 years ago

Priority: highlow
Resolution: invalid
Status: newclosed

I don't see a problem with either of the examples given, and I am inclined to deny this as a bug.

Note: See TracTickets for help on using tickets.