mirror of
https://github.com/projectM-visualizer/projectm.git
synced 2026-03-01 04:55:03 +00:00
Fix token parsing in Milkdrop preset factory
Thanks to Adam Guthrie for the fix! git-svn-id: https://projectm.svn.sourceforge.net/svnroot/projectm/trunk@1356 6778bc44-b910-0410-a7a0-be141de4315d
This commit is contained in:
@ -70,7 +70,7 @@ bool Parser::tokenWrapAroundEnabled(false);
|
||||
token_t Parser::parseToken(std::istream & fs, char * string)
|
||||
{
|
||||
|
||||
char c;
|
||||
int c;
|
||||
int i;
|
||||
|
||||
if (string != NULL)
|
||||
@ -1843,7 +1843,7 @@ int Parser::parse_wavecode(char * token, std::istream & fs, MilkdropPreset * pr
|
||||
|
||||
/* Create new initial condition */
|
||||
init_cond = new InitCond(param, init_val);
|
||||
|
||||
|
||||
if (init_cond == NULL)
|
||||
{
|
||||
if (PARSE_DEBUG) printf("parse_wavecode: new_init_cond failed!\n");
|
||||
|
||||
@ -145,7 +145,7 @@ public:
|
||||
static int last_token_size;
|
||||
static bool tokenWrapAroundEnabled;
|
||||
|
||||
static PerFrameEqn *parse_per_frame_eqn( std::istream & fs, int index,
|
||||
static PerFrameEqn *parse_per_frame_eqn( std::istream & fs, int index,
|
||||
MilkdropPreset * preset);
|
||||
static int parse_per_pixel_eqn( std::istream & fs, MilkdropPreset * preset,
|
||||
char * init_string);
|
||||
|
||||
@ -39,7 +39,7 @@
|
||||
void PerPixelEqn::evaluate(int mesh_i, int mesh_j) {
|
||||
|
||||
GenExpr * eqn_ptr = 0;
|
||||
|
||||
|
||||
|
||||
eqn_ptr = this->gen_expr;
|
||||
|
||||
@ -69,6 +69,6 @@ PerPixelEqn::PerPixelEqn(int _index, Param * _param, GenExpr * _gen_expr):index(
|
||||
assert(index >= 0);
|
||||
assert(param != 0);
|
||||
assert(gen_expr != 0);
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -52,8 +52,8 @@ class PerPixelEqn {
|
||||
public:
|
||||
int index; /* used for splay tree ordering. */
|
||||
int flags; /* primarily to specify if this variable is user-defined */
|
||||
Param *param;
|
||||
GenExpr *gen_expr;
|
||||
Param *param;
|
||||
GenExpr *gen_expr;
|
||||
|
||||
void evalPerPixelEqns( Preset *preset );
|
||||
void evaluate(int mesh_i, int mesh_j);
|
||||
|
||||
Reference in New Issue
Block a user