Alembic export: converted some export params to actual bools
[blender.git] / source / blender / alembic / ABC_alembic.h
index e62713f57f5faddcd31fe1d28334b18168fd846d..df19a836ca38cf4961fc65347eeb974e07fe2c3a 100644 (file)
@@ -28,6 +28,7 @@ extern "C" {
 #endif
 
 struct bContext;
+struct CacheReader;
 struct DerivedMesh;
 struct ListBase;
 struct Object;
@@ -52,24 +53,26 @@ struct AlembicExportParams {
        double shutter_open;
        double shutter_close;
 
-       /* bools */
-       unsigned int selected_only : 1;
-       unsigned int uvs : 1;
-       unsigned int normals : 1;
-       unsigned int vcolors : 1;
-       unsigned int apply_subdiv : 1;
-       unsigned int flatten_hierarchy : 1;
-       unsigned int visible_layers_only : 1;
-       unsigned int renderable_only : 1;
-       unsigned int face_sets : 1;
-       unsigned int use_subdiv_schema : 1;
-       unsigned int packuv : 1;
-       unsigned int triangulate : 1;
+       bool selected_only;
+       bool uvs;
+       bool normals;
+       bool vcolors;
+       bool apply_subdiv;
+       bool flatten_hierarchy;
+       bool visible_layers_only;
+       bool renderable_only;
+       bool face_sets;
+       bool use_subdiv_schema;
+       bool packuv;
+       bool triangulate;
 
        unsigned int compression_type : 1;
 
+       /* See MOD_TRIANGULATE_NGON_xxx and MOD_TRIANGULATE_QUAD_xxx
+        * in DNA_modifier_types.h */
        int quad_method;
        int ngon_method;
+
        float global_scale;
 };
 
@@ -92,21 +95,25 @@ AbcArchiveHandle *ABC_create_handle(const char *filename, struct ListBase *objec
 
 void ABC_free_handle(AbcArchiveHandle *handle);
 
-void ABC_get_transform(AbcArchiveHandle *handle,
-                       struct Object *ob,
-                       const char *object_path,
+void ABC_get_transform(struct CacheReader *reader,
                        float r_mat[4][4],
                        float time,
                        float scale);
 
-struct DerivedMesh *ABC_read_mesh(AbcArchiveHandle *handle,
+struct DerivedMesh *ABC_read_mesh(struct CacheReader *reader,
                                   struct Object *ob,
                                   struct DerivedMesh *dm,
-                                  const char *object_path,
                                   const float time,
                                   const char **err_str,
                                   int flags);
 
+void CacheReader_free(struct CacheReader *reader);
+
+struct CacheReader *CacheReader_open_alembic_object(struct AbcArchiveHandle *handle,
+                                                    struct CacheReader *reader,
+                                                    struct Object *object,
+                                                    const char *object_path);
+
 #ifdef __cplusplus
 }
 #endif