forked from bartvdbraak/blender
RNA: sequencer channel range was incorrect
Broke since 2.4x, zero sequence channels shouldn't be allowed
This commit is contained in:
parent
3b5eac548f
commit
2613bfadb2
@ -1496,7 +1496,7 @@ static void rna_def_sequence(BlenderRNA *brna)
|
||||
|
||||
prop = RNA_def_property(srna, "channel", PROP_INT, PROP_UNSIGNED);
|
||||
RNA_def_property_int_sdna(prop, NULL, "machine");
|
||||
RNA_def_property_range(prop, 0, MAXSEQ - 1);
|
||||
RNA_def_property_range(prop, 1, MAXSEQ);
|
||||
RNA_def_property_ui_text(prop, "Channel", "Y position of the sequence strip");
|
||||
RNA_def_property_int_funcs(prop, NULL, "rna_Sequence_channel_set", NULL); /* overlap test */
|
||||
RNA_def_property_update(prop, NC_SCENE | ND_SEQUENCER, "rna_Sequence_update");
|
||||
|
@ -485,8 +485,8 @@ void RNA_api_sequences(BlenderRNA *brna, PropertyRNA *cprop)
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_pointer(func, "clip", "MovieClip", "", "Movie clip to add");
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL);
|
||||
parm = RNA_def_int(func, "channel", 0, 0, MAXSEQ - 1, "Channel",
|
||||
"The channel for the new sequence", 0, MAXSEQ - 1);
|
||||
parm = RNA_def_int(func, "channel", 0, 1, MAXSEQ, "Channel",
|
||||
"The channel for the new sequence", 1, MAXSEQ);
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "frame_start", 0, -MAXFRAME, MAXFRAME, "",
|
||||
"The start frame for the new sequence", -MAXFRAME, MAXFRAME);
|
||||
@ -502,8 +502,8 @@ void RNA_api_sequences(BlenderRNA *brna, PropertyRNA *cprop)
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_pointer(func, "mask", "Mask", "", "Mask to add");
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL);
|
||||
parm = RNA_def_int(func, "channel", 0, 0, MAXSEQ - 1, "Channel",
|
||||
"The channel for the new sequence", 0, MAXSEQ - 1);
|
||||
parm = RNA_def_int(func, "channel", 0, 1, MAXSEQ, "Channel",
|
||||
"The channel for the new sequence", 1, MAXSEQ);
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "frame_start", 0, -MAXFRAME, MAXFRAME, "",
|
||||
"The start frame for the new sequence", -MAXFRAME, MAXFRAME);
|
||||
@ -519,8 +519,8 @@ void RNA_api_sequences(BlenderRNA *brna, PropertyRNA *cprop)
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_pointer(func, "scene", "Scene", "", "Scene to add");
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL);
|
||||
parm = RNA_def_int(func, "channel", 0, 0, MAXSEQ - 1, "Channel",
|
||||
"The channel for the new sequence", 0, MAXSEQ - 1);
|
||||
parm = RNA_def_int(func, "channel", 0, 1, MAXSEQ, "Channel",
|
||||
"The channel for the new sequence", 1, MAXSEQ);
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "frame_start", 0, -MAXFRAME, MAXFRAME, "",
|
||||
"The start frame for the new sequence", -MAXFRAME, MAXFRAME);
|
||||
@ -536,8 +536,8 @@ void RNA_api_sequences(BlenderRNA *brna, PropertyRNA *cprop)
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_string(func, "filepath", "File", 0, "", "Filepath to image");
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "channel", 0, 0, MAXSEQ - 1, "Channel",
|
||||
"The channel for the new sequence", 0, MAXSEQ - 1);
|
||||
parm = RNA_def_int(func, "channel", 0, 1, MAXSEQ, "Channel",
|
||||
"The channel for the new sequence", 1, MAXSEQ);
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "frame_start", 0, -MAXFRAME, MAXFRAME, "",
|
||||
"The start frame for the new sequence", -MAXFRAME, MAXFRAME);
|
||||
@ -553,8 +553,8 @@ void RNA_api_sequences(BlenderRNA *brna, PropertyRNA *cprop)
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_string(func, "filepath", "File", 0, "", "Filepath to movie");
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "channel", 0, 0, MAXSEQ - 1, "Channel",
|
||||
"The channel for the new sequence", 0, MAXSEQ - 1);
|
||||
parm = RNA_def_int(func, "channel", 0, 1, MAXSEQ, "Channel",
|
||||
"The channel for the new sequence", 1, MAXSEQ);
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "frame_start", 0, -MAXFRAME, MAXFRAME, "",
|
||||
"The start frame for the new sequence", -MAXFRAME, MAXFRAME);
|
||||
@ -570,8 +570,8 @@ void RNA_api_sequences(BlenderRNA *brna, PropertyRNA *cprop)
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_string(func, "filepath", "File", 0, "", "Filepath to movie");
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "channel", 0, 0, MAXSEQ - 1, "Channel",
|
||||
"The channel for the new sequence", 0, MAXSEQ - 1);
|
||||
parm = RNA_def_int(func, "channel", 0, 1, MAXSEQ, "Channel",
|
||||
"The channel for the new sequence", 1, MAXSEQ);
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "frame_start", 0, -MAXFRAME, MAXFRAME, "",
|
||||
"The start frame for the new sequence", -MAXFRAME, MAXFRAME);
|
||||
@ -588,8 +588,8 @@ void RNA_api_sequences(BlenderRNA *brna, PropertyRNA *cprop)
|
||||
parm = RNA_def_enum(func, "type", seq_effect_items, 0, "Type",
|
||||
"type for the new sequence");
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "channel", 0, 0, MAXSEQ - 1, "Channel",
|
||||
"The channel for the new sequence", 0, MAXSEQ - 1);
|
||||
parm = RNA_def_int(func, "channel", 0, 1, MAXSEQ, "Channel",
|
||||
"The channel for the new sequence", 1, MAXSEQ);
|
||||
/* don't use MAXFRAME since it makes importer scripts fail */
|
||||
RNA_def_property_flag(parm, PROP_REQUIRED);
|
||||
parm = RNA_def_int(func, "frame_start", 0, INT_MIN, INT_MAX, "",
|
||||
|
Loading…
Reference in New Issue
Block a user