When I call CGDisplayStreamCreate, I need to authorize it. I want to check the authorization status of Screen Recording when the app starts. I will request authorization and perform further operations without authorization. What is the relevant api?
CGDisplayStreamRef display_stream = CGDisplayStreamCreate(
display_id, 100, 100, 'BGRA', nil, handler);