replicant-frameworks_native/libs/gui
Dan Stoza ec4cb38750 GLConsumer: Fix crop math
When we have excess pixels that need to be removed from (for example)
the left and right sides, we currently do something like:

  left += excess / 2;
  right -= excess / 2;

If excess is odd, however, this removes 1 too few pixels since the odd
pixel gets rounded down twice. This changes the math to effectively:

  left += excess / 2;
  right -= (excess - excess / 2);

Which removes the correct total number of pixels.

Bug: 19611086
Change-Id: I8d1ad9fe7ba67c149794c148663d12acbccccef0
2015-06-10 10:24:51 -07:00
..
tests
Android.mk
BitTube.cpp
BufferItem.cpp
BufferItemConsumer.cpp
BufferQueue.cpp
BufferQueueConsumer.cpp
BufferQueueCore.cpp
BufferQueueProducer.cpp
BufferSlot.cpp
CleanSpec.mk
ConsumerBase.cpp
CpuConsumer.cpp
DisplayEventReceiver.cpp
GLConsumer.cpp GLConsumer: Fix crop math 2015-06-10 10:24:51 -07:00
GraphicBufferAlloc.cpp
GuiConfig.cpp
IConsumerListener.cpp
IDisplayEventConnection.cpp
IGraphicBufferAlloc.cpp
IGraphicBufferConsumer.cpp
IGraphicBufferProducer.cpp
IProducerListener.cpp
ISensorEventConnection.cpp
ISensorServer.cpp
ISurfaceComposer.cpp
ISurfaceComposerClient.cpp
LayerState.cpp
Sensor.cpp
SensorEventQueue.cpp
SensorManager.cpp
StreamSplitter.cpp
Surface.cpp
SurfaceComposerClient.cpp
SurfaceControl.cpp
SyncFeatures.cpp