Blender  V2.93
subdiv_converter.c
Go to the documentation of this file.
1 /*
2  * This program is free software; you can redistribute it and/or
3  * modify it under the terms of the GNU General Public License
4  * as published by the Free Software Foundation; either version 2
5  * of the License, or (at your option) any later version.
6  *
7  * This program is distributed in the hope that it will be useful,
8  * but WITHOUT ANY WARRANTY; without even the implied warranty of
9  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10  * GNU General Public License for more details.
11  *
12  * You should have received a copy of the GNU General Public License
13  * along with this program; if not, write to the Free Software Foundation,
14  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
15  *
16  * The Original Code is Copyright (C) 2018 by Blender Foundation.
17  * All rights reserved.
18  */
19 
24 #include "subdiv_converter.h"
25 
26 #include "BLI_utildefines.h"
27 
29 
31 {
32  if (converter->freeUserData) {
33  converter->freeUserData(converter);
34  }
35 }
36 
38 {
39  switch (settings->vtx_boundary_interpolation) {
41  return OSD_VTX_BOUNDARY_NONE;
46  }
47  BLI_assert(!"Unknown vtx boundary interpolation");
49 }
50 
51 /*OpenSubdiv_FVarLinearInterpolation*/ int BKE_subdiv_converter_fvar_linear_from_settings(
52  const SubdivSettings *settings)
53 {
54  switch (settings->fvar_linear_interpolation) {
67  }
68  BLI_assert(!"Unknown fvar linear interpolation");
70 }
@ SUBDIV_FVAR_LINEAR_INTERPOLATION_ALL
Definition: BKE_subdiv.h:55
@ SUBDIV_FVAR_LINEAR_INTERPOLATION_CORNERS_ONLY
Definition: BKE_subdiv.h:51
@ SUBDIV_FVAR_LINEAR_INTERPOLATION_BOUNDARIES
Definition: BKE_subdiv.h:54
@ SUBDIV_FVAR_LINEAR_INTERPOLATION_NONE
Definition: BKE_subdiv.h:50
@ SUBDIV_FVAR_LINEAR_INTERPOLATION_CORNERS_AND_JUNCTIONS
Definition: BKE_subdiv.h:52
@ SUBDIV_FVAR_LINEAR_INTERPOLATION_CORNERS_JUNCTIONS_AND_CONCAVE
Definition: BKE_subdiv.h:53
@ SUBDIV_VTX_BOUNDARY_EDGE_AND_CORNER
Definition: BKE_subdiv.h:46
@ SUBDIV_VTX_BOUNDARY_NONE
Definition: BKE_subdiv.h:42
@ SUBDIV_VTX_BOUNDARY_EDGE_ONLY
Definition: BKE_subdiv.h:44
#define BLI_assert(a)
Definition: BLI_assert.h:58
@ OSD_FVAR_LINEAR_INTERPOLATION_CORNERS_ONLY
@ OSD_FVAR_LINEAR_INTERPOLATION_ALL
@ OSD_FVAR_LINEAR_INTERPOLATION_NONE
@ OSD_FVAR_LINEAR_INTERPOLATION_CORNERS_PLUS1
@ OSD_FVAR_LINEAR_INTERPOLATION_BOUNDARIES
@ OSD_FVAR_LINEAR_INTERPOLATION_CORNERS_PLUS2
@ OSD_VTX_BOUNDARY_NONE
@ OSD_VTX_BOUNDARY_EDGE_AND_CORNER
@ OSD_VTX_BOUNDARY_EDGE_ONLY
void(* freeUserData)(const struct OpenSubdiv_Converter *converter)
eSubdivFVarLinearInterpolation fvar_linear_interpolation
Definition: BKE_subdiv.h:87
eSubdivVtxBoundaryInterpolation vtx_boundary_interpolation
Definition: BKE_subdiv.h:86
int BKE_subdiv_converter_fvar_linear_from_settings(const SubdivSettings *settings)
void BKE_subdiv_converter_free(struct OpenSubdiv_Converter *converter)
int BKE_subdiv_converter_vtx_boundary_interpolation_from_settings(const SubdivSettings *settings)