UltraGrid
UltraGrid Low-Latency High-Resolution Transmission System
Loading...
Searching...
No Matches
ref_count_init_once< T > Struct Template Reference

#include <ref_count.hpp>

Collaboration diagram for ref_count_init_once< T >:
Collaboration graph

Public Member Functions

std::optional< T > operator() (T(*init)(void), int &i)
 

Detailed Description

template<typename T>
struct ref_count_init_once< T >

Definition at line 43 of file ref_count.hpp.

Member Function Documentation

◆ operator()()

template<typename T >
std::optional< T > ref_count_init_once< T >::operator() ( T(* init )(void),
int & i )
inline

Definition at line 44 of file ref_count.hpp.

44 {
45 if (i++ == 0) {
46 return std::optional<T>(init());
47 }
48 return std::nullopt;
49 }
static af_result_code init(struct module *parent, const char *cfg, void **state)

References init().

Here is the call graph for this function:

The documentation for this struct was generated from the following file: