-
Notifications
You must be signed in to change notification settings - Fork 1
/
MeariDeviceController.java
4496 lines (4094 loc) · 221 KB
/
MeariDeviceController.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
package com.meari.sdk;
import android.text.TextUtils;
import com.meari.sdk.bean.CameraInfo;
import com.meari.sdk.bean.DeviceParams;
import com.meari.sdk.bean.MeariMoveDirection;
import com.meari.sdk.bean.MeariMusic;
import com.meari.sdk.bean.RefreshInfo;
import com.meari.sdk.bean.RoiInfo;
import com.meari.sdk.bean.SDCardInfo;
import com.meari.sdk.callback.IControlMusicCallback;
import com.meari.sdk.callback.IDeviceUpgradeAllPercentCallback;
import com.meari.sdk.callback.IDeviceUpgradeCallback;
import com.meari.sdk.callback.IDeviceUpgradePercentCallback;
import com.meari.sdk.callback.IGetDeviceParamsCallback;
import com.meari.sdk.callback.IGetFaceDetectResultCallback;
import com.meari.sdk.callback.IGetMusicVolumeCallback;
import com.meari.sdk.callback.IGetRefreshInfoCallback;
import com.meari.sdk.callback.IPlaybackDaysCallback;
import com.meari.sdk.callback.IRefreshMusicStatusCallback;
import com.meari.sdk.callback.IRefreshTempAndHumCallback;
import com.meari.sdk.callback.ISDCardFormatCallback;
import com.meari.sdk.callback.ISDCardFormatPercentCallback;
import com.meari.sdk.callback.ISDCardInfoCallback;
import com.meari.sdk.callback.ISetDeviceParamsCallback;
import com.meari.sdk.common.CameraSleepType;
import com.meari.sdk.json.BaseJSONArray;
import com.meari.sdk.json.BaseJSONObject;
import com.meari.sdk.listener.MeariDeviceListener;
import com.meari.sdk.listener.MeariDeviceRecordMp4Listener;
import com.meari.sdk.listener.MeariDeviceTalkVolumeListener;
import com.meari.sdk.listener.MeariDeviceVideoSeekListener;
import com.meari.sdk.listener.MeariDeviceVideoStopListener;
import com.meari.sdk.utils.BaseUtils;
import com.meari.sdk.utils.GsonUtil;
import com.meari.sdk.utils.JsonUtil;
import com.meari.sdk.utils.Logger;
import com.meari.sdk.utils.SdkUtils;
import com.ppstrong.ppsplayer.CameraPlayer;
import com.ppstrong.ppsplayer.CameraPlayerListener;
import com.ppstrong.ppsplayer.CameraPlayerRecordMp4Listener;
import com.ppstrong.ppsplayer.CameraPlayerRecordVolumeListener;
import com.ppstrong.ppsplayer.CameraPlayerVideoSeekListener;
import com.ppstrong.ppsplayer.CameraPlayerVideoStopListener;
import com.ppstrong.ppsplayer.PPSGLSurfaceView;
import java.util.ArrayList;
import java.util.Locale;
import java.util.Objects;
import org.json.JSONException;
/* loaded from: /var/folders/mb/smjzq82150ddzvk3gq411h300000gn/T/jadx-7000784439489740785.dex */
public class MeariDeviceController {
public static final int PLAYBACK_MODE = 1;
public static final int PLAYBACK_NONE = -1;
public static final int PLAY_MODE = 0;
public static final int PPSPLAYER_ALREADY_CALLED = -3;
public static final int PPSPLAYER_ALREADY_CONNECTED = -9;
public static final int PPSPLAYER_ALREADY_PLAYBACK = -11;
public static final int PPSPLAYER_ALREADY_PREVIEW = -10;
public static final int PPSPLAYER_CONNECT_IPC_FIRST = -6;
public static final int PPSPLAYER_DEVICE_OFFLINE = -15;
public static final int PPSPLAYER_DISCONNECTED = -14;
public static final int PPSPLAYER_ERROR_PARAMS = -1;
public static final int PPSPLAYER_ERROR_PASSWORD = -2;
public static final int PPSPLAYER_IOException = -13;
public static final int PPSPLAYER_NOT_SUPPORT = -12;
public static final int PPSPLAYER_OK = 0;
public static final int PPSPLAYER_PATH_INVALID = -8;
public static final int PPSPLAYER_PREVIEW_OR_PLAYBACK_FIRST = -7;
public static final int PPSPLAYER_REQUEST_FAILED = -5;
public static final int PPSPLAYER_REQUEST_TIMEOUT = -4;
public static final String STORAGE_PERMISSION_DENIED = "storage permission denied";
public static final int VIDEO_STATUS_CAMERA_OFF = 8;
public static final int VIDEO_STATUS_END_SLEEP = 9;
public static final int VIDEO_STATUS_GEO_SLEEP = 7;
public static final int VIDEO_STATUS_PLAYING = 10;
public static final int VIDEO_STATUS_POOR_TRANSMISSION = 11;
public static final int VIDEO_STATUS_STOP = 3;
public static final int VIDEO_STATUS_TIME_SLEEP = 6;
public static String mserverip = "https://audio.meari.com.cn";
private String TAG;
private long[] btss;
private CameraInfo cameraInfo;
private CameraPlayer cameraPlayer;
private int index;
/* loaded from: /var/folders/mb/smjzq82150ddzvk3gq411h300000gn/T/jadx-7000784439489740785.dex */
public interface VoiceType {
public static final int ChildVoice = 0;
public static final int GirlVoice = 1;
public static final int ManVoice = 2;
}
/* JADX INFO: Access modifiers changed from: package-private */
public static /* synthetic */ void lambda$pausePlaybackSDCard$4() {
}
/* JADX INFO: Access modifiers changed from: package-private */
public static /* synthetic */ void lambda$resumePlaybackSDCard$5() {
}
public MeariDeviceController() {
this.TAG = getClass().getSimpleName();
this.btss = new long[]{0, 0, 0, 0, 0};
if (this.cameraPlayer == null) {
this.cameraPlayer = new CameraPlayer();
}
}
public MeariDeviceController(CameraInfo cameraInfo) {
this();
this.cameraInfo = cameraInfo;
}
public void release() {
this.cameraPlayer = null;
}
public CameraInfo getCameraInfo() {
return this.cameraInfo;
}
public void setCameraInfo(CameraInfo cameraInfo) {
this.cameraInfo = cameraInfo;
}
public boolean isUnConnected() {
return (this.cameraPlayer.mstatus & 2) != 2;
}
public boolean isConnected() {
CameraPlayer cameraPlayer = this.cameraPlayer;
return cameraPlayer != null && cameraPlayer.IsLogined();
}
public boolean isConnecting() {
CameraPlayer cameraPlayer = this.cameraPlayer;
return cameraPlayer != null && cameraPlayer.isLogining();
}
public boolean isPreviewing() {
CameraPlayer cameraPlayer = this.cameraPlayer;
return cameraPlayer != null && cameraPlayer.IsPreviewing();
}
public boolean isPlaybacking() {
CameraPlayer cameraPlayer = this.cameraPlayer;
return cameraPlayer != null && cameraPlayer.IsPlaybacking();
}
public boolean isStopVoicing() {
CameraPlayer cameraPlayer = this.cameraPlayer;
return cameraPlayer != null && cameraPlayer.isStopVoicing();
}
public void enableHardDecode(boolean z) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.enableMediacodec(z);
}
}
public void setVoiceParams(String str, String str2, String str3, String str4) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.setVoiceParams(str, str2, str3, str4);
}
}
public void setStreamType(int i) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.setStreamType(i);
}
}
public void setPlayMode(int i) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.setPlayMode(i);
}
}
public void setCurrentPlayTime(int i) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.setCurrentPlayTime(i);
}
}
public void setVolume(int i) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.setVolume(i);
}
}
public void setNoiseSuppression(int i) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.setNoiseSuppression(i);
}
}
public int getP2pMode() {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer == null) {
return 0;
}
return cameraPlayer.getp2pmode();
}
public int getStatus() {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer == null) {
return 0;
}
return cameraPlayer.mstatus;
}
public int getPlaybackTime() {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer == null) {
return 0;
}
return cameraPlayer.getPlaybackTime();
}
public int getBitRate() {
long avg = (long) (((float) getAVG(this.cameraPlayer.getBts(0))) / 1024.0f);
int i = (avg > 120 ? 1 : (avg == 120 ? 0 : -1));
return (int) ((float) avg);
}
private long getAVG(long j) {
long[] jArr;
this.btss[0] = j;
long j2 = 0;
int i = 0;
while (true) {
jArr = this.btss;
if (i >= jArr.length) {
break;
}
if (jArr[i] == 0 || this.index == i) {
jArr[i] = j;
}
j2 += jArr[i];
i++;
}
int i2 = this.index + 1;
this.index = i2;
if (i2 == jArr.length) {
this.index = 0;
}
return j2 / ((long) jArr.length);
}
public void freeP2P() {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.freeP2P();
}
}
public void initP2P() {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer != null) {
cameraPlayer.initP2P();
}
}
public static void enableHardDecodingGlobal(boolean z) {
CameraPlayer.setMediacodecGobal(z);
}
public void startConnect(final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->startConnect--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
String str = this.TAG;
Logger.m3729i(str, "--->startConnect--object: " + toString() + "; string: " + SdkUtils.getConnectString(this.cameraInfo));
this.cameraPlayer.connectIPC2(SdkUtils.getConnectString(this.cameraInfo), new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.1
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startConnect--success--object: " + MeariDeviceController.this.toString() + "--" + str2);
meariDeviceListener.onSuccess(str2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startConnect--failed--object: " + MeariDeviceController.this.toString() + "--" + str2);
meariDeviceListener.onFailed(str2);
}
});
}
public void stopConnect(final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->stopConnect--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
String str = this.TAG;
Logger.m3729i(str, "--->stopConnect--start--object: " + toString());
this.cameraPlayer.disconnectIPC(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.2
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->stopConnect--success--object: " + MeariDeviceController.this.toString() + "--" + str2);
meariDeviceListener.onSuccess(str2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->stopConnect--failed--object: " + MeariDeviceController.this.toString() + "--" + str2);
meariDeviceListener.onFailed(str2);
}
});
}
public void startPreview(PPSGLSurfaceView pPSGLSurfaceView, int i, final MeariDeviceListener meariDeviceListener, MeariDeviceVideoStopListener meariDeviceVideoStopListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->startPreview--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
String str = this.TAG;
Logger.m3729i(str, "--->startPreview--start--videoId: " + i);
this.cameraPlayer.startPreview(pPSGLSurfaceView, i, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.3
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startPreview--success: " + str2);
meariDeviceListener.onSuccess(str2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startPreview--failed: " + str2);
meariDeviceListener.onFailed(str2);
}
}, new CameraPlayerVideoStopListener(meariDeviceVideoStopListener) { // from class: com.meari.sdk.-$$Lambda$MeariDeviceController$Z5IvjVr9A2whNED0L3sMtMaQQxc
public final /* synthetic */ MeariDeviceVideoStopListener f$1;
{
this.f$1 = r2;
}
@Override // com.ppstrong.ppsplayer.CameraPlayerVideoStopListener
public final void onCameraPlayerVideoClosed(int i2) {
MeariDeviceController.this.lambda$startPreview$0$MeariDeviceController(this.f$1, i2);
}
});
}
public /* synthetic */ void lambda$startPreview$0$MeariDeviceController(MeariDeviceVideoStopListener meariDeviceVideoStopListener, int i) {
String str = this.TAG;
Logger.m3729i(str, "--->startPreview--VideoStopListener: " + i);
meariDeviceVideoStopListener.onVideoClosed(i);
}
public void stopPreview(final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->stopPreview--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
Logger.m3729i(this.TAG, "--->stopPreview--start");
this.cameraPlayer.stopPreview(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.4
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopPreview--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopPreview--failed: " + str);
meariDeviceListener.onFailed(str);
}
});
}
public void changeVideoResolution(PPSGLSurfaceView pPSGLSurfaceView, int i, final MeariDeviceListener meariDeviceListener, MeariDeviceVideoStopListener meariDeviceVideoStopListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->changeVideoResolution--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
String str = this.TAG;
Logger.m3729i(str, "--->changeVideoResolution--start--videoId: " + i);
this.cameraPlayer.changePreview(pPSGLSurfaceView, i, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.5
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->changeVideoResolution--success: " + str2);
meariDeviceListener.onSuccess(str2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->changeVideoResolution--failed: " + str2);
meariDeviceListener.onFailed(str2);
}
}, new CameraPlayerVideoStopListener(meariDeviceVideoStopListener) { // from class: com.meari.sdk.-$$Lambda$MeariDeviceController$DJ8T4VCOH7_knPfxunJobLfZfGw
public final /* synthetic */ MeariDeviceVideoStopListener f$1;
{
this.f$1 = r2;
}
@Override // com.ppstrong.ppsplayer.CameraPlayerVideoStopListener
public final void onCameraPlayerVideoClosed(int i2) {
MeariDeviceController.this.lambda$changeVideoResolution$1$MeariDeviceController(this.f$1, i2);
}
});
}
public /* synthetic */ void lambda$changeVideoResolution$1$MeariDeviceController(MeariDeviceVideoStopListener meariDeviceVideoStopListener, int i) {
String str = this.TAG;
Logger.m3729i(str, "--->changeVideoResolution--StopListener-code: " + i);
meariDeviceVideoStopListener.onVideoClosed(i);
}
public void getPlaybackVideoDaysInMonth(int i, int i2, int i3, final IPlaybackDaysCallback iPlaybackDaysCallback) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->getPlaybackVideoDaysInMonth--CameraPlayer is null");
iPlaybackDaysCallback.onFailed("CameraPlayer is null");
return;
}
String str = this.TAG;
Logger.m3729i(str, "--->getPlaybackVideoDaysInMonth--start: " + i + ";" + i2 + ";" + i3);
this.cameraPlayer.searchPlaybackListOnMonth(i, i2, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.6
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->getPlaybackVideoDaysInMonth--success: " + str2);
iPlaybackDaysCallback.onSuccess(JsonUtil.getPlaybackDays(str2));
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->getPlaybackVideoDaysInMonth--failed: " + str2);
iPlaybackDaysCallback.onFailed(str2);
}
}, i3);
}
public void getPlaybackVideoTimesInDay(int i, int i2, int i3, int i4, final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->getPlaybackVideoTimesInDay--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
BaseJSONObject baseJSONObject = new BaseJSONObject();
baseJSONObject.put("action", "POST");
baseJSONObject.put("rec_type", 0);
baseJSONObject.put("videoid", i4);
baseJSONObject.put("day", String.format(Locale.CHINA, "%04d%02d%02d", Integer.valueOf(i), Integer.valueOf(i2), Integer.valueOf(i3)));
baseJSONObject.put("deviceurl", "http://127.0.0.1/devices/record/search_by_day");
String str = this.TAG;
Logger.m3729i(str, "--->getPlaybackVideoTimesInDay--start: " + i + ";" + i2 + ";" + i3);
this.cameraPlayer.commondeviceparams2(baseJSONObject.toString(), new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.7
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->getPlaybackVideoTimesInDay--success: " + str2);
meariDeviceListener.onSuccess(str2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->getPlaybackVideoTimesInDay--failed: " + str2);
meariDeviceListener.onFailed(str2);
}
});
}
public void startPlaybackSDCard(PPSGLSurfaceView pPSGLSurfaceView, int i, String str, final MeariDeviceListener meariDeviceListener, MeariDeviceVideoStopListener meariDeviceVideoStopListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->startPlaybackSDCard--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
} else if (pPSGLSurfaceView == null) {
Logger.m3729i(this.TAG, "--->startPlaybackSDCard--ppsGLSurfaceView is null");
meariDeviceListener.onFailed("ppsGLSurfaceView is null");
} else {
String str2 = this.TAG;
Logger.m3729i(str2, "--->startPlaybackSDCard--start--videoId: " + i + "; startTime: " + str);
this.cameraPlayer.startPlaybackSd(pPSGLSurfaceView, str, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.8
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->startPlaybackSDCard--success: " + str3);
meariDeviceListener.onSuccess(str3);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->startPlaybackSDCard--failed: " + str3);
meariDeviceListener.onFailed(str3);
}
}, new CameraPlayerVideoStopListener(meariDeviceVideoStopListener) { // from class: com.meari.sdk.-$$Lambda$MeariDeviceController$c6TxJn55LV_kBJsEnJBhi7dyCr0
public final /* synthetic */ MeariDeviceVideoStopListener f$1;
{
this.f$1 = r2;
}
@Override // com.ppstrong.ppsplayer.CameraPlayerVideoStopListener
public final void onCameraPlayerVideoClosed(int i2) {
MeariDeviceController.this.lambda$startPlaybackSDCard$2$MeariDeviceController(this.f$1, i2);
}
}, i);
}
}
public /* synthetic */ void lambda$startPlaybackSDCard$2$MeariDeviceController(MeariDeviceVideoStopListener meariDeviceVideoStopListener, int i) {
String str = this.TAG;
Logger.m3729i(str, "--->startPlaybackSDCard--videoStopListener-code: " + i);
meariDeviceVideoStopListener.onVideoClosed(i);
}
public void seekPlaybackSDCard(String str, final MeariDeviceListener meariDeviceListener, MeariDeviceVideoSeekListener meariDeviceVideoSeekListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->seekPlaybackSDCard--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
String str2 = this.TAG;
Logger.m3729i(str2, "--->seekPlaybackSDCard--start--seekTime:" + str);
this.cameraPlayer.sendPlaybackCmd(0, str, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.9
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->seekPlaybackSDCard--success: " + str3);
meariDeviceListener.onSuccess(str3);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->seekPlaybackSDCard--failed: " + str3);
meariDeviceListener.onFailed(str3);
}
}, new CameraPlayerVideoSeekListener(meariDeviceVideoSeekListener) { // from class: com.meari.sdk.-$$Lambda$MeariDeviceController$MqnCNTA5aPglKnvuNWJZ0R3o9Qo
public final /* synthetic */ MeariDeviceVideoSeekListener f$1;
{
this.f$1 = r2;
}
@Override // com.ppstrong.ppsplayer.CameraPlayerVideoSeekListener
public final void onCameraPlayerVideoSeek() {
MeariDeviceController.this.lambda$seekPlaybackSDCard$3$MeariDeviceController(this.f$1);
}
}, true);
}
public /* synthetic */ void lambda$seekPlaybackSDCard$3$MeariDeviceController(MeariDeviceVideoSeekListener meariDeviceVideoSeekListener) {
Logger.m3729i(this.TAG, "--->seekPlaybackSDCard--SeekListener");
meariDeviceVideoSeekListener.onVideoSeek();
}
public void pausePlaybackSDCard(final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->pausePlaybackSDCard--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
Logger.m3729i(this.TAG, "--->pausePlaybackSDCard--start");
this.cameraPlayer.sendPlaybackCmd(1, null, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.10
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->pausePlaybackSDCard--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->pausePlaybackSDCard--failed: " + str);
meariDeviceListener.onFailed(str);
}
}, lambda.INSTANCE, true);
}
public void resumePlaybackSDCard(final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->resumePlaybackSDCard--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
Logger.m3729i(this.TAG, "--->resumePlaybackSDCard--start: ");
this.cameraPlayer.sendPlaybackCmd(2, null, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.11
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->resumePlaybackSDCard--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->resumePlaybackSDCard--failed: " + str);
meariDeviceListener.onFailed(str);
}
}, $$Lambda$MeariDeviceController$29iaIfBgajeCHkIxfiun1g0Bnpk.INSTANCE, true);
}
public void stopPlaybackSDCard(final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->stopPlaybackSDCard--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
Logger.m3729i(this.TAG, "--->stopPlaybackSDCard--start");
this.cameraPlayer.stopPlaybackSd(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.12
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopPlaybackSDCard--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopPlaybackSDCard--failed: " + str);
meariDeviceListener.onFailed(str);
}
});
}
public void setMute(boolean z) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->setMute--CameraPlayer is null");
return;
}
String str = this.TAG;
Logger.m3729i(str, "--->setMute--isMute: " + z);
CameraPlayer cameraPlayer = this.cameraPlayer;
cameraPlayer.enableMute(z, cameraPlayer.getPlayMode());
}
public void snapshot(String str, final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer.getPlayMode() == 0) {
String str2 = this.TAG;
Logger.m3729i(str2, "--->snapshot--preview--start: " + str);
this.cameraPlayer.Playsnapshot(str, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.13
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->snapshot--preview--success: " + str3);
meariDeviceListener.onSuccess(str3);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->snapshot--preview--failed: " + str3);
meariDeviceListener.onFailed(str3);
}
});
return;
}
Logger.m3729i(this.TAG, "--->snapshot--playback--start");
this.cameraPlayer.Playbacksnapshot(str, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.14
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->snapshot--playback--success: " + str3);
meariDeviceListener.onSuccess(str3);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str3) {
String str4 = MeariDeviceController.this.TAG;
Logger.m3729i(str4, "--->snapshot--playback--failed: " + str3);
meariDeviceListener.onFailed(str3);
}
});
}
public void startRecordMP4(String str, final MeariDeviceListener meariDeviceListener, MeariDeviceRecordMp4Listener meariDeviceRecordMp4Listener) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->startRecordMP4--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
} else if (cameraPlayer.getPlayMode() == 0) {
Logger.m3729i(this.TAG, "--->startRecordMP4--preview--start");
this.cameraPlayer.startPlayRecordMp4(str, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.15
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startRecordMP4--preview--success: " + str2);
meariDeviceListener.onSuccess(str2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startRecordMP4--preview--failed: " + str2);
meariDeviceListener.onFailed(str2);
}
}, new CameraPlayerRecordMp4Listener(meariDeviceRecordMp4Listener) { // from class: com.meari.sdk.-$$Lambda$MeariDeviceController$KtNMUDJ1M6gFZq-_XnoIoUg5W_s
public final /* synthetic */ MeariDeviceRecordMp4Listener f$1;
{
this.f$1 = r2;
}
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordMp4Listener
public final void RecordMp4Interrupt(int i) {
MeariDeviceController.this.lambda$startRecordMP4$6$MeariDeviceController(this.f$1, i);
}
});
} else {
Logger.m3729i(this.TAG, "--->startRecordMP4--playback--start");
this.cameraPlayer.startPlaybackRecordMp4(str, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.16
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startRecordMP4--playback--success: " + str2);
meariDeviceListener.onSuccess(str2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str2) {
String str3 = MeariDeviceController.this.TAG;
Logger.m3729i(str3, "--->startRecordMP4--playback--failed: " + str2);
meariDeviceListener.onFailed(str2);
}
}, new CameraPlayerRecordMp4Listener(meariDeviceRecordMp4Listener) { // from class: com.meari.sdk.-$$Lambda$MeariDeviceController$O9dA4FlWgiFiN1nJ5VhqOS4QUA8
public final /* synthetic */ MeariDeviceRecordMp4Listener f$1;
{
this.f$1 = r2;
}
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordMp4Listener
public final void RecordMp4Interrupt(int i) {
MeariDeviceController.this.lambda$startRecordMP4$7$MeariDeviceController(this.f$1, i);
}
});
}
}
public /* synthetic */ void lambda$startRecordMP4$6$MeariDeviceController(MeariDeviceRecordMp4Listener meariDeviceRecordMp4Listener, int i) {
String str = this.TAG;
Logger.m3729i(str, "--->startRecordMP4--preview--RecordMp4Interrupt: " + i);
meariDeviceRecordMp4Listener.RecordMp4Interrupt(i);
}
public /* synthetic */ void lambda$startRecordMP4$7$MeariDeviceController(MeariDeviceRecordMp4Listener meariDeviceRecordMp4Listener, int i) {
String str = this.TAG;
Logger.m3729i(str, "--->startRecordMP4--playback--RecordMp4Interrupt: " + i);
meariDeviceRecordMp4Listener.RecordMp4Interrupt(i);
}
public void stopRecordMP4(final MeariDeviceListener meariDeviceListener) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->stopRecordMP4--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
} else if (cameraPlayer.getPlayMode() == 0) {
Logger.m3729i(this.TAG, "--->stopRecordMP4--preview--start");
this.cameraPlayer.stopPlayRecordMp4(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.17
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopRecordMP4--preview--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopRecordMP4--preview--failed: " + str);
meariDeviceListener.onFailed(str);
}
});
} else {
Logger.m3729i(this.TAG, "--->stopRecordMP4--playback--start");
this.cameraPlayer.stopPlaybackRecordMp4(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.18
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopRecordMP4--playback--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopRecordMP4--playback--failed: " + str);
meariDeviceListener.onFailed(str);
}
});
}
}
public void startVoiceTalk(int i, final MeariDeviceListener meariDeviceListener, final MeariDeviceTalkVolumeListener meariDeviceTalkVolumeListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->startVoiceTalk--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
} else if (i == 1) {
Logger.m3729i(this.TAG, "--->startVoiceTalk--1--start");
this.cameraPlayer.startvoicetalk(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.19
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--1--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--1--failed: " + str);
meariDeviceListener.onFailed(str);
}
}, new CameraPlayerRecordVolumeListener() { // from class: com.meari.sdk.MeariDeviceController.20
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordVolumeListener
public void onCameraPlayerRecordvolume(int i2) {
String str = MeariDeviceController.this.TAG;
Logger.m3729i(str, "--->startVoiceTalk--1--listener--volume: " + i2);
meariDeviceTalkVolumeListener.onTalkVolume(i2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordVolumeListener
public void error(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--1--listener--error: " + str);
meariDeviceTalkVolumeListener.onFailed(str);
}
});
} else if (i == 2) {
Logger.m3729i(this.TAG, "--->startVoiceTalk--2--start");
this.cameraPlayer.startVoiceTalkForVQE(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.21
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--2--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--2--failed: " + str);
meariDeviceListener.onFailed(str);
}
}, new CameraPlayerRecordVolumeListener() { // from class: com.meari.sdk.MeariDeviceController.22
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordVolumeListener
public void onCameraPlayerRecordvolume(int i2) {
String str = MeariDeviceController.this.TAG;
Logger.m3729i(str, "--->startVoiceTalk--2--listener--volume: " + i2);
meariDeviceTalkVolumeListener.onTalkVolume(i2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordVolumeListener
public void error(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--2--listener--error: " + str);
meariDeviceTalkVolumeListener.onFailed(str);
}
});
} else if (i == 3) {
Logger.m3729i(this.TAG, "--->startVoiceTalk--3--start");
this.cameraPlayer.startVoiceTalkForVoiceBell(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.23
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--3--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--3--failed: " + str);
meariDeviceListener.onFailed(str);
}
}, new CameraPlayerRecordVolumeListener() { // from class: com.meari.sdk.MeariDeviceController.24
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordVolumeListener
public void onCameraPlayerRecordvolume(int i2) {
String str = MeariDeviceController.this.TAG;
Logger.m3729i(str, "--->startVoiceTalk--3--listener--volume: " + i2);
meariDeviceTalkVolumeListener.onTalkVolume(i2);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerRecordVolumeListener
public void error(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->startVoiceTalk--3--listener--error: " + str);
meariDeviceTalkVolumeListener.onFailed(str);
}
});
}
}
public void stopVoiceTalk(final MeariDeviceListener meariDeviceListener) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->stopVoiceTalk--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
Logger.m3729i(this.TAG, "--->stopVoiceTalk--start");
this.cameraPlayer.stopvoicetalk(new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.25
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopVoiceTalk--success: " + str);
meariDeviceListener.onSuccess(str);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str) {
String str2 = MeariDeviceController.this.TAG;
Logger.m3729i(str2, "--->stopVoiceTalk--failed: " + str);
meariDeviceListener.onFailed(str);
}
});
}
public void changeG711u2WAV(String str, String str2, final MeariDeviceListener meariDeviceListener) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->changeG711u2WAV--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
cameraPlayer.changeG711u2WAV(str, str2, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.26
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str3) {
meariDeviceListener.onSuccess(str3);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str3) {
meariDeviceListener.onFailed(str3);
}
});
}
public void changeG711u2Pcm(String str, String str2, final MeariDeviceListener meariDeviceListener) {
CameraPlayer cameraPlayer = this.cameraPlayer;
if (cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->changeG711u2Pcm--CameraPlayer is null");
meariDeviceListener.onFailed("CameraPlayer is null");
return;
}
cameraPlayer.changeG711u2Pcm(str, str2, new CameraPlayerListener() { // from class: com.meari.sdk.MeariDeviceController.27
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPSuccessHandler(String str3) {
meariDeviceListener.onSuccess(str3);
}
@Override // com.ppstrong.ppsplayer.CameraPlayerListener
public void PPFailureError(String str3) {
meariDeviceListener.onFailed(str3);
}
});
}
public void startRecordVoiceMail(String str, String str2) {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->startRecordVoiceMail--CameraPlayer is null");
return;
}
String str3 = this.TAG;
Logger.m3729i(str3, "--->startRecordVoiceMail--start--pcmPath: " + str + "; g711uPath: " + str2);
this.cameraPlayer.startRecordVoice(str, str2);
}
public void stopRecordVoiceMail() {
if (this.cameraPlayer == null) {
Logger.m3729i(this.TAG, "--->stopRecordVoiceMail--CameraPlayer is null");
return;
}
Logger.m3729i(this.TAG, "--->stopRecordVoiceMail--start");
this.cameraPlayer.stopRecordVoice();
}
public void startPTZControl(String str) {