MATLAB Project: Tips, Guide & Concepts

  • Context: MATLAB 
  • Thread starter Thread starter needOfHelpCMath
  • Start date Start date
  • Tags Tags
    Matlab Project
Click For Summary
SUMMARY

The discussion revolves around a MATLAB project involving image processing and video creation. The user seeks assistance with a for loop designed to access images from a specified directory and display them using the dicomread function. Key issues include correctly implementing the loop and managing image resizing with imresize. The user also attempts to write a video file using VideoWriter but encounters challenges with image readability.

PREREQUISITES
  • Familiarity with MATLAB programming environment
  • Understanding of image processing functions such as dicomread and imresize
  • Knowledge of video creation in MATLAB using VideoWriter
  • Basic understanding of file handling and directory management in MATLAB
NEXT STEPS
  • Explore MATLAB's dicomread documentation for image reading techniques
  • Learn about MATLAB's VideoWriter options and settings for video creation
  • Investigate MATLAB's image processing toolbox for advanced image manipulation techniques
  • Review best practices for using loops in MATLAB to handle multiple files
USEFUL FOR

This discussion is beneficial for students and professionals working on MATLAB projects, particularly those focused on image processing and video generation. It is also useful for anyone seeking to improve their coding practices in MATLAB.

needOfHelpCMath
Messages
70
Reaction score
0
I have a project and i need some help to understand the concepts, what is it asking for, major tips, and guide me through the process of the project. The program I will be using to program will be MATLAB.https://blackboard.learn.fresnostat.../ECE72-01-74696-2167/Project 2 Directions.pdf
Code:
 // This is my for loop that i have to use to access my picture but unsure if it correct
           // THIS IS NOT FOR C++
srcFiles = dir('C:\Users\James\Documents\MATLAB\image');
for i = 1 : length(image)
  filename = image('',image(i).name);
  I = dicomread(filename);
  figure, imshow(I);
end
Code:
writerObj = VideoWriter(myAnimation, 'MPEG-4');
writerObj.FrameRate = 0.5;
open(writerObj);

a = imread('robot','jpg');
B=imresize(a,0.25);
figure(1)
imshow(B);

writeVideo(writeObj,'robot','jpg'); 

close(writeObj);
 

Attachments

Last edited:
Physics news on Phys.org
I, for one, cannot read those images.

You've posted an entire assignment without showing any work. What do you expect us to do?
 
Sorry for my bad images and not showing my work. I had class back to back had only 20 min passing period. I will tried resize the image show some of my work. :D
 
So I struggle trying put up the image so instead link the website to my pdf hopefully makes it better.
 

Similar threads

  • · Replies 10 ·
Replies
10
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 4 ·
Replies
4
Views
31K