MediaProjection captures DisplayArea
MediaProjection is used by apps to capture the contents of a display. Apps consume the content from a surface passed in to MediaProjection#createVirtualDisplay. The images written out to the surface can be used for saving screenshots of the current display, screen recording, or casting to a different display. MediaProjection is currently tied to capturing a physical display. This change instead captures the DisplayArea the app is launched on. This is consistent with Display API sandboxing, which returns the DisplayArea bounds rather than the physical display bounds. Note that apps use the Display APIs to size the VirtualDisplay and output surface. Verified: screenshots, screen recording, and casting Bug: 180624777 Bug: 195280234 Test: atest WmTests:DisplayContentTests Change-Id: I086fa1ae668dbdf0f25252c13614445af04d86f3
Loading
Please register or sign in to comment