نظرة عامة على مستقبِل الويب
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
تطبيق مستقبِل الويب
تطبيق مستقبِل الويب هو تطبيق HTML5/JavaScript الذي يعمل على جهاز استقبال الويب، مثل Chromecast. ينفّذ تطبيق "استقبال الويب" الوظائف التالية:
- يقدم واجهة لعرض محتوى التطبيق على التلفزيون.
- يتعامل مع الرسائل من تطبيق المُرسِل للتحكم في المحتوى على جهاز مستقبِل الويب.
- تعالج الرسائل المخصصة من تطبيق المُرسِل المخصص للتطبيق.

يوفّر مستقبِل الويب
وظائف إضافية.
حزمة SDK لمستقبل الويب
وتتضمّن حزمة SDK مستقبِل الويب أيضًا مشغّل وسائط مضمّنًا يوفّر تجربة تشغيل سلسة وسهلة. ويسمح لك أيضًا بتخصيص واجهة المستخدم في المشغّل وتزويد مستقبِل الويب بإمكانية اعتراض الرسائل وتجاهلها وطرق تنفيذ منطق نشاطك التجاري المخصّص.
يمكنك تنفيذ تطبيق Web Re الدخول باستخدام الطرق التالية:
- استخدام أداة استقبال الويب ذات الوسائط المتعددة: وهي عبارة عن تطبيق تم إنشائه مسبقًا للويب، وهو يوفر واجهة مستخدم لمشغّل الوسائط لمحتوى الصوت والفيديو. وتوفّر هذه الأداة واجهة مستخدم تلقائية لتطبيق
"استقبال الويب"، ولكن يمكنك تخصيص عناصر متعددة في واجهة المستخدم باستخدام ملف CSS.
- تطوير مستقبل ويب مخصّص: هذا تطبيق HTML5 مخصّص يجب استضافته للتعامل مع عرض محتوى تطبيقك على التلفزيون. قد تحتاج إلى إنشاء مستقبِل مخصّص إذا كان تطبيقك يريد عرض محتوى بخلاف وسائط الصوت/الفيديو أو إذا كان جهاز استقبال الوسائط النمطيّ لا يتوافق مع أنواع الوسائط التي يطلبها تطبيقك.
إذا اخترت عدم تنفيذ مستقبِل على الويب، يمكن لتطبيقك استخدام أداة استقبال الويب للوسائط التلقائية.
اختيار مستقبِل على الويب
توفّر حزمة SDK مستقبِل الويب أنواعًا مختلفة من أجهزة الاستقبال لتلبية احتياجات نشاطك التجاري. للمقارنة بين الإمكانات المختلفة، يُرجى الاطّلاع على
أنواع دليل تطبيقات المُستلِم.
مستقبل الويب لوسائط الوسائط هو تطبيق مستقبَل تم إنشاؤه مسبقًا من قِبل Google وهو مصمّم لبث محتوى الفيديو والصوت. يمكنك اختيار تصميم الواجهة بألوانك ومواد عرض علامتك التجارية باستخدام ملف CSS.
لاستخدام استقبال الويب لوسائط الوسائط، يجب اختيار "مستقبل الويب لوسائط الوسائط" عند
تسجيل تطبيق جديد و (اختياري) توفير عنوان URL إلى ملف CSS يحدّد مظهرًا مخصصًا لواجهة مستخدم
تطبيق "استقبال الويب" على الويب.
للحصول على تفاصيل حول أنماط CSS التي تسمح لك بتخصيص واجهة مستخدم
تطبيق استقبال الويب لوسائط نمط المحتوى، اطّلِع على دليل
استقبال الوسائط ذات النمط المعتمَد.
مستقبِل ويب مخصّص
إذا كان تطبيقك يوفّر محتوى، مثل معرض صور، أو يتطلب نظام إدارة الحقوق الرقمية (CRM) أو منطقًا مخصّصًا للأنشطة التجارية، عليك إنشاء تطبيق مستقبِل مخصّص للويب. استقبال الويب المخصّص هو تطبيق HTML5 يستضيفه خوادمك الخاصة ويجب تنفيذه باستخدام واجهة برمجة تطبيقات استقبال الويب في JavaScript.
للحصول على تفاصيل عن كيفية إنشاء تطبيق "استقبال الويب" عبر واجهة برمجة التطبيقات
لتلقي الويب، راجِع دليل مستقبل الويب المخصّص.
ويتوفّر خيار ثالث وهو مستقبل الويب التلقائي للوسائط. وهو تطبيق مخصّص مسبقًا
للاستقبال على الويب وتستضيفه Google، وهو مصمّم لبث محتوى الصوت والفيديو الخاص بك. لا يُطلب منك التسجيل في وحدة تحكّم مطوّري برامج
SDK لـ Google Cast، ولكن لا يمكنك تخصيص أيّ من واجهة المستخدم في
"مستقبل الويب التلقائي للوسائط".
بدلاً من التسجيل باستخدام وحدة تحكّم مطوّري البرامج لتلقّي معرّف التطبيق، يمكنك استخدام
مستقبِل الويب التلقائي للوسائط مع رقم تعريف التطبيق التلقائي:
- بالنسبة إلى التطبيقات المتوافقة مع Android:
CastMediaControlIntent.DEFAULT_MEDIA_RECEIVER_APPLICATION_ID
- بالنسبة إلى تطبيقات الويب:
chrome.cast.media.DEFAULT_MEDIA_RECEIVER_APP_ID
- بالنسبة إلى تطبيقات iOS:
- <=v4.0.0
kGCKMediaDefaultReceiverApplicationID
- >=v4.0.2
kGCKDefaultMediaReceiverApplicationID
من تطبيق المُرسِل، يمكنك بدء تشغيل تطبيق "استقبال الويب للوسائط التلقائية" على جهاز البث ثم استخدامه لتحميل عنوان URL إلى الوسائط.
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2022-11-04 (حسب التوقيت العالمي المتفَّق عليه)
[[["يسهُل فهم المحتوى.","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"]],["تاريخ التعديل الأخير: 2022-11-04 (حسب التوقيت العالمي المتفَّق عليه)"],[[["\u003cp\u003eA Web Receiver application is an HTML5/JavaScript application that runs on devices like Chromecast, displaying content, handling sender messages, and enabling custom functionalities.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can choose from three Web Receiver options: the Styled Media Web Receiver (pre-built and customizable with CSS), the Custom Web Receiver (for bespoke content and logic), and the Default Media Web Receiver (basic, uncustomizable media streaming).\u003c/p\u003e\n"],["\u003cp\u003eThe Styled Media Web Receiver is hosted by Google and suitable for streaming audio and video, offering customization through a CSS file for branding.\u003c/p\u003e\n"],["\u003cp\u003eCustom Web Receivers are self-hosted, built using the Web Receiver API, and necessary for content beyond audio/video or when specific requirements aren't met by the Styled Media Receiver.\u003c/p\u003e\n"],["\u003cp\u003eThe Default Media Web Receiver is a basic, uncustomizable option for audio and video streaming, hosted by Google and requiring no registration, suitable for simple use cases.\u003c/p\u003e\n"]]],[],null,["# Web Receiver Overview\n\nWeb Receiver application\n------------------------\n\nA Web Receiver application is an HTML5/JavaScript application that runs on the\nWeb Receiver device, such as a Chromecast. The Web Receiver application performs\nthe following functions:\n\n- Provides an interface to display the app's content on the TV.\n- Handles messages from the sender application to control content on the Web Receiver device.\n- Handles custom messages from the sender application that are application-specific.\n\nThe Web Receiver provides\n[additional functionality](#web_receiver_features_overview).\n\nWeb Receiver SDK\n----------------\n\nThe Web Receiver SDK also comes with a built-in media player, which provides a\nseamless and easy playback experience. It also allows you to customize the\nplayer UI and provides your Web Receiver with the ability to intercept and\noverride messages and methods to execute your custom business logic.\n\nYou can implement your Web Receiver application in the following ways:\n\n- Use the [Styled Media Web Receiver](#styled_media_web_receiver): This is a pre-built Web Receiver application that provides a media player UI for audio and video content. It provides a default UI for the Web Receiver application, but you can customize several elements in the UI with a CSS file.\n- Develop a [Custom Web Receiver](#custom_web_receiver): This is a custom built HTML5 app that you must host to handle the display of your app content on the TV. You may need to create a Custom Receiver if your app wants to display content other than audio/video media or if the Styled Media Receiver does not support the media types your app requires.\n\nIf you choose not to implement a Web Receiver, your application can use the\n[Default Media Web Receiver](#default_media_web_receiver).\n| **Note:** All Web Receivers support the media types described in [Supported Media](/cast/docs/media).\n\nChoose a Web Receiver\n---------------------\n\nThe Web Receiver SDK provides different types of receivers to meet your business\nneeds. For a comparison of the different capabilities, see the\n[types of Receiver apps guide](/cast/docs/overview#types_of_receiver_apps)).\n\n### Styled Media Web Receiver\n\nThe Styled Media Web Receiver is a pre-built Web Receiver application hosted by\nGoogle that is designed for streaming audio and video content. You can style the\ninterface with your own colors and branding assets using a CSS file.\n\nTo use the Styled Media Web Receiver, select Styled Media Web Receiver when\n[registering a new application](/cast/docs/registration) and (optionally)\nprovide the URL to a CSS file that defines a custom look for the Web Receiver\napplication's UI.\n\nFor details about the CSS styles that allow you to customize the Styled Media\nWeb Receiver application's UI, see the\n[Styled Media Receiver](/cast/docs/styled_receiver) guide.\n\n### Custom Web Receiver\n\nIf your app provides content such as an image gallery, requires DRM, or custom\nbusiness logic, then you need to build a Custom Web Receiver application. A\nCustom Web Receiver is an HTML5 app that you host on your own servers and that\nmust be implemented using the JavaScript\n[Web Receiver API](/cast/docs/reference/caf_receiver).\n\nFor details about how to build your Web Receiver application with the Web\nReceiver API, see the [Custom Web Receiver](/cast/docs/caf_receiver/basic)\nguide.\n\n### Default Media Web Receiver\n\nA third option available is the Default Media Web Receiver. This is a pre-built\nWeb Receiver application hosted by Google that is designed for streaming your\naudio and video content. It does not require you to register with the Google\nCast SDK Developer Console, but you **cannot customize any of the UI** in the\nDefault Media Web Receiver.\n\nInstead of registering with the developer console to receive an app ID, you can\nuse the Default Media Web Receiver with the default app ID:\n\n- For Android apps: `CastMediaControlIntent.DEFAULT_MEDIA_RECEIVER_APPLICATION_ID`\n- For Web apps: `chrome.cast.media.DEFAULT_MEDIA_RECEIVER_APP_ID`\n- For iOS apps:\n - \\\u003c=v4.0.0 `kGCKMediaDefaultReceiverApplicationID`\n - \\\u003e=v4.0.2 `kGCKDefaultMediaReceiverApplicationID`\n\nFrom your sender app, you start the Default Media Web Receiver app on the Cast\ndevice and then use it to load the URL to your media."]]