類別:BitrateChangedEvent
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-25 (世界標準時間)。
[null,null,["上次更新時間:2025-07-25 (世界標準時間)。"],[[["\u003cp\u003e\u003ccode\u003eBitrateChangedEvent\u003c/code\u003e provides data for events related to changes in media bitrate during playback.\u003c/p\u003e\n"],["\u003cp\u003eThis event includes the \u003ccode\u003etotalBitrate\u003c/code\u003e property representing the combined audio and video bitrate in bits per second.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can use the \u003ccode\u003ecast.framework.events.EventType.BITRATE_CHANGED\u003c/code\u003e event to track bitrate changes and adapt their application accordingly.\u003c/p\u003e\n"]]],["The `BitrateChangedEvent` class provides data for a `BITRATE_CHANGED` event. It features a constructor, `BitrateChangedEvent`, which accepts an optional `totalBitrate` parameter. The key property, `totalBitrate`, represents the combined audio and video bitrate in bits per second, and it can be a number or undefined. This information is used to track media bitrate changes within a casting framework.\n"],null,["# Class: BitrateChangedEvent\n\ncast.[framework](/cast/docs/reference/web_receiver/cast.framework).[events](/cast/docs/reference/web_receiver/cast.framework.events).BitrateChangedEvent\n========================================================================================================================================================\n\nclass static\n\nEvent data for a `cast.framework.events.EventType.BITRATE_CHANGED` event.\n\nConstructor\n-----------\n\n### BitrateChangedEvent\n\nnew\nBitrateChangedEvent(totalBitrate)\n\n| #### Parameter ||\n|--------------|-----------------|\n| totalBitrate | Optional number |\n\nProperty\n--------\n\n### totalBitrate\n\nconstant\n\n(number or undefined)\n\nThe bitrate of the media (audio and video) in bits per second."]]