scriptup 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/LICENSE.txt +11 -0
- data/README.md +5 -0
- data/ext/attribute_dictionaries.c +45 -0
- data/ext/attribute_dictionaries.h +3 -0
- data/ext/attribute_dictionary.c +156 -0
- data/ext/attribute_dictionary.h +3 -0
- data/ext/behavior.c +10 -0
- data/ext/behavior.h +3 -0
- data/ext/color.c +211 -0
- data/ext/color.h +3 -0
- data/ext/component_definition.c +188 -0
- data/ext/component_definition.h +3 -0
- data/ext/component_instance.c +10 -0
- data/ext/component_instance.h +3 -0
- data/ext/definition_list.c +145 -0
- data/ext/definition_list.h +3 -0
- data/ext/drawing_element.c +10 -0
- data/ext/drawing_element.h +3 -0
- data/ext/entities.c +11 -0
- data/ext/entities.h +3 -0
- data/ext/entity.c +253 -0
- data/ext/entity.h +3 -0
- data/ext/extconf.rb +38 -0
- data/ext/material.c +242 -0
- data/ext/material.h +3 -0
- data/ext/materials.c +80 -0
- data/ext/materials.h +3 -0
- data/ext/model.c +42 -0
- data/ext/model.h +3 -0
- data/ext/sketchup.c +89 -0
- data/ext/sketchup.h +4 -0
- data/ext/texture.c +9 -0
- data/ext/texture.h +3 -0
- data/ext/typed_value.c +84 -0
- data/ext/typed_value.h +5 -0
- data/ext/utils.h +80 -0
- data/lib/sketchup.rb +12 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/application.h +36 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/model.h +59 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/overlay.h +248 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/ruby_api.h +118 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/color.h +107 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/common.h +178 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/defs.h +19 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/extension_license.h +62 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/bounding_box.h +34 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/plane3d.h +153 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/point2d.h +96 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/point3d.h +98 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/ray3d.h +64 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/transformation.h +321 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/transformation2d.h +163 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/vector2d.h +235 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/vector3d.h +285 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry.h +152 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/import_export/modelexporterplugin.h +165 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/import_export/modelimporterplugin.h +183 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/import_export/pluginprogresscallback.h +84 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/initialize.h +43 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/length_formatter.h +424 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/arccurve.h +244 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/arrow_type.h +17 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/attribute_dictionary.h +161 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/axes.h +242 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/camera.h +398 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/classification_attribute.h +89 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/classification_info.h +125 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/classifications.h +86 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/component_definition.h +588 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/component_instance.h +344 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/curve.h +143 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/defs.h +142 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension.h +222 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension_linear.h +421 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension_radial.h +194 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension_style.h +253 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/drawing_element.h +198 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dynamic_component_attribute.h +92 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dynamic_component_info.h +70 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/edge.h +271 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/edge_use.h +214 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entities.h +834 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entity.h +186 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entity_list.h +80 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entity_list_iterator.h +90 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/face.h +686 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/font.h +138 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/geometry.h +20 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/geometry_input.h +685 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/group.h +244 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/guide_line.h +155 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/guide_point.h +153 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/image.h +288 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/image_rep.h +275 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/instancepath.h +266 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/layer.h +265 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/layer_folder.h +301 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/line_style.h +211 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/line_styles.h +81 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/location.h +65 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/loop.h +182 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/material.h +390 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/mesh_helper.h +187 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/model.h +1663 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/model_version.h +49 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/opening.h +72 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/options_manager.h +79 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/options_provider.h +166 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/polyline3d.h +140 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/rendering_options.h +179 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/scene.h +836 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/schema.h +56 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/schema_type.h +26 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/section_plane.h +212 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/selection.h +156 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/shadow_info.h +147 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/skp.h +45 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/style.h +303 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/styles.h +190 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/text.h +384 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/texture.h +358 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/texture_writer.h +280 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/typed_value.h +390 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/uv_helper.h +79 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/vertex.h +154 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/sketchup.h +122 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/sketchup_info.h +65 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/slapi.h +16 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/transformation.h +16 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/unicodestring.h +239 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/utils/math_helpers.h +124 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonGeometry.dylib +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonGeoutils.dylib +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonImage.dylib +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonPreferences.dylib +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonUnits.dylib +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonUtils.dylib +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonZip.dylib +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Resources/Info.plist +50 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/SketchUpAPI +0 -0
- data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/_CodeSignature/CodeResources +835 -0
- data/sketchup-sdk-win/binaries/sketchup/x64/SketchUpAPI.dll +0 -0
- data/sketchup-sdk-win/binaries/sketchup/x64/SketchUpAPI.lib +0 -0
- data/sketchup-sdk-win/binaries/sketchup/x64/SketchUpCommonPreferences.dll +0 -0
- data/sketchup-sdk-win/binaries/sketchup/x64/sketchup.lib +0 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/application/application.h +36 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/application/model.h +59 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/application/overlay.h +248 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/application/ruby_api.h +118 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/color.h +107 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/common.h +178 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/defs.h +19 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/extension_license.h +62 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/bounding_box.h +34 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/plane3d.h +153 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/point2d.h +96 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/point3d.h +98 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/ray3d.h +64 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/transformation.h +321 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/transformation2d.h +163 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/vector2d.h +235 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry/vector3d.h +285 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/geometry.h +152 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/import_export/modelexporterplugin.h +165 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/import_export/modelimporterplugin.h +183 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/import_export/pluginprogresscallback.h +84 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/initialize.h +43 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/length_formatter.h +424 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/arccurve.h +244 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/arrow_type.h +17 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/attribute_dictionary.h +161 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/axes.h +242 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/camera.h +398 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/classification_attribute.h +89 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/classification_info.h +125 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/classifications.h +86 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/component_definition.h +588 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/component_instance.h +344 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/curve.h +143 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/defs.h +142 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension.h +222 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension_linear.h +421 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension_radial.h +194 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension_style.h +253 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/drawing_element.h +198 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/dynamic_component_attribute.h +92 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/dynamic_component_info.h +70 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/edge.h +271 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/edge_use.h +214 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/entities.h +834 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/entity.h +186 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/entity_list.h +80 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/entity_list_iterator.h +90 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/face.h +686 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/font.h +138 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/geometry.h +20 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/geometry_input.h +685 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/group.h +244 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/guide_line.h +155 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/guide_point.h +153 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/image.h +288 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/image_rep.h +275 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/instancepath.h +266 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/layer.h +265 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/layer_folder.h +301 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/line_style.h +211 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/line_styles.h +81 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/location.h +65 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/loop.h +182 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/material.h +390 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/mesh_helper.h +187 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/model.h +1663 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/model_version.h +49 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/opening.h +72 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/options_manager.h +79 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/options_provider.h +166 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/polyline3d.h +140 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/rendering_options.h +179 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/scene.h +836 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/schema.h +56 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/schema_type.h +26 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/section_plane.h +212 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/selection.h +156 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/shadow_info.h +147 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/skp.h +45 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/style.h +303 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/styles.h +190 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/text.h +384 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/texture.h +358 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/texture_writer.h +280 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/typed_value.h +390 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/uv_helper.h +79 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/model/vertex.h +154 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/sketchup.h +122 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/sketchup_info.h +65 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/slapi.h +16 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/transformation.h +16 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/unicodestring.h +239 -0
- data/sketchup-sdk-win/headers/SketchUpAPI/utils/math_helpers.h +124 -0
- metadata +313 -0
@@ -0,0 +1,685 @@
|
|
1
|
+
// Copyright 2013 Trimble Inc. All Rights Reserved.
|
2
|
+
|
3
|
+
/**
|
4
|
+
* @file
|
5
|
+
* @brief Interfaces for SUGeometryInputRef.
|
6
|
+
*/
|
7
|
+
#ifndef SKETCHUP_MODEL_GEOMETRY_INPUT_H_
|
8
|
+
#define SKETCHUP_MODEL_GEOMETRY_INPUT_H_
|
9
|
+
|
10
|
+
#include <SketchUpAPI/geometry.h>
|
11
|
+
#include <SketchUpAPI/common.h>
|
12
|
+
#include <SketchUpAPI/model/defs.h>
|
13
|
+
#include <SketchUpAPI/model/curve.h>
|
14
|
+
|
15
|
+
#pragma pack(push, 8)
|
16
|
+
#ifdef __cplusplus
|
17
|
+
extern "C" {
|
18
|
+
#endif
|
19
|
+
|
20
|
+
/**
|
21
|
+
@struct SUGeometryInputRef
|
22
|
+
@brief References a geometry input object. It is used as an input to
|
23
|
+
SUEntitiesFill().
|
24
|
+
*/
|
25
|
+
|
26
|
+
/**
|
27
|
+
@brief SUMaterialInput contains information that is needed to apply a
|
28
|
+
material to a face.
|
29
|
+
|
30
|
+
@deprecated This struct is made obsolete by the newer SUMaterialPositionInput
|
31
|
+
and left in place only for compatibility.
|
32
|
+
|
33
|
+
@note Prior to SketchUp 2021.1, API 9.1 it was not possible to apply a
|
34
|
+
textured material without providing explicit UV coordinates.
|
35
|
+
|
36
|
+
@see SUMaterialPositionInput
|
37
|
+
|
38
|
+
The conventional method for applying a material to a face is to use 1 to 4 UV
|
39
|
+
coordinates, which are Cartesian textures coordinates and corresponding vertex
|
40
|
+
indices on the face. The vertices are referenced by index into the top level
|
41
|
+
SUGeometryInputRef's vertex array. Once the \p material input is used
|
42
|
+
(e.g. with SUEntitiesFill()), the material object must not be released since it
|
43
|
+
will be associated with a parent object.
|
44
|
+
*/
|
45
|
+
struct SUMaterialInput {
|
46
|
+
size_t num_uv_coords; ///< Number of texture coordinates. 0 if the material
|
47
|
+
///< should be applied using default UV coordinates.
|
48
|
+
///< 1 to 4 otherwise.
|
49
|
+
|
50
|
+
struct SUPoint2D uv_coords[4]; ///< Texture coordinates.
|
51
|
+
|
52
|
+
size_t vertex_indices[4]; ///< Vertex indices corresponding to the texture
|
53
|
+
///< coordinates. Should reference the vertex array
|
54
|
+
///< of the parent SUGeometryInputRef.
|
55
|
+
|
56
|
+
SUMaterialRef material; ///< Material to be applied.
|
57
|
+
};
|
58
|
+
|
59
|
+
/**
|
60
|
+
@brief SUMaterialInput contains information that is needed to apply a
|
61
|
+
material to a face.
|
62
|
+
|
63
|
+
The conventional method for applying a material to a face is to use 1 to 4 UV
|
64
|
+
coordinates, which are Cartesian textures coordinates and corresponding 3D
|
65
|
+
points on the face's plane. If the 3D points are not on the face's plane they
|
66
|
+
will be projected onto it. Once the material input is used
|
67
|
+
(e.g. with SUEntitiesFill()), the \p material object must not be released since
|
68
|
+
it will be associated with a parent object.
|
69
|
+
|
70
|
+
@since SketchUp 2021.1, API 9.1
|
71
|
+
*/
|
72
|
+
struct SUMaterialPositionInput {
|
73
|
+
size_t num_uv_coords; ///< Number of texture coordinates. 0 if the material
|
74
|
+
///< should be applied using default UV coordinates.
|
75
|
+
///< 1 to 4 otherwise.
|
76
|
+
|
77
|
+
struct SUPoint2D uv_coords[4]; ///< Texture coordinates.
|
78
|
+
|
79
|
+
struct SUPoint3D points[4]; ///< 3D point corresponding to the
|
80
|
+
///< texture coordinates. The points
|
81
|
+
///< should all lie on the plane of the
|
82
|
+
///< face the material is applied to.
|
83
|
+
|
84
|
+
SUMaterialRef material; ///< Material to be applied.
|
85
|
+
struct SUVector3D projection; ///< Optional projection direction.
|
86
|
+
///< Leave as invalid (0, 0, 0) for no projection.
|
87
|
+
};
|
88
|
+
|
89
|
+
/**
|
90
|
+
@brief Creates a geometry input object.
|
91
|
+
@param[out] geom_input The object created. This object can be passed into
|
92
|
+
SUEntitiesFill() to populate an entities object.
|
93
|
+
It should be released subsequently by calling
|
94
|
+
SUGeometryInputRelease().
|
95
|
+
@related SUGeometryInputRef
|
96
|
+
@return
|
97
|
+
- \ref SU_ERROR_NONE on success
|
98
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if geom_input is NULL
|
99
|
+
- \ref SU_ERROR_OVERWRITE_VALID if geom_input already references a valid object
|
100
|
+
*/
|
101
|
+
SU_RESULT SUGeometryInputCreate(SUGeometryInputRef* geom_input);
|
102
|
+
|
103
|
+
/**
|
104
|
+
@brief Deallocates a geometry input object.
|
105
|
+
@param[in] geom_input The object to deallocate.
|
106
|
+
@related SUGeometryInputRef
|
107
|
+
@return
|
108
|
+
- \ref SU_ERROR_NONE on success
|
109
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if geom_input is NULL
|
110
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input points to an invalid object
|
111
|
+
*/
|
112
|
+
SU_RESULT SUGeometryInputRelease(SUGeometryInputRef* geom_input);
|
113
|
+
|
114
|
+
/**
|
115
|
+
@brief Adds a vertex to a geometry input object.
|
116
|
+
@param[in] geom_input The geometry input object.
|
117
|
+
@param[in] point The location of the vertex to be added.
|
118
|
+
@related SUGeometryInputRef
|
119
|
+
@return
|
120
|
+
- \ref SU_ERROR_NONE on success
|
121
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
122
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if point is NULL
|
123
|
+
*/
|
124
|
+
SU_RESULT SUGeometryInputAddVertex(SUGeometryInputRef geom_input, const struct SUPoint3D* point);
|
125
|
+
|
126
|
+
/**
|
127
|
+
@brief Sets all vertices of a geometry input object. Any existing vertices will
|
128
|
+
be overridden.
|
129
|
+
@param[in] geom_input The geometry input object.
|
130
|
+
@param[in] num_vertices The number of vertices in the given point array.
|
131
|
+
@param[in] points The points array containing the location of vertices.
|
132
|
+
@related SUGeometryInputRef
|
133
|
+
@return
|
134
|
+
- \ref SU_ERROR_NONE on success
|
135
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
136
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if points is NULL
|
137
|
+
*/
|
138
|
+
SU_RESULT SUGeometryInputSetVertices(
|
139
|
+
SUGeometryInputRef geom_input, size_t num_vertices, const struct SUPoint3D points[]);
|
140
|
+
|
141
|
+
/**
|
142
|
+
@brief Adds an edge to a geometry input object. This method is intended for
|
143
|
+
specifying edges which are not associated with loop inputs. For
|
144
|
+
specifying edge properties on a face use the SULoopInput interface.
|
145
|
+
@since SketchUp 2017, API 5.0
|
146
|
+
@param[in] geom_input The geometry input object.
|
147
|
+
@param[in] vertex0_index The vertex index of the edge's first vertex.
|
148
|
+
@param[in] vertex1_index The vertex index of the edge's last vertex.
|
149
|
+
@param[out] added_edge_index (optional) If not NULL, returns the index of the
|
150
|
+
added edge.
|
151
|
+
@related SUGeometryInputRef
|
152
|
+
@return
|
153
|
+
- \ref SU_ERROR_NONE on success
|
154
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
155
|
+
- \ref SU_ERROR_OUT_OF_RANGE if vertex0_index or vertex1_index are greater than
|
156
|
+
the total vertex count
|
157
|
+
- \ref SU_ERROR_INVALID_ARGUMENT if vertex0_index and vertex1_index are equal
|
158
|
+
*/
|
159
|
+
SU_RESULT SUGeometryInputAddEdge(
|
160
|
+
SUGeometryInputRef geom_input, size_t vertex0_index, size_t vertex1_index,
|
161
|
+
size_t* added_edge_index);
|
162
|
+
|
163
|
+
/**
|
164
|
+
@brief Sets the hidden flag of an edge in a geometry input object which is not
|
165
|
+
associated with a loop input.
|
166
|
+
@since SketchUp 2017, API 5.0
|
167
|
+
@param[in] geom_input The geometry input object.
|
168
|
+
@param[in] edge_index The zero-based index of the edge which is not associated
|
169
|
+
with a loop input.
|
170
|
+
@param[in] hidden The flag to set.
|
171
|
+
@related SUGeometryInputRef
|
172
|
+
@return
|
173
|
+
- \ref SU_ERROR_NONE on success
|
174
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
175
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references beyond the current total
|
176
|
+
number of edges which are not associated with loop inputs
|
177
|
+
*/
|
178
|
+
SU_RESULT SUGeometryInputEdgeSetHidden(
|
179
|
+
SUGeometryInputRef geom_input, size_t edge_index, bool hidden);
|
180
|
+
|
181
|
+
/**
|
182
|
+
@brief Sets the soft flag of an edge in a geometry input object which is not
|
183
|
+
associated with a loop input.
|
184
|
+
@since SketchUp 2017, API 5.0
|
185
|
+
@param[in] geom_input The geometry input object.
|
186
|
+
@param[in] edge_index The zero-based index of the edge which is not associated
|
187
|
+
with a loop input.
|
188
|
+
@param[in] soft The flag to set.
|
189
|
+
@related SUGeometryInputRef
|
190
|
+
@return
|
191
|
+
- \ref SU_ERROR_NONE on success
|
192
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
193
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references beyond the current total
|
194
|
+
number of edges which are not associated with loop inputs
|
195
|
+
*/
|
196
|
+
SU_RESULT SUGeometryInputEdgeSetSoft(SUGeometryInputRef geom_input, size_t edge_index, bool soft);
|
197
|
+
|
198
|
+
/**
|
199
|
+
@brief Sets the smooth flag of an edge in a geometry input object which is not
|
200
|
+
associated with a loop input.
|
201
|
+
@since SketchUp 2017, API 5.0
|
202
|
+
@param[in] geom_input The geometry input object.
|
203
|
+
@param[in] edge_index The zero-based index of the edge which is not associated
|
204
|
+
with a loop input.
|
205
|
+
@param[in] smooth The flag to set.
|
206
|
+
@related SUGeometryInputRef
|
207
|
+
@return
|
208
|
+
- \ref SU_ERROR_NONE on success
|
209
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
210
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references beyond the current total
|
211
|
+
number of edges which are not associated with loop inputs
|
212
|
+
*/
|
213
|
+
SU_RESULT SUGeometryInputEdgeSetSmooth(
|
214
|
+
SUGeometryInputRef geom_input, size_t edge_index, bool smooth);
|
215
|
+
|
216
|
+
/**
|
217
|
+
@brief Sets the material of an edge in the geometry input.
|
218
|
+
@since SketchUp 2017, API 5.0
|
219
|
+
@param[in] geom_input The geometry input object.
|
220
|
+
@param[in] edge_index Index of the edge to set the material.
|
221
|
+
@param[in] material The material to be set.
|
222
|
+
@related SUGeometryInputRef
|
223
|
+
@return
|
224
|
+
- \ref SU_ERROR_NONE on success
|
225
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input or material is not valid
|
226
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references an edge beyond the total
|
227
|
+
- \ref SU_ERROR_INVALID_ARGUMENT is the material is owned by a layer or image
|
228
|
+
edge count of geom_input
|
229
|
+
*/
|
230
|
+
SU_RESULT SUGeometryInputEdgeSetMaterial(
|
231
|
+
SUGeometryInputRef geom_input, size_t edge_index, SUMaterialRef material);
|
232
|
+
|
233
|
+
/**
|
234
|
+
@brief Sets the layer of an edge in the geometry input.
|
235
|
+
@since SketchUp 2017, API 5.0
|
236
|
+
@param[in] geom_input The geometry input object.
|
237
|
+
@param[in] edge_index Index of the edge to set the layer.
|
238
|
+
@param[in] layer The layer to be set.
|
239
|
+
@related SUGeometryInputRef
|
240
|
+
@return
|
241
|
+
- \ref SU_ERROR_NONE on success
|
242
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input or layer is not valid
|
243
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references an edge beyond the total
|
244
|
+
edge count of geom_input
|
245
|
+
*/
|
246
|
+
SU_RESULT SUGeometryInputEdgeSetLayer(
|
247
|
+
SUGeometryInputRef geom_input, size_t edge_index, SULayerRef layer);
|
248
|
+
|
249
|
+
/**
|
250
|
+
@brief Adds a curve to a geometry input object. This method is intended for
|
251
|
+
specifying curves which are not associated with loop inputs. For
|
252
|
+
specifying curves on faces use the SULoopInput interface.
|
253
|
+
@since SketchUp 2017, API 5.0
|
254
|
+
@param[in] geom_input The geometry input object.
|
255
|
+
@param[in] num_edges The number of edges to be used in the curve.
|
256
|
+
@param[in] edge_indices The edge indices to be used in defining the curve.
|
257
|
+
@param[out] added_curve_index (optional) If not NULL, returns the index of the
|
258
|
+
added curve.
|
259
|
+
@related SUGeometryInputRef
|
260
|
+
@return
|
261
|
+
- \ref SU_ERROR_NONE on success
|
262
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
263
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if edge_indices is NULL
|
264
|
+
- \ref SU_ERROR_OUT_OF_RANGE if any of the indices in edge_indices are greater
|
265
|
+
than the total number of edges which are not associated with loop inputs
|
266
|
+
*/
|
267
|
+
SU_RESULT SUGeometryInputAddCurve(
|
268
|
+
SUGeometryInputRef geom_input, size_t num_edges, const size_t edge_indices[],
|
269
|
+
size_t* added_curve_index);
|
270
|
+
|
271
|
+
/**
|
272
|
+
@brief Adds an arccurve to a geometry input object. In addition to adding an
|
273
|
+
arccurve to the geometry input this method will append num_segments edges
|
274
|
+
to the geometry's edge collection where control_edge_index is the index
|
275
|
+
of the first new edge. Also, num_segments-1 vertices along the arc will
|
276
|
+
be appended to the geometry's collection of verttices. In order to
|
277
|
+
include an arccurve in a loop the user only needs add the arccurve's
|
278
|
+
points to a loop using \ref SULoopInputAddVertexIndex().
|
279
|
+
@since SketchUp 2017 M2, API 5.2
|
280
|
+
@param[in] geom_input The geometry input object.
|
281
|
+
@param[in] start_point The index of the vertex at the start of the arc.
|
282
|
+
@param[in] end_point The index of the vertex at the end of the arc.
|
283
|
+
@param[in] center The center point of the arc's circle.
|
284
|
+
@param[in] normal The normal vector of the arc plane.
|
285
|
+
@param[in] num_segments The number of edges for the arc.
|
286
|
+
@param[out] added_curve_index (optional) If not NULL, returns the index of the
|
287
|
+
added curve.
|
288
|
+
@param[out] control_edge_index (optional) If not NULL, returns the index of the
|
289
|
+
the arc's control edge which can be used to set
|
290
|
+
the arc's edge properties.
|
291
|
+
@related SUGeometryInputRef
|
292
|
+
@return
|
293
|
+
- \ref SU_ERROR_NONE on success
|
294
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
295
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if center or normal is NULL
|
296
|
+
- \ref SU_ERROR_OUT_OF_RANGE if either start_point or end_point are greater than
|
297
|
+
the total number of points in geom_input
|
298
|
+
- \ref SU_ERROR_INVALID_ARGUMENT if the data specifies an invalid arccurve
|
299
|
+
*/
|
300
|
+
SU_RESULT SUGeometryInputAddArcCurve(
|
301
|
+
SUGeometryInputRef geom_input, size_t start_point, size_t end_point,
|
302
|
+
const struct SUPoint3D* center, const struct SUVector3D* normal, size_t num_segments,
|
303
|
+
size_t* added_curve_index, size_t* control_edge_index);
|
304
|
+
|
305
|
+
/**
|
306
|
+
@brief Creates a loop input object.
|
307
|
+
@param[out] loop_input The object created.
|
308
|
+
@related SUGeometryInputRef
|
309
|
+
@return
|
310
|
+
- \ref SU_ERROR_NONE on success
|
311
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if loop_input is NULL
|
312
|
+
- \ref SU_ERROR_OVERWRITE_VALID if loop_input already references a valid object
|
313
|
+
*/
|
314
|
+
SU_RESULT SULoopInputCreate(SULoopInputRef* loop_input);
|
315
|
+
|
316
|
+
/**
|
317
|
+
@brief Deallocates a loop input object.
|
318
|
+
@param[in] loop_input The object to deallocate.
|
319
|
+
@related SUGeometryInputRef
|
320
|
+
@return
|
321
|
+
- \ref SU_ERROR_NONE on success
|
322
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if loop_input is NULL
|
323
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input points to an invalid object
|
324
|
+
*/
|
325
|
+
SU_RESULT SULoopInputRelease(SULoopInputRef* loop_input);
|
326
|
+
|
327
|
+
/**
|
328
|
+
@brief Adds a vertex index to a loop input object.
|
329
|
+
|
330
|
+
@warning Breaking Change: The behavior of this method was changed in
|
331
|
+
SketchUp 2017 M2, API 5.2. In previous releases this method returned
|
332
|
+
\ref SU_ERROR_INVALID_INPUT if the specified index was already anywhere
|
333
|
+
in the loop. In SketchUp 2017 M1 the concept of an explicitly closed
|
334
|
+
loop was introduced. A loop can be explicitly closed by either using
|
335
|
+
this method to insert an index which is already at the beginning of the
|
336
|
+
loop, or by adding a curve to the loop which connects the loop's start
|
337
|
+
and end points using \ref SULoopInputAddCurve(). If a loop was not
|
338
|
+
previously closed and \ref SULoopInputAddVertexIndex() is used to add
|
339
|
+
the loop's start vertex, the loop will be closed and \ref SU_ERROR_NONE
|
340
|
+
will be returned. If attempts are made to add vertices after a loop has
|
341
|
+
been explicitly closed \ref SU_ERROR_UNSUPPORTED will be returned. If
|
342
|
+
an attempt is made to add a vertex that already existed in an open loop
|
343
|
+
not at the front \ref SU_ERROR_INVALID_ARGUMENT will be returned.
|
344
|
+
|
345
|
+
@param[in] loop_input The loop input object.
|
346
|
+
@param[in] vertex_index The vertex index to add. This references a vertex within
|
347
|
+
the parent geometry input's vertex collection (as a
|
348
|
+
zero- based index).
|
349
|
+
@related SUGeometryInputRef
|
350
|
+
@return
|
351
|
+
- \ref SU_ERROR_NONE on success
|
352
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input is not valid
|
353
|
+
- \ref SU_ERROR_UNSUPPORTED if the loop was already closed
|
354
|
+
- \ref SU_ERROR_INVALID_ARGUMENT if vertex_index already existed in the loop not
|
355
|
+
at the front
|
356
|
+
*/
|
357
|
+
SU_RESULT SULoopInputAddVertexIndex(SULoopInputRef loop_input, size_t vertex_index);
|
358
|
+
|
359
|
+
/**
|
360
|
+
@brief Sets the hidden flag of an edge in a loop input object.
|
361
|
+
@param[in] loop_input The loop input object.
|
362
|
+
@param[in] edge_index The zero-based index of the edge within the loop.
|
363
|
+
@param[in] hidden The flag to set.
|
364
|
+
@related SUGeometryInputRef
|
365
|
+
@return
|
366
|
+
- \ref SU_ERROR_NONE on success
|
367
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input is not valid
|
368
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references beyond the current edge
|
369
|
+
count
|
370
|
+
*/
|
371
|
+
SU_RESULT SULoopInputEdgeSetHidden(SULoopInputRef loop_input, size_t edge_index, bool hidden);
|
372
|
+
|
373
|
+
/**
|
374
|
+
@brief Sets the soft flag of an edge in a loop input object.
|
375
|
+
@param[in] loop_input The loop input object.
|
376
|
+
@param[in] edge_index The zero-based index of the edge within the loop.
|
377
|
+
@param[in] soft The flag to set.
|
378
|
+
@related SUGeometryInputRef
|
379
|
+
@return
|
380
|
+
- \ref SU_ERROR_NONE on success
|
381
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input is not valid
|
382
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references beyond the current edge
|
383
|
+
count
|
384
|
+
*/
|
385
|
+
SU_RESULT SULoopInputEdgeSetSoft(SULoopInputRef loop_input, size_t edge_index, bool soft);
|
386
|
+
|
387
|
+
/**
|
388
|
+
@brief Sets the smooth flag of an edge in a loop input object.
|
389
|
+
@param[in] loop_input The loop input object.
|
390
|
+
@param[in] edge_index The zero-based index of the edge within the loop.
|
391
|
+
@param[in] smooth The flag to set.
|
392
|
+
@related SUGeometryInputRef
|
393
|
+
@return
|
394
|
+
- \ref SU_ERROR_NONE on success
|
395
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input is not valid
|
396
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references beyond the current edge
|
397
|
+
count
|
398
|
+
*/
|
399
|
+
SU_RESULT SULoopInputEdgeSetSmooth(SULoopInputRef loop_input, size_t edge_index, bool smooth);
|
400
|
+
|
401
|
+
/**
|
402
|
+
@brief Sets the material of an edge in the loop input.
|
403
|
+
@since SketchUp 2017, API 5.0
|
404
|
+
@param[in] loop_input The loop input object.
|
405
|
+
@param[in] edge_index Index of the edge to set the material.
|
406
|
+
@param[in] material The material to be set.
|
407
|
+
@related SUGeometryInputRef
|
408
|
+
@return
|
409
|
+
- \ref SU_ERROR_NONE on success
|
410
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input or material is not valid
|
411
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references an edge beyond the total
|
412
|
+
- \ref SU_ERROR_INVALID_ARGUMENT is the material is owned by a layer or image
|
413
|
+
edge count of loop_input
|
414
|
+
*/
|
415
|
+
SU_RESULT SULoopInputEdgeSetMaterial(
|
416
|
+
SULoopInputRef loop_input, size_t edge_index, SUMaterialRef material);
|
417
|
+
|
418
|
+
/**
|
419
|
+
@brief Sets the layer of an edge in the loop input.
|
420
|
+
@since SketchUp 2017, API 5.0
|
421
|
+
@param[in] loop_input The loop input object.
|
422
|
+
@param[in] edge_index Index of the edge to set the layer.
|
423
|
+
@param[in] layer The layer to be set.
|
424
|
+
@related SUGeometryInputRef
|
425
|
+
@return
|
426
|
+
- \ref SU_ERROR_NONE on success
|
427
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input or layer is not valid
|
428
|
+
- \ref SU_ERROR_OUT_OF_RANGE if edge_index references an edge beyond the total
|
429
|
+
edge count of loop_input
|
430
|
+
*/
|
431
|
+
SU_RESULT SULoopInputEdgeSetLayer(SULoopInputRef loop_input, size_t edge_index, SULayerRef layer);
|
432
|
+
|
433
|
+
/**
|
434
|
+
@brief Adds a simple curve to a loop input object.
|
435
|
+
@param[in] loop_input The loop input object.
|
436
|
+
@param[in] first_edge_index First edge index to be associated with the curve.
|
437
|
+
@param[in] last_edge_index Last edge index to be associated with the curve.
|
438
|
+
@related SUGeometryInputRef
|
439
|
+
@return
|
440
|
+
- \ref SU_ERROR_NONE on success
|
441
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input is not valid
|
442
|
+
- \ref SU_ERROR_OUT_OF_RANGE if first_edge_index or last_edge_index reference an
|
443
|
+
edge beyond the loop's total edge count
|
444
|
+
*/
|
445
|
+
SU_RESULT SULoopInputAddCurve(
|
446
|
+
SULoopInputRef loop_input, size_t first_edge_index, size_t last_edge_index);
|
447
|
+
|
448
|
+
/**
|
449
|
+
@brief Retrieves whether the loop input is closed. A loop input can be closed
|
450
|
+
either by re-adding the start vertex to the end of the loop using \ref
|
451
|
+
SULoopInputAddVertexIndex or by adding a curve to the loop input which
|
452
|
+
connects the loop's start and end points using \ref SULoopInputAddCurve().
|
453
|
+
@since SketchUp 2017 M2, API 5.2
|
454
|
+
@param[in] loop_input The loop input object.
|
455
|
+
@param[out] is_closed The flag retrieved (true if the loop is closed).
|
456
|
+
@related SUGeometryInputRef
|
457
|
+
@return
|
458
|
+
- \ref SU_ERROR_NONE on success
|
459
|
+
- \ref SU_ERROR_INVALID_INPUT if loop_input is not valid
|
460
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if is_closed is NULL
|
461
|
+
count
|
462
|
+
*/
|
463
|
+
SU_RESULT SULoopInputIsClosed(SULoopInputRef loop_input, bool* is_closed);
|
464
|
+
|
465
|
+
/**
|
466
|
+
@brief Adds a face to a geometry input object with a given outer loop for the
|
467
|
+
face.
|
468
|
+
|
469
|
+
@warning Breaking Change: The behavior of this method was changed in
|
470
|
+
SketchUp 2017 M2, API 5.2. An additional error code was added (\ref
|
471
|
+
SU_ERROR_INVALID_ARGUMENT) to indicate to users when the loop contains
|
472
|
+
invalid data.
|
473
|
+
|
474
|
+
@param[in] geom_input The geometry input object.
|
475
|
+
@param[in] outer_loop The outer loop to be set for the face. If the
|
476
|
+
function succeeds (i.e. returns SU_ERROR_NONE),
|
477
|
+
this loop will be deallocated.
|
478
|
+
@param[out] added_face_index (optional) If not NULL, returns the index of the
|
479
|
+
added face.
|
480
|
+
@related SUGeometryInputRef
|
481
|
+
@return
|
482
|
+
- \ref SU_ERROR_NONE on success
|
483
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
484
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if outer_loop is NULL
|
485
|
+
- \ref SU_ERROR_INVALID_ARGUMENT if the data specifies an invalid loop
|
486
|
+
*/
|
487
|
+
SU_RESULT SUGeometryInputAddFace(
|
488
|
+
SUGeometryInputRef geom_input, SULoopInputRef* outer_loop, size_t* added_face_index);
|
489
|
+
|
490
|
+
/**
|
491
|
+
@brief Sets a flag in the geometry input that, when true, will create a face by
|
492
|
+
reversing the orientations of all of its loops.
|
493
|
+
@param[in] geom_input The geometry input object.
|
494
|
+
@param[in] face_index Index of the face to be reversed.
|
495
|
+
@param[in] reverse The given reverse flag.
|
496
|
+
@related SUGeometryInputRef
|
497
|
+
@return
|
498
|
+
- \ref SU_ERROR_NONE on success
|
499
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
500
|
+
- \ref SU_ERROR_OUT_OF_RANGE if face_index references a face beyond the total
|
501
|
+
face count of geom_input
|
502
|
+
*/
|
503
|
+
SU_RESULT SUGeometryInputFaceSetReverse(
|
504
|
+
SUGeometryInputRef geom_input, size_t face_index, bool reverse);
|
505
|
+
|
506
|
+
/**
|
507
|
+
@brief Sets the layer of a face in the geometry input.
|
508
|
+
@param[in] geom_input The geometry input object.
|
509
|
+
@param[in] face_index Index of the face to be reversed.
|
510
|
+
@param[in] layer The layer to be set.
|
511
|
+
@related SUGeometryInputRef
|
512
|
+
@return
|
513
|
+
- \ref SU_ERROR_NONE on success
|
514
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input or layer is not valid
|
515
|
+
- \ref SU_ERROR_OUT_OF_RANGE if face_index references a face beyond the total
|
516
|
+
face count of geom_input
|
517
|
+
*/
|
518
|
+
SU_RESULT SUGeometryInputFaceSetLayer(
|
519
|
+
SUGeometryInputRef geom_input, size_t face_index, SULayerRef layer);
|
520
|
+
|
521
|
+
/**
|
522
|
+
@brief Adds an inner loop to a face in the geometry input.
|
523
|
+
|
524
|
+
@warning Breaking Change: The behavior of this method was changed in
|
525
|
+
SketchUp 2017 M2, API 5.2. An additional error code was added (\ref
|
526
|
+
SU_ERROR_INVALID_ARGUMENT) to indicate to users when the loop contains
|
527
|
+
invalid data.
|
528
|
+
|
529
|
+
@param[in] geom_input The geometry input object.
|
530
|
+
@param[in] face_index Index of the face to receive the inner loop.
|
531
|
+
@param[in] loop_input The inner loop to be added. If the function succeeds
|
532
|
+
(i.e. returns SU_ERROR_NONE), this loop will be
|
533
|
+
deallocated.
|
534
|
+
@related SUGeometryInputRef
|
535
|
+
@return
|
536
|
+
- \ref SU_ERROR_NONE on success
|
537
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input or *loop_input are not valid
|
538
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if loop_input is NULL
|
539
|
+
- \ref SU_ERROR_OUT_OF_RANGE if face_index references a face beyond the total
|
540
|
+
face count of geom_input.
|
541
|
+
- \ref SU_ERROR_INVALID_ARGUMENT if the data specifies an invalid loop
|
542
|
+
*/
|
543
|
+
SU_RESULT SUGeometryInputFaceAddInnerLoop(
|
544
|
+
SUGeometryInputRef geom_input, size_t face_index, SULoopInputRef* loop_input);
|
545
|
+
|
546
|
+
/**
|
547
|
+
@brief Sets the front material of a face in the geometry input.
|
548
|
+
|
549
|
+
@deprecated This function is made obsolete by the newer
|
550
|
+
SUGeometryInputFaceSetFrontMaterialPosition() and left in place only
|
551
|
+
for compatibility.
|
552
|
+
|
553
|
+
@see SUGeometryInputFaceSetFrontMaterialPosition
|
554
|
+
|
555
|
+
@param[in] geom_input The geometry input object.
|
556
|
+
@param[in] face_index Index of the face to receive the material.
|
557
|
+
@param[in] material_input The material input to set.
|
558
|
+
|
559
|
+
@related SUGeometryInputRef
|
560
|
+
|
561
|
+
@return
|
562
|
+
- \ref SU_ERROR_NONE on success
|
563
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
564
|
+
- \ref SU_ERROR_OUT_OF_RANGE if face_index references a face beyond the total
|
565
|
+
face count of geom_input
|
566
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if material_input is NULL
|
567
|
+
- \ref SU_ERROR_INVALID_ARGUMENT is the material is owned by a layer or image
|
568
|
+
*/
|
569
|
+
SU_RESULT SUGeometryInputFaceSetFrontMaterial(
|
570
|
+
SUGeometryInputRef geom_input, size_t face_index, const struct SUMaterialInput* material_input);
|
571
|
+
|
572
|
+
/**
|
573
|
+
@brief Sets the back material of a face in the geometry input.
|
574
|
+
|
575
|
+
@deprecated This function is made obsolete by the newer
|
576
|
+
SUGeometryInputFaceSetBackMaterialPosition() and left in place only
|
577
|
+
for compatibility.
|
578
|
+
|
579
|
+
@see SUGeometryInputFaceSetBackMaterialPosition
|
580
|
+
|
581
|
+
@param[in] geom_input The geometry input object.
|
582
|
+
@param[in] face_index Index of the face to receive the material.
|
583
|
+
@param[in] material_input The material input to set.
|
584
|
+
|
585
|
+
@related SUGeometryInputRef
|
586
|
+
|
587
|
+
@return
|
588
|
+
- \ref SU_ERROR_NONE on success
|
589
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
590
|
+
- \ref SU_ERROR_OUT_OF_RANGE if face_index references a face beyond the total
|
591
|
+
face count of geom_input
|
592
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if material_input is NULL
|
593
|
+
- \ref SU_ERROR_INVALID_ARGUMENT is the material is owned by a layer or image
|
594
|
+
*/
|
595
|
+
SU_RESULT SUGeometryInputFaceSetBackMaterial(
|
596
|
+
SUGeometryInputRef geom_input, size_t face_index, const struct SUMaterialInput* material_input);
|
597
|
+
|
598
|
+
/**
|
599
|
+
@brief Sets the front material of a face in the geometry input.
|
600
|
+
|
601
|
+
@param[in] geom_input The geometry input object.
|
602
|
+
@param[in] face_index Index of the face to receive the material.
|
603
|
+
@param[in] material_input The material input to set.
|
604
|
+
|
605
|
+
@related SUGeometryInputRef
|
606
|
+
|
607
|
+
@since SketchUp 2021.1, API 9.1
|
608
|
+
|
609
|
+
@return
|
610
|
+
- \ref SU_ERROR_NONE on success
|
611
|
+
- \ref SU_ERROR_INVALID_INPUT if \p geom_input is not valid
|
612
|
+
- \ref SU_ERROR_OUT_OF_RANGE if \p face_index references a face beyond the total
|
613
|
+
face count of \p geom_input
|
614
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if \p material_input is NULL
|
615
|
+
- \ref SU_ERROR_INVALID_ARGUMENT is the material is owned by a layer or image
|
616
|
+
*/
|
617
|
+
SU_RESULT SUGeometryInputFaceSetFrontMaterialByPosition(
|
618
|
+
SUGeometryInputRef geom_input, size_t face_index,
|
619
|
+
const struct SUMaterialPositionInput* material_input);
|
620
|
+
|
621
|
+
/**
|
622
|
+
@brief Sets the back material of a face in the geometry input.
|
623
|
+
|
624
|
+
@param[in] geom_input The geometry input object.
|
625
|
+
@param[in] face_index Index of the face to receive the material.
|
626
|
+
@param[in] material_input The material input to set.
|
627
|
+
|
628
|
+
@related SUGeometryInputRef
|
629
|
+
|
630
|
+
@since SketchUp 2021.1, API 9.1
|
631
|
+
|
632
|
+
@return
|
633
|
+
- \ref SU_ERROR_NONE on success
|
634
|
+
- \ref SU_ERROR_INVALID_INPUT if \p geom_input is not valid
|
635
|
+
- \ref SU_ERROR_OUT_OF_RANGE if \p face_index references a face beyond the total
|
636
|
+
face count of \p geom_input
|
637
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if \p material_input is NULL
|
638
|
+
- \ref SU_ERROR_INVALID_ARGUMENT is the material is owned by a layer or image
|
639
|
+
*/
|
640
|
+
SU_RESULT SUGeometryInputFaceSetBackMaterialByPosition(
|
641
|
+
SUGeometryInputRef geom_input, size_t face_index,
|
642
|
+
const struct SUMaterialPositionInput* material_input);
|
643
|
+
|
644
|
+
/**
|
645
|
+
@brief Sets a flag in the geometry input that, when true, will create a hidden
|
646
|
+
face.
|
647
|
+
@since SketchUp 2017, API 5.0
|
648
|
+
@param[in] geom_input The geometry input object.
|
649
|
+
@param[in] face_index Index of the face to be hidden.
|
650
|
+
@param[in] hidden The given hidden flag.
|
651
|
+
@related SUGeometryInputRef
|
652
|
+
@return
|
653
|
+
- \ref SU_ERROR_NONE on success
|
654
|
+
- \ref SU_ERROR_INVALID_INPUT if geom_input is not valid
|
655
|
+
- \ref SU_ERROR_OUT_OF_RANGE if face_index references a face beyond the total
|
656
|
+
face count of geom_input
|
657
|
+
*/
|
658
|
+
SU_RESULT SUGeometryInputFaceSetHidden(
|
659
|
+
SUGeometryInputRef geom_input, size_t face_index, bool hidden);
|
660
|
+
|
661
|
+
/**
|
662
|
+
@brief Returns all the various geometry counts.
|
663
|
+
@since SketchUp 2018, API 6.0
|
664
|
+
@param[in] geom_input The geometry input object.
|
665
|
+
@param[out] vertices_count The total count of vertices.
|
666
|
+
@param[out] faces_count The total count of faces.
|
667
|
+
@param[out] edge_count The total count of edges.
|
668
|
+
@param[out] curve_count The total count of curves.
|
669
|
+
@param[out] arc_count The total count of arcs.
|
670
|
+
@related SUGeometryInputRef
|
671
|
+
@return
|
672
|
+
- \ref SU_ERROR_NONE on success
|
673
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if vertices_count, faces_count,
|
674
|
+
edge_count, curve_count, or arc_count is NULL
|
675
|
+
*/
|
676
|
+
SU_RESULT SUGeometryInputGetCounts(
|
677
|
+
SUGeometryInputRef geom_input, size_t* vertices_count, size_t* faces_count, size_t* edge_count,
|
678
|
+
size_t* curve_count, size_t* arc_count);
|
679
|
+
|
680
|
+
#ifdef __cplusplus
|
681
|
+
} // extern "C"
|
682
|
+
#endif
|
683
|
+
#pragma pack(pop)
|
684
|
+
|
685
|
+
#endif // SKETCHUP_MODEL_GEOMETRY_INPUT_H_
|