2 * ***** BEGIN GPL LICENSE BLOCK *****
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software Foundation,
16 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 * The Original Code is Copyright (C) 2013 Blender Foundation.
19 * All rights reserved.
21 * Original Author: Joshua Leung
22 * Contributor(s): Sergey Sharybin
24 * ***** END GPL LICENSE BLOCK *****
27 /** \file blender/depsgraph/DEG_depsgraph_query.h
30 * Public API for Querying and Filtering Depsgraph.
33 #ifndef __DEG_DEPSGRAPH_QUERY_H__
34 #define __DEG_DEPSGRAPH_QUERY_H__
44 /* Check if given ID type was tagged for update. */
45 bool DEG_id_type_tagged(struct Main *bmain, short idtype);
47 /* Get additional evaluation flags for the given ID. */
48 short DEG_get_eval_flags_for_id(struct Depsgraph *graph, struct ID *id);
50 /* ************************ DEG traversal ********************* */
52 typedef void (*DEGForeachIDCallback)(ID *id, void *user_data);
54 /* NOTE: Modifies runtime flags in depsgraph nodes, so can not be used in
55 * parallel. Keep an eye on that!
57 void DEG_foreach_dependent_ID(const Depsgraph *depsgraph,
59 DEGForeachIDCallback callback, void *user_data);
66 #endif /* __DEG_DEPSGRAPH_QUERY_H__ */