Be the first, order the brand new Galaxy S24 FE, Galaxy Tab S10 Ultra, order the KING Galaxy S24 Ultra!

SamMobile has affiliate and sponsored partnerships. If you buy something through one of these links, we may earn a commission.

News For You
News For You
Notifications

Google is encouraging developers to make better-behaving apps for foldables

Phone
By 

Last updated: November 22nd, 2022 at 07:14 UTC+01:00

Most smartphone buyers buy a phone to take advantage of these phones' great camera capabilities. For example, the Galaxy S22 Ultra saw a huge demand among smartphone buyers because of its exceptional camera performance. And cameras are going to be one of the top reasons for a consumer to purchase a phone.

App developers, in order to use the camera capabilities in their apps, adopt Android's Camera Framework. The first use case of the framework is to implement the camera preview to be displayed in the app. But as ambitious foldable devices like Samsung's Galaxy Z Fold 4 are becoming increasingly popular, the camera preview screen may become stretched, upside-down, or incorrectly rotated. Often these make the app crash if used in a multi-window environment.

To fix all this, Google is setting some new guidelines with the new CameraViewfinder that will take care of all those details and provide a streamlined camera experience. As noted in the official blog, “CameraViewfinder is a new artifact from the Jetpack library that allows you to quickly implement camera previews with minimal effort.

This CameraViewfinder employs either a TextureView or a SurfaceView, allowing the camera feed to adjust in accordance with the transformations. The transformations include the correct aspect ratio, scale, and rotation. Moreover, it is fully compatible with the Camera2 codebase.

For a complete step-by-step process to use the CameraViewfinder, you can visit here. The CameraViewfinder function is now ready to use across foldable phones, configuration changes, rotations, and multi-window modes. In fact, as noted in the blog, it has been tried and tested on many foldable devices.

Phone Google
Galaxy AI summarized

Scroll for more related content
News For You

You might also like

Accessing Google Wallet on Samsung phones gets easier

Accessing Google Wallet on Samsung phones gets easier

Google Wallet has received a new feature on Samsung smartphones. It brought a Quick Settings Tile, which was available on several Android phones but curiously missing from Samsung Galaxy phones. Google Wallet gets Quick Settings Tile on Samsung phones A few months ago, Google announced a Quick Settings Tile for Google Wallet on Android smartphones. […]

  • By Asif Iqbal Shaik
  • 4 days ago
Quick Share for Galaxy Book laptops gets updated with bug fixes

Quick Share for Galaxy Book laptops gets updated with bug fixes

A few months ago, Google released the Quick Share app for Windows OS to replace the Nearby Share app. This move came after Google merged its Nearby Share system into Samsung's Quick Share app. Now, Google has released a new update to the Quick Share app for Windows devices like the Galaxy Book series. Quick […]

  • By Abid Iqbal Shaik
  • 5 days ago
Gemini to get Spotify, WhatsApp integration on your Galaxy device soon

Gemini to get Spotify, WhatsApp integration on your Galaxy device soon

Earlier this year, Google started rolling out Gemini to Android phones and tablets. However, it wasn't as feature-rich as Google Assistant regarding third-party integrations. Slowly, though, Google is bringing third-party app integrations to Gemini, and integration with Spotify and WhatsApp is coming soon. Gemini will soon get Spotify and WhatsApp integration Google is working on several […]

  • By Asif Iqbal Shaik
  • 5 days ago
Gemini Live AI assistant now supports a lot more languages

Gemini Live AI assistant now supports a lot more languages

Earlier this year, Google unveiled Gemini Live, the advanced version of Gemini, Google's new AI-powered digital voice assistant. Until yesterday, Gemini Live was only available in a few languages. Today, Gemini Live has been released in several languages, including a lot from India. Gemini Live is now available in several European and Indian languages After […]

  • By Asif Iqbal Shaik
  • 2 weeks ago
Gmail app on Android now fetches more useful info from emails

Gmail app on Android now fetches more useful info from emails

Gmail is the world's most popular email service, and it is not without a reason. Google regularly adds new features to Gmail, and in a new move, the company is bringing more information to the top of the email so you don't miss out on important information. Gmail to get Bills, Events, Purchases, and Travel […]

  • By Asif Iqbal Shaik
  • 2 weeks ago
One UI 7.0 Gallery app could get Google Photos-like AI smarts

One UI 7.0 Gallery app could get Google Photos-like AI smarts

It appears that the One UI 7.0 beta update won't be released anytime soon. Samsung was expected to release at the end of July, but two months have passed since, and there are still no signs of the update. It is now being reported that the company will bring AI-powered search improvements to the stock […]

  • By Asif Iqbal Shaik
  • 2 weeks ago