اعتبارًا من عام 2026، ولضمان توافقنا مع نموذج التطوير الثابت الرئيسي وضمان استقرار المنصة في المنظومة المتكاملة، سننشر الرمز المصدري في "مشروع Android مفتوح المصدر" (AOSP) في الربع الثاني والربع الرابع. لإنشاء AOSP والمساهمة فيه، ننصحك باستخدام android-latest-release بدلاً من aosp-main. سيشير فرع البيان android-latest-release دائمًا إلى أحدث إصدار تم إرساله إلى AOSP. لمزيد من المعلومات، يُرجى الاطّلاع على التغييرات في مشروع Android المفتوح المصدر (AOSP).
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
مرجع بنية gralloc_module_t
#include <
gralloc.h
>
|
|
|
struct
hw_module_t
|
شائعة
|
|
|
|
int(*
|
registerBuffer
)(struct
gralloc_module_t
const *module, buffer_handle_t handle)
|
|
|
|
int(*
|
unregisterBuffer
)(struct
gralloc_module_t
const *module, buffer_handle_t handle)
|
|
|
|
int(*
|
lock
)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, void **vaddr)
|
|
|
|
int(*
|
unlock
)(struct
gralloc_module_t
const *module, buffer_handle_t handle)
|
|
|
|
int(*
|
perform
)(struct
gralloc_module_t
const *module, int operation,...)
|
|
|
|
int(*
|
lock_ycbcr
)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, struct android_ycbcr *ycbcr)
|
|
|
|
int(*
|
lockAsync
)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, void **vaddr, int fenceFd)
|
|
|
|
int(*
|
unlockAsync
)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int *fenceFd)
|
|
|
|
int(*
|
lockAsync_ycbcr
)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, struct android_ycbcr *ycbcr, int fenceFd)
|
|
|
|
void *
|
reserved_proc
[3]
|
|
|
يجب أن تحتوي كل وحدة أجهزة على بنية بيانات باسم HAL_MODULE_INFO_SYM، ويجب أن تبدأ حقول بنية البيانات هذه بـ
hw_module_t
متبوعة بمعلومات خاصة بالوحدة.
التعريف في السطر
155
من الملف
gralloc.h
.
|
int(* lock)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, void **vaddr)
|
|
int(* lock_ycbcr)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, struct android_ycbcr *ycbcr)
|
|
int(* lockAsync)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, void **vaddr, int fenceFd)
|
|
int(* lockAsync_ycbcr)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int usage, int l, int t, int w, int h, struct android_ycbcr *ycbcr, int fenceFd)
|
|
int(* registerBuffer)(struct
gralloc_module_t
const *module, buffer_handle_t handle)
|
|
int(* unlockAsync)(struct
gralloc_module_t
const *module, buffer_handle_t handle, int *fenceFd)
|
|
int(* unregisterBuffer)(struct
gralloc_module_t
const *module, buffer_handle_t handle)
|
تم إنشاء مستندات هذه البنية من الملف التالي:
-
hardware/libhardware/include/hardware/
gralloc.h
يخضع كل من المحتوى وعيّنات التعليمات البرمجية في هذه الصفحة للتراخيص الموضحّة في ترخيص استخدام المحتوى. إنّ Java وOpenJDK هما علامتان تجاريتان مسجَّلتان لشركة Oracle و/أو الشركات التابعة لها.
تاريخ التعديل الأخير: 2025-07-27 (حسب التوقيت العالمي المتفَّق عليه)
[[["يسهُل فهم المحتوى.","easyToUnderstand","thumb-up"],["ساعَدني المحتوى في حلّ مشكلتي.","solvedMyProblem","thumb-up"],["غير ذلك","otherUp","thumb-up"]],[["لا يحتوي على المعلومات التي أحتاج إليها.","missingTheInformationINeed","thumb-down"],["الخطوات معقدة للغاية / كثيرة جدًا.","tooComplicatedTooManySteps","thumb-down"],["المحتوى قديم.","outOfDate","thumb-down"],["ثمة مشكلة في الترجمة.","translationIssue","thumb-down"],["مشكلة في العيّنات / التعليمات البرمجية","samplesCodeIssue","thumb-down"],["غير ذلك","otherDown","thumb-down"]],["تاريخ التعديل الأخير: 2025-07-27 (حسب التوقيت العالمي المتفَّق عليه)"],[],[]]