WIP: Vulkan: Workbench #107886
|
@ -246,9 +246,9 @@ static bool rna_DepsgraphUpdate_is_updated_geometry_get(PointerRNA *ptr)
|
||||||
|
|
||||||
/* **************** Depsgraph **************** */
|
/* **************** Depsgraph **************** */
|
||||||
|
|
||||||
static void rna_Depsgraph_debug_relations_graphviz(Depsgraph *depsgraph, const char *filename)
|
static void rna_Depsgraph_debug_relations_graphviz(Depsgraph *depsgraph, const char *filepath)
|
||||||
{
|
{
|
||||||
FILE *f = fopen(filename, "w");
|
FILE *f = fopen(filepath, "w");
|
||||||
if (f == NULL) {
|
if (f == NULL) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -257,14 +257,14 @@ static void rna_Depsgraph_debug_relations_graphviz(Depsgraph *depsgraph, const c
|
||||||
}
|
}
|
||||||
|
|
||||||
static void rna_Depsgraph_debug_stats_gnuplot(Depsgraph *depsgraph,
|
static void rna_Depsgraph_debug_stats_gnuplot(Depsgraph *depsgraph,
|
||||||
const char *filename,
|
const char *filepath,
|
||||||
const char *output_filename)
|
const char *output_filepath)
|
||||||
{
|
{
|
||||||
FILE *f = fopen(filename, "w");
|
FILE *f = fopen(filepath, "w");
|
||||||
if (f == NULL) {
|
if (f == NULL) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
DEG_debug_stats_gnuplot(depsgraph, f, "Timing Statistics", output_filename);
|
DEG_debug_stats_gnuplot(depsgraph, f, "Timing Statistics", output_filepath);
|
||||||
fclose(f);
|
fclose(f);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -695,15 +695,15 @@ static void rna_def_depsgraph(BlenderRNA *brna)
|
||||||
func = RNA_def_function(
|
func = RNA_def_function(
|
||||||
srna, "debug_relations_graphviz", "rna_Depsgraph_debug_relations_graphviz");
|
srna, "debug_relations_graphviz", "rna_Depsgraph_debug_relations_graphviz");
|
||||||
parm = RNA_def_string_file_path(
|
parm = RNA_def_string_file_path(
|
||||||
func, "filename", NULL, FILE_MAX, "File Name", "Output path for the graphviz debug file");
|
func, "filepath", NULL, FILE_MAX, "File Name", "Output path for the graphviz debug file");
|
||||||
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
|
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
|
||||||
|
|
||||||
func = RNA_def_function(srna, "debug_stats_gnuplot", "rna_Depsgraph_debug_stats_gnuplot");
|
func = RNA_def_function(srna, "debug_stats_gnuplot", "rna_Depsgraph_debug_stats_gnuplot");
|
||||||
parm = RNA_def_string_file_path(
|
parm = RNA_def_string_file_path(
|
||||||
func, "filename", NULL, FILE_MAX, "File Name", "Output path for the gnuplot debug file");
|
func, "filepath", NULL, FILE_MAX, "File Name", "Output path for the gnuplot debug file");
|
||||||
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
|
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
|
||||||
parm = RNA_def_string_file_path(func,
|
parm = RNA_def_string_file_path(func,
|
||||||
"output_filename",
|
"output_filepath",
|
||||||
NULL,
|
NULL,
|
||||||
FILE_MAX,
|
FILE_MAX,
|
||||||
"Output File Name",
|
"Output File Name",
|
||||||
|
|
|
@ -1001,7 +1001,7 @@ static void rna_def_render_result(BlenderRNA *brna)
|
||||||
RNA_def_function_flag(func, FUNC_USE_REPORTS);
|
RNA_def_function_flag(func, FUNC_USE_REPORTS);
|
||||||
parm = RNA_def_string_file_name(
|
parm = RNA_def_string_file_name(
|
||||||
func,
|
func,
|
||||||
"filename",
|
"filepath",
|
||||||
NULL,
|
NULL,
|
||||||
FILE_MAX,
|
FILE_MAX,
|
||||||
"File Name",
|
"File Name",
|
||||||
|
@ -1122,11 +1122,11 @@ static void rna_def_render_layer(BlenderRNA *brna)
|
||||||
RNA_def_function_flag(func, FUNC_USE_REPORTS);
|
RNA_def_function_flag(func, FUNC_USE_REPORTS);
|
||||||
parm = RNA_def_string(
|
parm = RNA_def_string(
|
||||||
func,
|
func,
|
||||||
"filename",
|
"filepath",
|
||||||
NULL,
|
NULL,
|
||||||
0,
|
0,
|
||||||
"Filename",
|
"File Path",
|
||||||
"Filename to load into this render tile, must be no smaller than the renderlayer");
|
"File path to load into this render tile, must be no smaller than the renderlayer");
|
||||||
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
|
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
|
||||||
RNA_def_int(func,
|
RNA_def_int(func,
|
||||||
"x",
|
"x",
|
||||||
|
|
|
@ -87,12 +87,12 @@ static PyObject *bpy_app_icons_new_triangles(PyObject *UNUSED(self), PyObject *a
|
||||||
}
|
}
|
||||||
|
|
||||||
PyDoc_STRVAR(bpy_app_icons_new_triangles_from_file_doc,
|
PyDoc_STRVAR(bpy_app_icons_new_triangles_from_file_doc,
|
||||||
".. function:: new_triangles_from_file(filename)\n"
|
".. function:: new_triangles_from_file(filepath)\n"
|
||||||
"\n"
|
"\n"
|
||||||
" Create a new icon from triangle geometry.\n"
|
" Create a new icon from triangle geometry.\n"
|
||||||
"\n"
|
"\n"
|
||||||
" :arg filename: File path.\n"
|
" :arg filepath: File path.\n"
|
||||||
" :type filename: string.\n"
|
" :type filepath: string.\n"
|
||||||
" :return: Unique icon value (pass to interface ``icon_value`` argument).\n"
|
" :return: Unique icon value (pass to interface ``icon_value`` argument).\n"
|
||||||
" :rtype: int\n");
|
" :rtype: int\n");
|
||||||
static PyObject *bpy_app_icons_new_triangles_from_file(PyObject *UNUSED(self),
|
static PyObject *bpy_app_icons_new_triangles_from_file(PyObject *UNUSED(self),
|
||||||
|
@ -100,20 +100,20 @@ static PyObject *bpy_app_icons_new_triangles_from_file(PyObject *UNUSED(self),
|
||||||
PyObject *kw)
|
PyObject *kw)
|
||||||
{
|
{
|
||||||
/* bytes */
|
/* bytes */
|
||||||
char *filename;
|
char *filepath;
|
||||||
|
|
||||||
static const char *_keywords[] = {"filename", NULL};
|
static const char *_keywords[] = {"filepath", NULL};
|
||||||
static _PyArg_Parser _parser = {
|
static _PyArg_Parser _parser = {
|
||||||
"s" /* `filename` */
|
"s" /* `filepath` */
|
||||||
":new_triangles_from_file",
|
":new_triangles_from_file",
|
||||||
_keywords,
|
_keywords,
|
||||||
0,
|
0,
|
||||||
};
|
};
|
||||||
if (!_PyArg_ParseTupleAndKeywordsFast(args, kw, &_parser, &filename)) {
|
if (!_PyArg_ParseTupleAndKeywordsFast(args, kw, &_parser, &filepath)) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct Icon_Geom *geom = BKE_icon_geom_from_file(filename);
|
struct Icon_Geom *geom = BKE_icon_geom_from_file(filepath);
|
||||||
if (geom == NULL) {
|
if (geom == NULL) {
|
||||||
PyErr_SetString(PyExc_ValueError, "Unable to load from file");
|
PyErr_SetString(PyExc_ValueError, "Unable to load from file");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
Loading…
Reference in New Issue