0

Where to specify the width and height for the file that need to be transcoded. This is my code.

$job = $elasticTranscoder->createJob(array('PipelineId' => 'xx-nxx','OutputKeyPrefix' => 'output2/'.$folder.'/',

    'Input' => array(
    'Key' => $_GET['name'],
    'FrameRate' => 'auto',
    'Resolution' => 'auto',
    'AspectRatio' => '4:3',
    'Interlaced' => 'auto',
    'Container' => 'auto',
    ),
   'Outputs' => array(
    array(
        'Key' => $out,
        'Rotate' => 'auto',
        'PresetId' =>$p ,
        ),),));

I reffered this aws document and when i included it as

'DetectedProperties' => array(
        'Width' => 540,
        'Height' => 720, ),),

it is saying

"message":"Do not specify a value for 'Input:DetectedProperties',

Need help!!

John Rotenstein
  • 241,921
  • 22
  • 380
  • 470
Reaching-Out
  • 415
  • 6
  • 26

1 Answers1

-1

Structure of a request - creating a Job:

POST /2012-09-25/jobs HTTP/1.1
Content-Type: application/json; charset=UTF-8
Accept: */*
Host: elastictranscoder.us-east-1.amazonaws.com:443
Content-Length: 300
{
   "Input":{
  "Key":"sample.mp4",
  "FrameRate":"auto",
  "Resolution":"auto",
  "AspectRatio":"auto",
  "Interlaced":"auto",
  "Container":"mp4"
   },
   "OutputKeyPrefix":"family-videos/",
   "Outputs":[
  {
     "Key":"sams-birthday.mp4",
     "ThumbnailPattern":"thumbnails/sams-birthday-{count}",
     "Rotate":"0",
     "PresetId":"1351620000000-100080"
  }
   ],
   "PipelineId":"1111111111111-abcde1"
}

For setting width and height, go and create your own configurations apart from the presets available.

jeffry copps
  • 305
  • 5
  • 22
  • but the structure does not tell us how to set the width and height of the output transcoded video. – Reaching-Out Oct 16 '15 at 04:14
  • Create your own presets. The landing page link looks something like this. https://console.aws.amazon.com/elastictranscoder/home?region=ap-southeast-1#create-preset: – jeffry copps Oct 16 '15 at 07:28