How often do you send text messages while crossing the street?

Or how about when you're getting off a packed train surrounded by crowds of people? Apple is patenting technology that could make it easier to see your surroundings while looking down at your phone.

According to Apple's patent, the tech would enable your iPhone to trigger its camera automatically while you're in the device's messaging app. The phone would use its camera to present your surroundings as the background image on your iPhone's screen as you send text messages. The patent reads as follows:

The background within the text messaging session can continuously be live and current video image of the view seen by the camera at any given moment. Consequently, the device's user is less likely to collide with or stumble over an object while participating in a text message session.

The patent application, which was published on Thursday and was first spotted by Apple Insider, also notes that the tech could allow SMS and iMessage text bubbles to be transparent. This would enable the background video to be at least partially visible within the text bubble.

It's unclear if we'll actually see this feature debut in the iPhone, but there are a few apps for the iPhone and Android smartphones that already offer this functionality. Type n Walk, for example, allows you to type messages while viewing your surroundings. However, although you can type within the Type n Walk app, you still need to share it through your standard, non-transparent messaging app. Apple's invention sounds like it would be built into the existing messaging app in iOS.