HOW CAN I LEARN MEX-FILES

조회 수: 11 (최근 30일)
AYMAN
AYMAN 2012년 9월 4일
HOW CAN I LEARN MEX-FILES
  댓글 수: 2
Friedrich
Friedrich 2012년 9월 4일
First learn C, than read the ML doc about the MEX interface, so the mx**** function defintitions.
TAB
TAB 2012년 9월 4일
편집: TAB 2012년 9월 4일
In C or Fortron ?

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

답변 (2개)

TAB
TAB 2012년 9월 4일
편집: TAB 2012년 9월 5일
[Edited 05-Sep-2012]
This document will guide you through step by step procedure to create a C-mex file, call the existing C function in it, build it and call it in matlab.
The structure of a basic c-mex file is
#include "mex.h"
void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])
{
/* variable declarations */
/* Write your code Or Call existing function*/
}

AYMAN
AYMAN 2012년 9월 4일
honestly i want to call c code and run into matlab so can you tell me about the steps of using mex-files
  댓글 수: 1
TAB
TAB 2012년 9월 5일
See edited part of my answer.

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

카테고리

Help CenterFile Exchange에서 Write C Functions Callable from MATLAB (MEX Files)에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by