New Features

Box

A “contains” function has been added to check whether the given Box is completely inside the current Box:

bool contains(const Box& other) const;

ImagePlane

A function has been added to fill a channel with a value using multiple threads:

void fillChannelThreaded(Channel z, float value);

Iop

Iop has had minor changes to support ongoing performance work.
  • Iop::get(...) has been made virtual.

  • Iop::engine(...) has been made public.

  • The full requested box is now stored. Previously, the requested box was only stored after having been clamped to the available Info2D.

MultiTileIop

MultiTile.h has been removed from DDImage and replaced by MultiTileIop.h. To optimise Ops to read efficiently for all of the Tile types available in Nuke, you should now inherit from MultiTileIop. This provides pure virtual functions for implementations of engine for each type of Tile available. See MultiTileIop.h for full details.

Op

A new function to locate the memory that will be stored into by a knob has been added:

void* field(const char* name, FieldFormat& fieldFormat);

This is similar to the existing field functions but takes a FieldFormat that can be used to do type-safety checking. The FieldFormats are listed in the new file OpFields.h.

New virtual functions have been added to retrieve the name and version of a plugin’s associated library:

virtual std::string getLibraryName() const { return {}; } virtual VersionInfo getLibraryVersion() const { return kUnsetVersion; }

VersionInfo is a tuple with 4 components to contain the major, minor, point and revision parts of the version number respectively.

A new function to return the Ops hints has been added:

//! Return hints to control when and how this op will be evaluated by the top-down system.
virtual OpHints opHints() const;

Ops return OpHints::eIgnore by default, which indicates that they will not be evaluated in top-down order. However, most ops typically inherit from a more specialised Op class (Iop, GeoOp, etc) that returns different hints. Most notably, Iops return OpHints::eDefault to indicate that they should be evaluated in top-down order.

PlanarI

A new virtual function has been added:

virtual bool stripesCanBeRenderedInParallel() { return false; }

This should return true if the Op implementing PlanarI does not do its own threading, and if it is safe to render multiple output stripes at the same time on parallel threads. Currently, it is guaranteed that renderStripe( ImagePlane& ) will be called from a single thread, but this might change in future. For Ops that do not do their own threading, returning true from this function will allow them to benefit from any future performance improvements in this area automatically.

Read

Functions to get and set the file type have been made public. There is also a new version of make_format that takes a filename.

Row

New functions have been added to manipulate the data pointers inside Rows. Use read(Channel, float*) to make the Row read data from an existing buffer. You can also call setPreallocatedWriteBuffer(Channel, float*) to give the Row a buffer to write into the next time Row::writable is called.

UpRez

UpRez is now a MultiTileIop.

VConvolve

VConvolve is now a MultiTileIop.

MemHolderFactory

Originally MemoryHolderFactory has been replaced with MemHolderFactory.