[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Octave bwlabel and imagesc in C++ API
From: |
Søren Hauberg |
Subject: |
Re: Octave bwlabel and imagesc in C++ API |
Date: |
Fri, 07 Oct 2011 08:45:41 +0200 |
tor, 06 10 2011 kl. 23:40 -0700, skrev attudlb:
> I am new to Octave C++ API. Trying use bwlabel and imagesc in C++. My code
> goes like the following:
>
> #include<iostream>
> #include<octave/oct.h>
> #include<octave/octave.h>
> #include<octave/oct-rand.h>
>
> int main()
> {
>
> Matrix A = octave_rand::matrix(10,10);
> std::cout << A;
> Matrix B = mx_el_gt(A,0.39);
> std::cout << B;
> Matrix C = bwlabel(B,4);
> std::cout << C;
> imagesc(C);
>
> }
>
> I am unable to find how to use bwlabel and imagesc in Octave C++ API. Pls
The short answer is that these functions are not part of the C++ API. If
you really want to use them from C++ (but are you sure that's really
what you want?) you will have to go through the interpreter, i.e. use
the 'feval' function.
Søren