BaseResolutionPolicy decides how AndEngine will handle our application display width and height based on various factors:
FillResolutionPolicy: The FillResolutionPolicy class is typical if we just want our application to take up the full width and height of the display. This can cause some noticeable stretching so that our scene covers the entire available display size.
FixedResolutionPolicy: The FixedResolutionPolicy class allows us to use a fixed display size for our application, regardless of the size of the deviceβs display or the size of the camera object. This policy can be passed to EngineOptions through the new FixedResolutionPolicy (pWidth, pHeight), where pWidth defines the final width, the view will span, and pHeight determines the final height, the application will span.
RatioResolutionPolicy: The RatioResolutionPolicy class is the best resolution policy choice if we need to get the maximum display size without causing any sprite distortion. On the other hand, due to the wide range of Android devices covering many size displays, it is possible that some devices may see black bars either on the top and bottom, or on the left and right sides of the display.
RelativeResolutionPolicy: This is the final permission policy. This policy allows us to apply scaling, both larger and smaller, to the overall appearance of the application, based on the scaling factor, with 1f being the default value.
So, if you want full-screen mode, use FillResolutionPolicy as follows:
EngineOptions engineOptions = new EngineOptions(true, ScreenOrientation.LANDSCAPE_FIXED, new FillResolutionPolicy(), mCamera);
source share