core: Reduce memory usage in Integral Auto Gain Detector
core: Reduce memory usage in Integral Auto Gain Detector

This is just fallback to the original IP code. I deviated from it
during my testing.

NeoGeographyToolkit/StereoPipeline,aaronknister/StereoPipeline,oleg-alexandrov/StereoPipeline,oleg-alexandrov/StereoPipeline,aaronknister/StereoPipeline,oleg-alexandrov/StereoPipeline,njwilson23/StereoPipeline,aaronknister/StereoPipeline,oleg-alexandrov/StereoPipeline,NeoGeographyToolkit/StereoPipeline,DougFirErickson/StereoPipeline,aaronknister/StereoPipeline,njwilson23/StereoPipeline,DougFirErickson/StereoPipeline,njwilson23/StereoPipeline,oleg-alexandrov/StereoPipeline,oleg-alexandrov/StereoPipeline,ScottMcMichael/StereoPipeline,njwilson23/StereoPipeline,aaronknister/StereoPipeline,ScottMcMichael/StereoPipeline,DougFirErickson/StereoPipeline,ScottMcMichael/StereoPipeline,DougFirErickson/StereoPipeline,DougFirErickson/StereoPipeline,NeoGeographyToolkit/StereoPipeline,DougFirErickson/StereoPipeline,NeoGeographyToolkit/StereoPipeline,ScottMcMichael/StereoPipeline,NeoGeographyToolkit/StereoPipeline,njwilson23/StereoPipeline,ScottMcMichael/StereoPipeline,njwilson23/StereoPipeline,ScottMcMichael/StereoPipeline,NeoGeographyToolkit/StereoPipeline