|
@@ -280,8 +280,8 @@ namespace bbiwarg.Detectors.FingerDetection
|
|
|
|
|
|
private FingerSliceTrail orderTrailTipToHand(FingerSliceTrail trail)
|
|
|
{
|
|
|
- int maxX = depthImage.Width - 1;
|
|
|
- int maxY = depthImage.Height - 1;
|
|
|
+ int maxX = depthImage.Width - 2;
|
|
|
+ int maxY = depthImage.Height - 2;
|
|
|
|
|
|
FingerSlice start = trail.Start;
|
|
|
FingerSlice end = trail.End;
|
|
@@ -294,10 +294,10 @@ namespace bbiwarg.Detectors.FingerDetection
|
|
|
float startOutLength = float.MaxValue;
|
|
|
float endOutLength = float.MaxValue;
|
|
|
|
|
|
- if (startOutSlice.Start.isWithin(0, 0, maxX, maxY) && startOutSlice.End.isWithin(0, 0, maxX, maxY))
|
|
|
+ if (startOutSlice.Start.isWithin(1, 1, maxX, maxY) && startOutSlice.End.isWithin(1, 1, maxX, maxY))
|
|
|
startOutLength = startOutSlice.Length;
|
|
|
|
|
|
- if (endOutSlice.Start.isWithin(0, 0, maxX, maxY) && endOutSlice.End.isWithin(0, 0, maxX, maxY))
|
|
|
+ if (endOutSlice.Start.isWithin(1, 1, maxX, maxY) && endOutSlice.End.isWithin(1, 1, maxX, maxY))
|
|
|
endOutLength = endOutSlice.Length;
|
|
|
|
|
|
if (startOutLength <= endOutLength)
|