MCPcopy Create free account
hub / github.com/Kitware/VTK / SetTuple

Method SetTuple

Common/Core/vtkBitArray.cxx:399–415  ·  view source on GitHub ↗

------------------------------------------------------------------------------ Description: Set the tuple at the ith location using the jth tuple in the source array. This method assumes that the two arrays have the same type and structure. Note that range checking and memory allocation is not performed; use in conjunction with SetNumberOfTuples() to allocate space.

Source from the content-addressed store, hash-verified

397// and structure. Note that range checking and memory allocation is not
398// performed; use in conjunction with SetNumberOfTuples() to allocate space.
399void vtkBitArray::SetTuple(vtkIdType i, vtkIdType j, vtkAbstractArray* source)
400{
401 vtkBitArray* ba = vtkArrayDownCast<vtkBitArray>(source);
402 if (!ba)
403 {
404 vtkWarningMacro("Input and output arrays types do not match.");
405 return;
406 }
407
408 vtkIdType loci = i * this->NumberOfComponents;
409 vtkIdType locj = j * ba->GetNumberOfComponents();
410 for (vtkIdType cur = 0; cur < this->NumberOfComponents; cur++)
411 {
412 this->SetValue(loci + cur, ba->GetValue(locj + cur));
413 }
414 this->DataChanged();
415}
416
417//------------------------------------------------------------------------------
418// Description:

Callers 15

DeepCopyMethod · 0.95
operator()Method · 0.45
RequestDataMethod · 0.45
ApplyMorphingToDataArrayFunction · 0.45
ReadUniformValuesMethod · 0.45
ReadBinaryListMethod · 0.45
MoveBoundaryMeshMethod · 0.45
FillFieldMethod · 0.45
GetVolFieldAtTimeStepMethod · 0.45
ProcessTriangleMethod · 0.45
ProcessColumnOrderingMethod · 0.45

Calls 4

SetValueMethod · 0.95
DataChangedMethod · 0.95
GetNumberOfComponentsMethod · 0.45
GetValueMethod · 0.45

Tested by 15

populateAttributesFunction · 0.36
fill_arrayFunction · 0.36
TestCopyAttributeDataFunction · 0.36
testBitArrayArgumentsMethod · 0.36
testArrayMethod · 0.36
TestArrayAccessMethod · 0.36
TestSOADataArrayFunction · 0.36
TestVariantArrayFunction · 0.36
TestTupleRangeAPIFunction · 0.36
Create2DTransferToothFunction · 0.36
Create2DTransferFunction · 0.36