This repository was archived by the owner on Feb 6, 2023. It is now read-only.
Description 左右明显被切
- (void)viewDidLoad {
[super viewDidLoad];
self.player = [[SVGAPlayer alloc] initWithFrame:CGRectMake(0, 0, 58, 65)];
self.player.backgroundColor = UIColor.blackColor;
self.player.center = self.view.center;
[self.view addSubview:self.player];
self.parser = [[SVGAParser alloc] init];
NSString *str = @"https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fup.enterdesk.com%2Fedpic%2F76%2F7b%2F57%2F767b578c5e68a890cf98b5b7e002aca8.jpeg&refer=http%3A%2F%2Fup.enterdesk.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1642659725&t=eb1aa225d1a5216b671b28d5ae577c26";
[self.player setImageWithURL:[NSURL URLWithString:str] forKey:@"avatar1"];
__weak typeof(self) weakself = self;
[self.parser parseWithNamed:@"直播中-中号" inBundle:nil completionBlock:^(SVGAVideoEntity * _Nonnull videoItem) {
weakself.player.videoItem = videoItem;
[weakself.player startAnimation];
} failureBlock:^(NSError * _Nonnull error) {
NSLog(@"发生错误:%@", error);
}];
}
效果图:
直播中-中号.svga.zip
相同的素材在Android中播放正常
Reactions are currently unavailable
左右明显被切
效果图:

直播中-中号.svga.zip
相同的素材在Android中播放正常