androidmedia encoder won't accept h264 profiles other than high

My pipeline is
```
"videotestsrc is-live=true ! "
"video/x-raw,format=NV12,width=1280,height=720,framerate=60/1 ! "
"amcvidenc-c2qtiavcencoder ! "
"video/x-h264,profile=high ! " // Any other profiles won’t work
"h264parse ! "
"rtph264pay name=rtppay config-interval=-1 aggregate-mode=zero-latency ! "
"application/x-rtp,payload=96 ! "
“udpsink host=127.0.0.1 port=5600”
```
Changing the profile to anything but high results in a negotiation error. I’m trying to get a latency as low as possible, while using the high profile gives a latency of more than 150 ms, which is unacceptable. Using x264enc can achieve a nice latency of less than 50 ms, but I would prefer a hardware encoder. Any help?

That may be a device limitation or that particular encoder limitation. There may be another H264 encoder on your system that supports low latency.

I tested on another device with MTK CPU and got the same issue (amcvidenc-c2mtkavcencoder). I feel this may be a bug in androidmedia.

Supported encoder caps:
video/x-h264, width=(int)[ 16, 4096 ], height=(int)[ 16, 4096 ], framerate=(fraction)[ 0/1, 2147483647/1 ], parsed=(boolean)true, stream-format=(string)byte-stream, alignment=(string)au, profile=(string)high, level=(string){ 1, 1b, 1.1, 1.2, 1.3, 2, 2.1, 2.2, 3, 3.1, 3.2, 4, 4.1, 4.2, 5, 5.1 }; 
video/x-h264, width=(int)[ 16, 4096 ], height=(int)[ 16, 4096 ], framerate=(fraction)[ 0/1, 2147483647/1 ], parsed=(boolean)true, stream-format=(string)byte-stream, alignment=(string)au, profile=(string)main, level=(string){ 1, 1b, 1.1, 1.2, 1.3, 2, 2.1, 2.2, 3, 3.1, 3.2, 4, 4.1, 4.2, 5, 5.1 }; 
video/x-h264, width=(int)[ 16, 4096 ], height=(int)[ 16, 4096 ], framerate=(fraction)[ 0/1, 2147483647/1 ], parsed=(boolean)true, stream-format=(string)byte-stream, alignment=(string)au, profile=(string)baseline, level=(string){ 1, 1b, 1.1, 1.2, 1.3, 2, 2.1, 2.2, 3, 3.1, 3.2, 4, 4.1, 4.2, 5, 5.1 }

Although the query says the encoder supports other profiles, none of them except the high profile works.