9 #ifndef CMZN_SCENEFILTER_HPP__
10 #define CMZN_SCENEFILTER_HPP__
12 #include "zinc/scenefilter.h"
13 #include "zinc/context.hpp"
14 #include "zinc/graphics.hpp"
15 #include "zinc/region.hpp"
22 class ScenefilterOperator;
36 cmzn_scenefilter_id id;
44 explicit Scenefilter(cmzn_scenefilter_id in_filter_id) :
49 id(cmzn_scenefilter_access(scenefilter.id))
54 cmzn_scenefilter_id temp_id = cmzn_scenefilter_access(scenefilter.id);
57 cmzn_scenefilter_destroy(&
id);
67 cmzn_scenefilter_destroy(&
id);
86 cmzn_scenefilter_id
getId()
const
99 return cmzn_scenefilter_is_managed(
id);
116 return cmzn_scenefilter_set_managed(
id, value);
128 return cmzn_scenefilter_evaluate_graphics(
id, graphics.
getId());
138 return cmzn_scenefilter_is_inverse(
id);
150 return cmzn_scenefilter_set_inverse(
id, value);
161 return cmzn_scenefilter_get_name(
id);
172 return cmzn_scenefilter_set_name(
id, name);
202 Scenefilter(reinterpret_cast<cmzn_scenefilter_id>(operator_filter_id))
212 return reinterpret_cast<cmzn_scenefilter_operator_id
>(id);
225 return cmzn_scenefilter_operator_append_operand(
getDerivedId(), operand.
getId());
257 return cmzn_scenefilter_operator_is_operand_active(
getDerivedId(), operand.
getId());
269 return cmzn_scenefilter_operator_set_operand_active(
getDerivedId(), operand.
getId(), isActive);
283 return cmzn_scenefilter_operator_insert_operand_before(
getDerivedId(), operand.
getId(), refOperand.
getId());
294 return cmzn_scenefilter_operator_remove_operand(
getDerivedId(), operand.
getId());
311 cmzn_scenefiltermodule_id id;
320 id(in_filtermodule_id)
324 id(cmzn_scenefiltermodule_access(scenefiltermodule.id))
329 cmzn_scenefiltermodule_id temp_id = cmzn_scenefiltermodule_access(
330 scenefiltermodule.id);
333 cmzn_scenefiltermodule_destroy(&
id);
343 cmzn_scenefiltermodule_destroy(&
id);
362 cmzn_scenefiltermodule_id
getId()
const
376 return Scenefilter(cmzn_scenefiltermodule_create_scenefilter_visibility_flags(
id));
388 return Scenefilter(cmzn_scenefiltermodule_create_scenefilter_field_domain_type(
id,
389 static_cast<cmzn_field_domain_type>(domainType)));
400 return Scenefilter(cmzn_scenefiltermodule_create_scenefilter_graphics_name(
id, matchName));
411 return Scenefilter(cmzn_scenefiltermodule_create_scenefilter_graphics_type(
id,
412 static_cast<cmzn_graphics_type>(graphicsType)));
424 return Scenefilter(cmzn_scenefiltermodule_create_scenefilter_region(
425 id, matchRegion.
getId()));
437 cmzn_scenefiltermodule_create_scenefilter_operator_and(
id)));
449 cmzn_scenefiltermodule_create_scenefilter_operator_or(
id)));
460 return Scenefilter(cmzn_scenefiltermodule_find_scenefilter_by_name(
id, name));
474 return cmzn_scenefiltermodule_begin_change(
id);
488 return cmzn_scenefiltermodule_end_change(
id);
498 return Scenefilter(cmzn_scenefiltermodule_get_default_scenefilter(
id));
509 return cmzn_scenefiltermodule_set_default_scenefilter(
id, filter.
getId());
Scenefilter createScenefilterRegion(const Region &matchRegion)
Definition: scenefilter.hpp:422
cmzn_scenefilter_id getId() const
Definition: scenefilter.hpp:86
Scenefilter getFirstOperand()
Definition: scenefilter.hpp:232
int setDefaultScenefilter(const Scenefilter &filter)
Definition: scenefilter.hpp:507
Scenefilter findScenefilterByName(const char *name)
Definition: scenefilter.hpp:458
int endChange()
Definition: scenefilter.hpp:486
Scenefilter createScenefilterFieldDomainType(Field::DomainType domainType)
Definition: scenefilter.hpp:386
bool isValid() const
Definition: scenefilter.hpp:352
int insertOperandBefore(const Scenefilter &operand, const Scenefilter &refOperand)
Definition: scenefilter.hpp:281
bool isValid() const
Definition: scenefilter.hpp:76
cmzn_scenefilter_operator_id getDerivedId()
Definition: scenefilter.hpp:210
A hierarchical block/namespace owning domains and fields.
Definition: region.hpp:33
Base graphics type: produces 3-D graphics visualising domains and fields.
Definition: graphics.hpp:45
cmzn_region_id getId() const
Definition: region.hpp:84
Module managing all scene filters.
Definition: scenefilter.hpp:308
An operator OR or AND specific scene filter type.
Definition: scenefilter.hpp:193
int removeOperand(const Scenefilter &operand)
Definition: scenefilter.hpp:292
Scenefilter createScenefilterGraphicsName(const char *matchName)
Definition: scenefilter.hpp:398
Scenefilter getDefaultScenefilter()
Definition: scenefilter.hpp:496
int setName(const char *name)
Definition: scenefilter.hpp:170
bool isManaged()
Definition: scenefilter.hpp:97
DomainType
Definition: field.hpp:190
ScenefilterOperator createScenefilterOperatorAnd()
Definition: scenefilter.hpp:434
Scenefilter getNextOperand(const Scenefilter &refOperand)
Definition: scenefilter.hpp:244
Scenefilter createScenefilterVisibilityFlags()
Definition: scenefilter.hpp:374
ScenefilterOperator castOperator()
Definition: scenefilter.hpp:298
int setOperandActive(const Scenefilter &operand, bool isActive)
Definition: scenefilter.hpp:267
Scenefiltermodule getScenefiltermodule()
Definition: scenefilter.hpp:513
int appendOperand(const Scenefilter &operand)
Definition: scenefilter.hpp:223
int setManaged(bool value)
Definition: scenefilter.hpp:114
bool isInverse()
Definition: scenefilter.hpp:136
int setInverse(bool value)
Definition: scenefilter.hpp:148
Type
Definition: graphics.hpp:131
Scene filters determines which graphics are drawn.
Definition: scenefilter.hpp:33
cmzn_scenefiltermodule_id getId() const
Definition: scenefilter.hpp:362
Scenefilter createScenefilterGraphicsType(Graphics::Type graphicsType)
Definition: scenefilter.hpp:409
bool evaluateGraphics(const Graphics &graphics)
Definition: scenefilter.hpp:126
char * getName()
Definition: scenefilter.hpp:159
bool isOperandActive(const Scenefilter &operand)
Definition: scenefilter.hpp:255
cmzn_graphics_id getId() const
Definition: graphics.hpp:153
int beginChange()
Definition: scenefilter.hpp:472
ScenefilterOperator createScenefilterOperatorOr()
Definition: scenefilter.hpp:446