How do I produce a solid green image directly above an imported image

조회 수: 3 (최근 30일)
HG24
HG24 2019년 6월 3일
답변: KSSV 2019년 6월 3일
I have imported an image and I require there to be a solid green image of the same dimensions directly above the imported image. How would I go about doing this? I have attempted using patch but to no success.
  댓글 수: 2
KALYAN ACHARJYA
KALYAN ACHARJYA 2019년 6월 3일
편집: KALYAN ACHARJYA 2019년 6월 3일
directly above the imported image??
Question is not clear? What result you are expecting? May be you require one green image (plane) having size equal to the processed image. Clarify ?
HG24
HG24 2019년 6월 3일
편집: HG24 2019년 6월 3일
Essentially I require 2 images, one of a solid green square and beneath it my imported image. I have attached an image of it

댓글을 달려면 로그인하십시오.

채택된 답변

KSSV
KSSV 2019년 6월 3일
I1 = imread('peppers.png') ;
[nx,ny,nz] = size(I1) ;
I2 = zeros(nx,ny,nz) ;
I2(:,:,2) = 255 ;
I12 = vertcat(I2,I1) ;
imshow(I12)

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Lighting, Transparency, and Shading에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by