Android Image Data Invoking System for Memory Overflow Prevention

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Android applications face crashing issues due to excessive memory usage when invoking full-size images with high camera resolutions, leading to system-induced termination.

Innovation Solution

Implementing an image data invoking system that uses a capture mode library for full-size images and a preview mode library for binning-size images, with tags in the hardware abstraction and application framework layers to manage image resolution and parameters, ensuring the image resolution does not exceed available memory and passes Compatibility Test Suite (CTS) tests.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Measurement precision

If full-size images are invoked from the Android system, then image quality is improved, but memory usage exceeds available memory causing application crashes

Engineering Contradiction:
Improveimage qualityVSAvoidmemory usage
Core Design Contradiction:
Measurement precisionVSQuantity of substance

Solution Approach 1:

The patent divides image data into two segments: full-size images stored in capture mode library and binning-size images stored in preview mode library. The system selectively invokes appropriate image sizes based on application needs, preventing memory overflow while maintaining image quality when full-size images are required.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent changes the resolution parameter of images by implementing binning processing that converts full-size images into smaller binning-size images. This parameter transformation allows the system to use smaller images for preview functions, reducing memory consumption while full-size images remain available for high-quality requirements.

Inventive Principle:
Principle #35Parameter changes

2Quantity of substance

If binning-size images are used, then memory usage is reduced, but image quality deteriorates

Engineering Contradiction:
Improvememory usageVSAvoidimage quality
Core Design Contradiction:
Quantity of substanceVSMeasurement precision

Solution Approach 1:

The patent implements a dynamic image invocation mechanism that adapts image selection based on real-time requirements. The system can dynamically switch between invoking binning-size images from preview mode library for memory efficiency and full-size images from capture mode library when high quality is needed, making the image quality flexible rather than fixed.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The patent introduces an image processing intermediary layer that includes capture mode library, preview mode library, and multiple tags (first tag, second tag, third tag, fourth tag) that mediate between the Android system and applications. This intermediary structure enables flexible image selection and processing, allowing the system to optimize between memory usage and image quality based on specific scenarios.

Inventive Principle:
Principle #24Intermediary (Mediator)

3Manufacturing precision

If full-size images are processed, then image detail is improved, but application stability deteriorates due to system termination

Engineering Contradiction:
Improveimage detailVSAvoidapplication stability
Core Design Contradiction:
Manufacturing precisionVSReliability

Solution Approach 1:

The patent performs preliminary processing of full-size images into binning-size images and stores them in advance in the preview mode library. This preliminary action ensures that when applications need images, they can use the pre-processed binning-size images that are guaranteed to fit within memory constraints, preventing system termination and ensuring application stability.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent creates a protective buffer by maintaining both full-size and binning-size image versions in separate libraries. This beforehand cushioning prepares the system in advance to handle memory constraints, ensuring that even if full-size images are requested, the system has pre-prepared binning-size alternatives that prevent memory overflow and application crashes.

Inventive Principle:
Principle #11Beforehand cushioning (Prior cushioning)

Data Source

PatentEP4134903B1Image data calling method and system for application, and electronic device and storage medium
Publication Date: 2024.12.11 HONOR DEVICE CO LTD
  • EP4134903B1 patent drawingFigure 1
  • EP4134903B1 patent drawingFigure 2
  • EP4134903B1 patent drawingFigure 3

AI summary

This application relates to an image data invoking method and system for an application, an electronic device, and a storage medium. When the electronic device identifies an entry file HalSensorList.cpp of a sensor, an image with an image resolution of binning size is filled. The electronic device obtains an image with an image resolution of binning size from a preview mode library at a kernel layer, fills an MTK_SCALER_AVAILABLE_STREAM_CONFIGURATIONS_WITH_DURATIONS tag at a Hal layer with the image with an image resolution of binning size, and reports the binning size of the MTK_SCALER_AVAILABLE_STREAM_CONFIGURATIONS_WITH_DURATIONS tag at the Hal layer to an android.scaler.availableStreamConfigurations tag at a framework layer. An application obtains the image with an image resolution of binning size with which the android.scaler.availableStreamConfigurations tag at the framework layer is filled from the android.scaler.availableStreamConfigurations tag. This application resolves the crashing problem of the application caused by the application invoking image data with an excessive resolution.