iPhone 17 smart framing api not working

I tried to modify the AVCam sample code by copying the code here https://developer.apple.com/documentation/avfoundation/adopting-smart-framing-in-your-camera-app#Configure-the-smart-framing-monitor smart framing monitors

I can ensure the activeformat supports smart framing, but the supported frames in monitor is always nil.

In my another project it has supported value, but the observation has never been triggered, then I tried to keep printing the recommended frame, it's always nil.

Could the engineer embed the code into AVCam rather than posting a few code pieces?

iPhone 17 smart framing api not working
 
 
Q