質問編集履歴

2

いろいろ

2017/12/21 23:16

投稿

ths
ths

スコア21

test CHANGED
File without changes
test CHANGED
@@ -72,9 +72,33 @@
72
72
 
73
73
  ```
74
74
 
75
- ですが、F-06Fで実行してもアプリクラッシュし
75
+ ですが、F-06Fで実行しても再生されせん
76
76
 
77
+ 以下のエラーが出ます。
78
+
79
+ ```ここに言語を入力
80
+
81
+ 12-22 08:05:24.333 1019-1019/? E/MediaPlayer-JNI: QCMediaPlayer mediaplayer NOT present
82
+
83
+ 12-22 08:05:24.362 1019-1019/? E/MediaPlayer-JNI: QCMediaPlayer mediaplayer NOT present
84
+
85
+ 12-22 08:05:24.434 1019-1019/? E/MediaPlayer: Should have subtitle controller already set
86
+
87
+ 12-22 08:12:34.470 25818-25818/? E/MediaPlayer-JNI: QCMediaPlayer mediaplayer NOT present
88
+
77
- エラーログを見たところSound.ktのmp.prepare()で落ちています。
89
+ 12-22 08:12:34.482 25818-25818/? E/MediaPlayer: prepareAsync called in state 8
90
+
91
+ 12-22 08:14:04.316 27256-27256/sechs.kanazawa E/MediaPlayer-JNI: QCMediaPlayer mediaplayer NOT present
92
+
93
+ 12-22 08:14:04.325 27256-27256/sechs.kanazawa E/MediaPlayer: prepareAsync called in state 8
94
+
95
+ 12-22 08:14:04.382 27256-27256/sechs.kanazawa E/MediaPlayer: Should have subtitle controller already set
96
+
97
+ ```
98
+
99
+
100
+
101
+
78
102
 
79
103
  MediaPlayerの使い方が間違っているのでしょうか?
80
104
 

1

ソースの変更

2017/12/21 23:15

投稿

ths
ths

スコア21

test CHANGED
File without changes
test CHANGED
@@ -12,7 +12,7 @@
12
12
 
13
13
 
14
14
 
15
- class MainActivity : AppCompatActivity() {
15
+ open class MainActivity : AppCompatActivity() {
16
16
 
17
17
 
18
18
 
@@ -44,7 +44,7 @@
44
44
 
45
45
 
46
46
 
47
- class Sound(context: Context){
47
+ open class Sound(context: Context){
48
48
 
49
49
  val context = context
50
50