Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
apply_operation_base.hpp File Reference

Given an object with run-time specified type (denoted as an array of Bits, dynamic index, and a static set of Types) and a generic operation, casts the object to its appropriate type and applies the operation. More...

Include dependency graph for apply_operation_base.hpp:
This graph shows which files directly or indirectly include this file:

Classes

struct  boost::gil::detail::apply_operation_fwd_fn< N >
 
struct  boost::gil::detail::reduce_bind1< T2, Op >
 
struct  boost::gil::detail::reduce_bind2< Types1, Bits1, Op >
 

Namespaces

 boost
 Duration formatting facet for input.
 
 boost::gil
 
 boost::gil::detail
 

Macros

#define GIL_FWD_TYPEDEFS(z, N, text)   T##N; typedef typename mpl::next<T##N>::type
 
#define GIL_FWD_CASE(z, N, SUM)   case N: return op(*gil_reinterpret_cast<typename mpl::deref<T##N>::type*>(&bits));
 
#define GIL_FWD_CONST_CASE(z, N, SUM)   case N: return op(*gil_reinterpret_cast_c<const typename mpl::deref<T##N>::type*>(&bits));
 
#define GIL_FWD_CASE_WITH_INFO(z, N, SUM)   case N: return op(*gil_reinterpret_cast<typename mpl::deref<T##N>::type*>(&bits), info);
 
#define GIL_FWD_CONST_CASE_WITH_INFO(z, N, SUM)   case N: return op(*gil_reinterpret_cast_c<const typename mpl::deref<T##N>::type*>(&bits), info);
 
#define GIL_APPLY_FWD_OP(z, N, text)
 
#define GIL_GENERATE_APPLY_FWD_OPS(N)   BOOST_PP_REPEAT(N, GIL_APPLY_FWD_OP, BOOST_PP_EMPTY)
 

Functions

template<typename Types , typename Bits , typename Op >
Op::result_type boost::gil::apply_operation_basec (const Bits &bits, std::size_t index, Op op)
 
template<typename Types , typename Bits , typename Op >
Op::result_type boost::gil::apply_operation_base (Bits &bits, std::size_t index, Op op)
 

Detailed Description

Given an object with run-time specified type (denoted as an array of Bits, dynamic index, and a static set of Types) and a generic operation, casts the object to its appropriate type and applies the operation.

Author
Lubomir Bourdev and Hailin Jin
Adobe Systems Incorporated
Date
2005-2007
Last updated on November 6, 2007

Macro Definition Documentation

#define GIL_APPLY_FWD_OP (   z,
  N,
  text 
)
#define GIL_FWD_CASE (   z,
  N,
  SUM 
)    case N: return op(*gil_reinterpret_cast<typename mpl::deref<T##N>::type*>(&bits));
#define GIL_FWD_CASE_WITH_INFO (   z,
  N,
  SUM 
)    case N: return op(*gil_reinterpret_cast<typename mpl::deref<T##N>::type*>(&bits), info);
#define GIL_FWD_CONST_CASE (   z,
  N,
  SUM 
)    case N: return op(*gil_reinterpret_cast_c<const typename mpl::deref<T##N>::type*>(&bits));
#define GIL_FWD_CONST_CASE_WITH_INFO (   z,
  N,
  SUM 
)    case N: return op(*gil_reinterpret_cast_c<const typename mpl::deref<T##N>::type*>(&bits), info);
#define GIL_FWD_TYPEDEFS (   z,
  N,
  text 
)    T##N; typedef typename mpl::next<T##N>::type
#define GIL_GENERATE_APPLY_FWD_OPS (   N)    BOOST_PP_REPEAT(N, GIL_APPLY_FWD_OP, BOOST_PP_EMPTY)