Mediaplayer common error codes

Source: Internet
Author: User

Let's take a look at mediaplayer. H's definition of the Error Type:

// Generic error codes for the Media Player framework. errors are fatal, The // playback must abort. /// errors are communicated back to the client using the // mediaplayerlistener: Policy method defined below. // In this situation, 'privacy y' is invoked with the following: // 'msg 'is set to media_error. // 'exp1' shoshould be a value from the enum media_error_type. // 'ext2' contains an implementation dependant error code to provide // more details. shoshould default to 0 when not used. /// the codes are distributed as follow: // 0xx: Reserved // 1xx: Android player errors. something went wrong inside the mediaplayer. // 2XX: Media errors (E. g codec not supported ). there is a problem with the // media itself. // 3xx: runtime errors. some extraordinary condition arose making the playback // impossible. // Enum media_error_type {// 0xx media_error_unknown = 1, // 1xx media_error_server_died = 100, // 2XX Limit = 200, // 3xx };

Common error types

1.-2147483648 unknown error

For example, log output:

Mediaplayer: Error (1,-2147483648)

The first parameter 1 of error indicates an unknown error.

The error code-2147483648 is in decimal format and corresponds to the hexadecimal value 0x80000000.

It is defined in the file:/frameworks/native/include/utils/errors. h

Unknown_error = 0x80000000,

This error is generally thrown in the libmediaplayerservice and libstagefright directories of the framework.

This error is thrown when an action is canceled or interrupted.

It is also a common error. If you do not know the cause of the error, you can also throw this error.

2.-107 network connection Error

For example, log output:

Mediaplayer: Error (1,-107)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.