MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / copyFrom

Method copyFrom

JUCE/modules/juce_core/memory/juce_MemoryBlock.cpp:221–237  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

219}
220
221void MemoryBlock::copyFrom (const void* const src, int offset, size_t num) noexcept
222{
223 auto* d = static_cast<const char*> (src);
224
225 if (offset < 0)
226 {
227 d -= offset;
228 num += (size_t) -offset;
229 offset = 0;
230 }
231
232 if ((size_t) offset + num > size)
233 num = size - (size_t) offset;
234
235 if (num > 0)
236 memcpy (data + offset, d, num);
237}
238
239void MemoryBlock::copyTo (void* const dst, int offset, size_t num) const noexcept
240{

Callers 15

runTestMethod · 0.45
copyingTestsMethod · 0.45
processSamplesMethod · 0.45
fixNumChannelsFunction · 0.45
trimImpulseResponseFunction · 0.45
processSamplesMethod · 0.45
processSamplesMethod · 0.45
testConvolutionMethod · 0.45
runTestMethod · 0.45
processMethod · 0.45
processMethod · 0.45

Calls

no outgoing calls

Tested by 4

runTestMethod · 0.36
copyingTestsMethod · 0.36
testConvolutionMethod · 0.36
runTestMethod · 0.36