Contao\CoreBundle\Test\Contao\ImageTest::getComputeResizeDataWithoutImportantPart PHP Method

getComputeResizeDataWithoutImportantPart() public method

Provides the data for the testComputeResizeWithoutImportantPart() method.
    public function getComputeResizeDataWithoutImportantPart()
    {
        return ['No dimensions' => [[null, null, 100, 100, null], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]], 'Same dimensions' => [[100, 100, 100, 100, null], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]], 'Scale down' => [[50, 50, 100, 100, null], ['width' => 50, 'height' => 50, 'target_x' => 0, 'target_y' => 0, 'target_width' => 50, 'target_height' => 50]], 'Scale up' => [[100, 100, 50, 50, null], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]], 'Width only' => [[100, null, 50, 50, null], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]], 'Height only' => [[null, 100, 50, 50, null], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]], 'Crop landscape' => [[100, 50, 100, 100, null], ['width' => 100, 'height' => 50, 'target_x' => 0, 'target_y' => -25, 'target_width' => 100, 'target_height' => 100]], 'Crop portrait' => [[50, 100, 100, 100, null], ['width' => 50, 'height' => 100, 'target_x' => -25, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]], 'Mode proportional landscape' => [[100, 10, 100, 50, 'proportional'], ['width' => 100, 'height' => 50, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 50]], 'Mode proportional portrait' => [[10, 100, 50, 100, 'proportional'], ['width' => 50, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 50, 'target_height' => 100]], 'Mode proportional square' => [[100, 50, 100, 100, 'proportional'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]], 'Mode box landscape 1' => [[100, 100, 100, 50, 'box'], ['width' => 100, 'height' => 50, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 50]], 'Mode box landscape 2' => [[100, 10, 100, 50, 'box'], ['width' => 20, 'height' => 10, 'target_x' => 0, 'target_y' => 0, 'target_width' => 20, 'target_height' => 10]], 'Mode box portrait 1' => [[100, 100, 50, 100, 'box'], ['width' => 50, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 50, 'target_height' => 100]], 'Mode box portrait 2' => [[10, 100, 50, 100, 'box'], ['width' => 10, 'height' => 20, 'target_x' => 0, 'target_y' => 0, 'target_width' => 10, 'target_height' => 20]], 'Mode left_top landscape' => [[100, 100, 100, 50, 'left_top'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode left_top portrait' => [[100, 100, 50, 100, 'left_top'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 200]], 'Mode center_top landscape' => [[100, 100, 100, 50, 'center_top'], ['width' => 100, 'height' => 100, 'target_x' => -50, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode center_top portrait' => [[100, 100, 50, 100, 'center_top'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 200]], 'Mode right_top landscape' => [[100, 100, 100, 50, 'right_top'], ['width' => 100, 'height' => 100, 'target_x' => -100, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode right_top portrait' => [[100, 100, 50, 100, 'right_top'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 200]], 'Mode left_center landscape' => [[100, 100, 100, 50, 'left_center'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode left_center portrait' => [[100, 100, 50, 100, 'left_center'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => -50, 'target_width' => 100, 'target_height' => 200]], 'Mode center_center landscape' => [[100, 100, 100, 50, 'center_center'], ['width' => 100, 'height' => 100, 'target_x' => -50, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode center_center portrait' => [[100, 100, 50, 100, 'center_center'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => -50, 'target_width' => 100, 'target_height' => 200]], 'Mode right_center landscape' => [[100, 100, 100, 50, 'right_center'], ['width' => 100, 'height' => 100, 'target_x' => -100, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode right_center portrait' => [[100, 100, 50, 100, 'right_center'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => -50, 'target_width' => 100, 'target_height' => 200]], 'Mode left_bottom landscape' => [[100, 100, 100, 50, 'left_bottom'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode left_bottom portrait' => [[100, 100, 50, 100, 'left_bottom'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => -100, 'target_width' => 100, 'target_height' => 200]], 'Mode center_bottom landscape' => [[100, 100, 100, 50, 'center_bottom'], ['width' => 100, 'height' => 100, 'target_x' => -50, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode center_bottom portrait' => [[100, 100, 50, 100, 'center_bottom'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => -100, 'target_width' => 100, 'target_height' => 200]], 'Mode right_bottom landscape' => [[100, 100, 100, 50, 'right_bottom'], ['width' => 100, 'height' => 100, 'target_x' => -100, 'target_y' => 0, 'target_width' => 200, 'target_height' => 100]], 'Mode right_bottom portrait' => [[100, 100, 50, 100, 'right_bottom'], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => -100, 'target_width' => 100, 'target_height' => 200]], 'Float values' => [[100.4, 100.4, 50, 50, null], ['width' => 100, 'height' => 100, 'target_x' => 0, 'target_y' => 0, 'target_width' => 100, 'target_height' => 100]]];
    }