refactor: remove pointless else statments
This commit is contained in:
parent
f9575c92a9
commit
3529f7e415
1 changed files with 6 additions and 4 deletions
10
main.go
10
main.go
|
@ -173,9 +173,10 @@ func isDiffUInt8(x, y uint8) bool {
|
||||||
sq := d * d
|
sq := d * d
|
||||||
if sq > 0 {
|
if sq > 0 {
|
||||||
return true
|
return true
|
||||||
} else {
|
|
||||||
return false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return false
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func isDiffUInt8WithTolerance(x, y uint8, tolerance uint64) bool {
|
func isDiffUInt8WithTolerance(x, y uint8, tolerance uint64) bool {
|
||||||
|
@ -183,9 +184,10 @@ func isDiffUInt8WithTolerance(x, y uint8, tolerance uint64) bool {
|
||||||
sq := d * d
|
sq := d * d
|
||||||
if sq > tolerance {
|
if sq > tolerance {
|
||||||
return true
|
return true
|
||||||
} else {
|
|
||||||
return false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return false
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func countUniqueVideoFrames(video_path1 string, video_path2 string, min_diff uint64, use_sq_diff bool) error {
|
func countUniqueVideoFrames(video_path1 string, video_path2 string, min_diff uint64, use_sq_diff bool) error {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue