Effacer les filtres
Effacer les filtres

Can anyone answer what is the error about (attached image)?

2 vues (au cours des 30 derniers jours)
Surya Gnyawali
Surya Gnyawali le 8 Fév 2017
Commenté : Walter Roberson le 16 Fév 2017
I was trying to delete some frames from a video (>1500 frames). Want to cut down the size by deleting frames that are affected by noise. Took this code from file exchange.But while running to my situational video the attached error popups. Thanks for helping
  4 commentaires
Geoff Hayes
Geoff Hayes le 9 Fév 2017
Surya - the error message is telling you that not enough input parameters are being supplied to aviinfo. I see this function being called from within cropavi but perhaps you are calling it yourself from your main program and not passing the single input parameter? Can you show us some of your code that leads to this error?
Surya Gnyawali
Surya Gnyawali le 9 Fév 2017
Modifié(e) : Surya Gnyawali le 9 Fév 2017
I directly used the code. cropavi.m, I asked my IT personnel to install the windows drivers "Windows 7 Codec Pack" just in case if nay drivers were missing in my computer.
Thanks for helping!

Connectez-vous pour commenter.

Réponse acceptée

Walter Roberson
Walter Roberson le 10 Fév 2017
Unfortunately that code was written for older versions of MATLAB. If you manage to get past the aviinfo problem then you would fail because it relies on aviread() which no longer exists.
I fixed the code up in a couple of places for later versions, and added a little error checking. I have enclosed the changed version. It will not work for many more releases at all, as it relies upon aviinfo() which is going away soon. As it has that dependency I also let it have a dependency on the less recommended read() method of VideoReader instead of switching it to readframe, to make it easier to position to particular frames.
I cannot promise that it works in this version; unfortunately on my system there is a problem in reading most .avi files that I will have to explore with Mathworks; because of that problem I could not test the code through to the actual reading.
  8 commentaires
Surya Gnyawali
Surya Gnyawali le 16 Fév 2017
on the aviinfo() line img1 and next line img2 attached.
Could not go to fprintf().
Walter Roberson
Walter Roberson le 16 Fév 2017
When you reach the breakpoint, type those fprintf() in at the command line and report the results.

Connectez-vous pour commenter.

Plus de réponses (0)

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by