Skip to content
This repository has been archived by the owner on Aug 9, 2022. It is now read-only.

集成没成功 #2

Closed
zhangzzqq opened this issue Feb 19, 2016 · 1 comment
Closed

集成没成功 #2

zhangzzqq opened this issue Feb 19, 2016 · 1 comment

Comments

@zhangzzqq
Copy link
Contributor

继承没有成功,求帮助?

package com.pc.mediaplayertest;

import android.app.Activity;
import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.View;
import android.view.Menu;
import android.view.MenuItem;

import com.nostra13.universalimageloader.core.ImageLoaderConfiguration;

import java.security.AlgorithmParameterGenerator;
import java.security.cert.PKIXCertPathChecker;

import de.greenrobot.event.EventBus;
import fm.jiecao.jcvideoplayer_lib.JCVideoPlayer;

public class MainActivity extends Activity {

@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);


    JCVideoPlayer videoController = (JCVideoPlayer) findViewById(R.id.videocontroller1);
    videoController.setUp("http://2449.vod.myqcloud.com/2449_43b6f696980311e59ed467f22794e792.f20.mp4",
            "http://p.qpic.cn/videoyun/0/2449_43b6f696980311e59ed467f22794e792_1/640",
            "qqq");

}


@Override
protected void onDestroy() {
    super.onDestroy();
    JCVideoPlayer.releaseAllVideo();
}

}

1:36.504 7367-7367/com.pc.mediaplayertest E/AndroidRuntime: Caused by: java.lang.IllegalStateException: ImageLoader must be init with configuration before using
02-19 12:11:36.504 7367-7367/com.pc.mediaplayertest E/AndroidRuntime: at com.nostra13.universalimageloader.core.ImageLoader.checkConfiguration(ImageLoader.java:568)
02-19 12:11:36.504 7367-7367/com.pc.mediaplayertest E/AndroidRuntime: at com.nostra13.universalimageloader.core.ImageLoader.displayImage(ImageLoader.java:208)
02-19 12:11:36.504 7367-7367/com.pc.mediaplayertest E/AndroidRuntime: at com.nostra13.universalimageloader.core.ImageLoader.displayImage(ImageLoader.java:303)
02-19 12:11:36.504 7367-7367/com.pc.mediaplayertest E/AndroidRuntime: at fm.jiecao.jcvideoplayer_lib.JCVideoPlayer.setUp(JCVideoPlayer.java:151)
02-19 12:11:36.504 7367-7367/com.pc.mediaplayertest E/AndroidRuntime: at fm.jiecao.jcvideoplayer_lib.JCVideoPlayer.setUp(JCVideoPlayer.java:127)
02-19 12:11:36.504 7367-7367/com.pc.mediaplayertest E/AndroidRuntime: at com.pc.mediaplayertest.MainActivity.onCreate(MainActivity.java:32)

@lipangit
Copy link
Owner

ImageLoader must be init with configuration before using
初始化imageloader
或者参照DemoApplication中的初始化
或者按照imageloader官方的初始化方法https://github.com/nostra13/Android-Universal-Image-Loader/wiki/Configuration
^_^

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants