- #include "cxcore.h"
- int main( int argc, char** argv )
- {
- CvMat* mat = cvCreateMat( 3, 3, CV_32F );
- CvFileStorage* fs = cvOpenFileStorage( "example.yml", 0, CV_STORAGE_WRITE );
- cvSetIdentity( mat );
- cvWrite( fs, "A", mat, cvAttrList(0,0) );
- cvReleaseFileStorage( &fs );
- cvReleaseMat( &mat );
- return 0;
- }