WSPutByteArray (C 関数)
int WSPutByteArray(WSLINK link,const unsigned char *a,const int *dims,const char **heads,int d)
範囲0–255内の整数配列を で指定されたWSTP接続に置き,次元 で深さが の配列を形成する.
例題
例 (1)
#include "wstp.h"
/* send a list of integers in the range 0-255 to a link */
void f(WSLINK lp)
{
unsigned char array[10][5][3][4];
long dims[4];
int i;
for(i = 0; i < 600; i++)
*((unsigned char *)array + i) = i;
dims[0] = 10;
dims[1] = 5;
dims[2] = 3;
dims[3] = 4;
if(! WSPutByteArray(lp, (unsigned char *)array, (long *)dims, (char **)0, 4))
{ /* unable to send array of integers to lp */ }
}