wfpacket.cpp
24 lines
| 504 B
| text/x-c
|
CppLexer
/ rmapplugin / wfpacket.cpp
r20 | #include "wfpacket.h" | |||
r58 | WFPacket::WFPacket(QObject *parent, unsigned int nbData) : | |||
r20 | QObject(parent) | |||
{ | ||||
r58 | this->nbSamples = nbData; | |||
r20 | // | |||
r58 | wf_v = (short*) malloc(2*nbData); | |||
wf_e1 = (short*) malloc(2*nbData); | ||||
wf_e2 = (short*) malloc(2*nbData); | ||||
wf_b1 = (short*) malloc(2*nbData); | ||||
wf_b2 = (short*) malloc(2*nbData); | ||||
wf_b3 = (short*) malloc(2*nbData); | ||||
r20 | } | |||
WFPacket::~WFPacket() | ||||
{ | ||||
free(wf_v); | ||||
free(wf_e1); | ||||
free(wf_e2); | ||||
free(wf_b1); | ||||
free(wf_b2); | ||||
free(wf_b3); | ||||
} | ||||