Matlab生成《寻找唐可可》
前几天寻找唐可可的图大火,随手用matlab摸了个
依观众要求,此处放出代码
具体视频见https://www.bilibili.com/video/BV1ur4y1Q7tc?spm_id_from=333.999.0.0
运行环境
matlab2018b代码与素材
pic_line=0;pic_length=20;
pic_line=pic_line*2+10;
pic4=pic3(1:150,11:85,1:3);
tkk_pos=uint8(zeros(pic_line,pic_length));
pos=randi(pic_line*pic_length);
tkk_pos(fix(pos/pic_length)+1,mod(pos,pic_length)+1)=1;
pic_final=uint8(zeros(150+pic_length*75,pic_line*75,3));
pic_final(1:150,(pic_line-10)/2*75+1:(pic_line-10)/2*75+750,1:3)=pi