• <xmp id="om0om">
  • <table id="om0om"><noscript id="om0om"></noscript></table>
  • Compute Graph Framework SDK Reference  5.14
    All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
    dwCameraChannelNode.hpp
    Go to the documentation of this file.
    1
    2//
    3// Notice
    4// ALL NVIDIA DESIGN SPECIFICATIONS AND CODE ("MATERIALS") ARE PROVIDED "AS IS" NVIDIA MAKES
    5// NO REPRESENTATIONS, WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
    6// THE MATERIALS, AND EXPRESSLY DISCLAIMS ANY IMPLIED WARRANTIES OF NONINFRINGEMENT,
    7// MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.
    8//
    9// NVIDIA CORPORATION & AFFILIATES assumes no responsibility for the consequences of use of such
    10// information or for any infringement of patents or other rights of third parties that may
    11// result from its use. No license is granted by implication or otherwise under any patent
    12// or patent rights of NVIDIA CORPORATION & AFFILIATES. No third party distribution is allowed unless
    13// expressly authorized by NVIDIA. Details are subject to change without notice.
    14// This code supersedes and replaces all information previously supplied.
    15// NVIDIA CORPORATION & AFFILIATES products are not authorized for use as critical
    16// components in life support devices or systems without express written approval of
    17// NVIDIA CORPORATION & AFFILIATES.
    18//
    19// SPDX-FileCopyrightText: Copyright (c) 2018-2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
    20// SPDX-License-Identifier: LicenseRef-NvidiaProprietary
    21//
    22// NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
    23// property and proprietary rights in and to this material, related
    24// documentation and any modifications thereto. Any use, reproduction,
    25// disclosure or distribution of this material and related documentation
    26// without an express license agreement from NVIDIA CORPORATION or
    27// its affiliates is strictly prohibited.
    28//
    30
    31#ifndef DW_FRAMEWORK_CAMERA_NODE_HPP_
    32#define DW_FRAMEWORK_CAMERA_NODE_HPP_
    33
    34#include <dwcgf/node/Node.hpp>
    37#include <dwcgf/port/Port.hpp>
    39#include <dwcgf/pass/Pass.hpp>
    41
    42#include <dwframework/dwnodes/common/SensorCommonTypes.hpp>
    43/* Need to include the appropriate ChannelPacketTypes.hpp since port initialization requires
    44 the parameter_trait overrides. Otherwise, it will be considered as a packet of generic type. */
    45//#include <dwframework/dwnodes/common/ChannelPacketTypes.hpp>
    47
    48#include <dw/sensors/Sensors.h>
    49#include <dw/sensors/SensorExtras.h>
    50#include <dw/sensors/camera/Camera.h>
    51
    52namespace dw
    53{
    54namespace framework
    55{
    56
    57class dwCameraChannelNodeImpl;
    58
    60{
    61 char8_t const* sensorName;
    62 cudaStream_t cudaStream;
    64 dwConstRigHandle_t rig;
    65 dwSALHandle_t sal;
    66 dw::core::FixedString<32> frameSkipMask;
    67 dwImageProperties imageProperties;
    68};
    69
    71{
    72public:
    73 static constexpr char LOG_TAG[] = "dwCameraChannelNode";
    74
    75 static constexpr auto describeInputPorts()
    76 {
    78 DW_DESCRIBE_PORT(dwCalibratedExtrinsics, "SENSOR_EXTRINSICS"_sv),
    79 DW_DESCRIBE_PORT(dwTime_t, "VIRTUAL_SYNC_TIME"_sv),
    80 DW_DESCRIBE_PORT(dwImageHandle_t, "IMAGE_NATIVE_PROCESSED"_sv));
    81 };
    82 static constexpr auto describeOutputPorts()
    83 {
    85 DW_DESCRIBE_PORT(dwSensorNodeProperties, "SENSOR_PROPERTIES"_sv),
    86 DW_DESCRIBE_PORT(dwFThetaCameraConfig, "INTRINSICS"_sv),
    87 DW_DESCRIBE_PORT(dwImageHandle_t, "IMAGE_NATIVE_PROCESSED"_sv),
    88 DW_DESCRIBE_PORT(dwTime_t, "IMAGE_TIMESTAMP"_sv),
    89 DW_DESCRIBE_PORT(dwTime_t, "NEXT_IMAGE_TIMESTAMP"_sv),
    90 DW_DESCRIBE_PORT(dwSensorTsAndID, "IMAGE_TIMESTAMP_AND_ID"_sv));
    91 };
    92
    93 static constexpr auto describePasses()
    94 {
    96 describePass("SETUP"_sv, DW_PROCESSOR_TYPE_CPU),
    97 describePass("PROCESSED_OUTPUT"_sv, DW_PROCESSOR_TYPE_GPU),
    98 describePass("TEARDOWN"_sv, DW_PROCESSOR_TYPE_CPU));
    99 };
    100
    101 dwSensorType getSensorType() const
    102 {
    103 return DW_SENSOR_CAMERA;
    104 }
    105
    106 static std::unique_ptr<dwCameraChannelNode> create(ParameterProvider& provider);
    107
    108 static constexpr auto describeParameters()
    109 {
    110 return describeConstructorArguments<dwCameraChannelNodeParams, dwContextHandle_t>(
    113 const char*,
    115 "cameraIndex"_sv,
    118 dwImageProperties,
    120 "cameraIndex"_sv,
    123 cudaStream_t,
    124 "streamIndex"_sv,
    127 bool,
    128 "useEEPROMIntrinsics"_sv,
    131 dwConstRigHandle_t,
    134 dwSALHandle_t,
    138 dwContextHandle_t)));
    139 }
    140
    142 const dwContextHandle_t ctx);
    143};
    144}
    145}
    146#endif // DW_FRAMEWORK_CAMERA_NODE_HPP_
    #define DW_DESCRIBE_INDEX_PARAMETER_WITH_SEMANTIC(TYPE_NAME, SEMANTIC_TYPE_NAME, args...)
    #define DW_DESCRIBE_INDEX_PARAMETER(TYPE_NAME, args...)
    #define DW_DESCRIBE_UNNAMED_PARAMETER(TYPE_NAME, args...)
    #define DW_DESCRIBE_PARAMETER(TYPE_NAME, args...)
    #define DW_DESCRIBE_PORT(TYPE_NAME, args...)
    The interface to access parameter values identified by name and/or (semantic) type.
    static constexpr auto describeInputPorts()
    dwCameraChannelNode(dwCameraChannelNodeParams const &params, const dwContextHandle_t ctx)
    static std::unique_ptr< dwCameraChannelNode > create(ParameterProvider &provider)
    static constexpr auto describeOutputPorts()
    static constexpr auto describeParameters()
    constexpr auto describeConstructorArgument(const Args &&... args) -> dw::core::Tuple< Args... >
    constexpr auto describePassCollection(const Args &&... args) -> std::tuple< Args... >
    constexpr auto describePortCollection(Args &&... args) -> dw::core::Tuple< Args... >
    constexpr PassDescriptorT< 0 > describePass(dw::core::StringView const &&name, dwProcessorType processorType)
    Definition: Buffer.hpp:40
    人人超碰97caoporen国产