videoFrame = snapshot(cam);
frameSize = size(videoFrame);
videoPlayer = vision.VideoPlayer('Position', [100 100 [frameSize(2), frameSize(1)]+30]);
videoFrame = snapshot(cam);
results = ocr(videoFrame);
Ninshikimoji = lower(results.Words);
Ninshikiwaku = results.WordBoundingBoxes;
Jisho = readtable('allergy.xlsx','ReadRowNames',true);
word = categorical(Jisho.word);
for n = 1:size(Ninshikimoji,1)
if any(word == Ninshikimoji{n})
Shoukai = Jisho{Ninshikimoji{n},:};
videoFrame = insertObjectAnnotation(videoFrame,'rectangle',Ninshikiwaku(n,:),Shoukai{:},'font','Yu Gothic Bold');
x = Ninshikiwaku(n,1); y = Ninshikiwaku(n,2); w = Ninshikiwaku(n,3); h = Ninshikiwaku(n,4);
logo = imresize(imread([Shoukai{:} '.png']),0.3);
VideoFrame(y:(y+size(logo,1)-1),(x+w):(x+w+size(logo,2)-1),:) = logo;
Mininshiki = [Mininshiki ' ' Ninshikimoji{n}];
step(videoPlayer, videoFrame);
runLoop = isOpen(videoPlayer);