Program Listing for File XLinkIn.hpp

Return to documentation for file (include/depthai/pipeline/node/XLinkIn.hpp)

#pragma once

#include <depthai/pipeline/Node.hpp>

// shared
#include <depthai-shared/properties/XLinkInProperties.hpp>

namespace dai {
namespace node {

class XLinkIn : public NodeCRTP<Node, XLinkIn, XLinkInProperties> {
   public:
    constexpr static const char* NAME = "XLinkIn";

   public:
    XLinkIn(const std::shared_ptr<PipelineImpl>& par, int64_t nodeId);
    XLinkIn(const std::shared_ptr<PipelineImpl>& par, int64_t nodeId, std::unique_ptr<Properties> props);

    Output out{*this, "out", Output::Type::MSender, {{DatatypeEnum::Buffer, true}}};

    void setStreamName(const std::string& name);

    void setMaxDataSize(std::uint32_t maxDataSize);

    void setNumFrames(std::uint32_t numFrames);

    std::string getStreamName() const;
    std::uint32_t getMaxDataSize() const;
    std::uint32_t getNumFrames() const;
};

}  // namespace node
}  // namespace dai