Menu

Patch for some 0.88 command-line options

Help
2004-11-18
2013-04-03
  • Andrew Burton

    Andrew Burton - 2004-11-18

    The following command-line options in MAME 0.88 cause gxmame to be broken:

    -bpp
    -scanlines
    -artwork_resolution

    Attached is a preliminary diff -u to resolve these.

    --- options_string.c    2004-11-19 00:30:28.000000000 +1100
    +++ gxmame/src/options_string.c 2004-11-19 00:28:51.000000000 +1100
    @@ -55,7 +55,7 @@
                    brightness = g_strdup_printf("-brightness %i",(int)(((target->brightness)-0.5)*(100/1.5)));
            }

    -       option_string = g_strdup_printf (/*" -bpp %i "*/
    +       option_string = g_strdup_printf (" -bpp %i "
                                    "-arbheight %i "
                                    "-heightscale %i "
                                    "-widthscale %i "
    @@ -63,7 +63,7 @@
                                    "-effect %i "
                                    "-%sautodouble "
                                    "%s "                           /* dirty */
    -                               /*"-%sscanlines "*/
    +                               "-%sscanlines "
                                    "-frameskipper %i "
                                    "-%sthrottle "
                                    "-%ssleepidle "
    @@ -77,7 +77,7 @@
                                    "%s "                           /* rol */
                                    "%s "                           /* flipx */
                                    "%s ",                          /* flipy */
    -                               /*target->bpp,*/
    +                               target->bpp,
                                    target->arbheight,
                                    target->heightscale,
                                    target->widthscale,
    @@ -85,7 +85,7 @@
                                    target->effect,
                                    (target->autodouble)?"":"no",
                                    (dirty)?dirty:"",
    -                               /*(target->scanlines)?"":"no",*/
    +                               (target->scanlines)?"":"no",
                                    target->frameskipper,
                                    (target->throttle)?"":"no",
                                    (target->sleepidle)?"":"no",
    @@ -772,12 +772,12 @@
                                            "-%suse_overlays "                     /* use_overlays */
                                            "-%suse_bezels "                       /* use_bezels */
                                            "-%sartwork_crop "                     /* artwork_crop */
    -                                       /*"-artwork_resolution %i"*/,
    +                                       "-artwork_resolution %i",
                                            (target->use_backdrops)?"":"no",
                                            (target->use_overlays)?"":"no",
                                            (target->use_bezels)?"":"no",
    -                                       (target->artwork_crop)?"":"no"/*,
    -                                       target->artwork_resolution*/
    +                                       (target->artwork_crop)?"":"no",
    +                                       target->artwork_resolution
                                            );
            }

     
    • Nobody/Anonymous

      Trying to patch the fsource I got this message:

      patching file options_string.c
      patch: **** malformed patch at line 4: brightness = g_strdup_printf("-brightness %i",(int)(((target->brightness)-0.5)*(100/1.5)));

       
    • Ian Weber

      Ian Weber - 2004-11-22

      The original format of the patch has been messed up in it being pasted here, I've encountered it before. Best you can do is try and work out what needs to be changed and change it by hand. Don't be too optimistic though, I've tried it already and ran into trouble with the artwork_resolution part. Leaving that alone, I still ran into trouble as it doesn't cover all the parameter changes. Apparently the team is working on a way to make it less susceptible to problems like this but all the work is going into the 0.40 branch in CVS so it could be a while before we see anything.

       
    • Nobody/Anonymous

      i got the same error while patching.

      please help.

       
    • Nobody/Anonymous

      I also decided to try to fix up the options_string.c as well, and after removing the -bpp, -scanlines, -x11-mode, and -artwork-resolution options, (just commenting their strings out, the variables for them, and making sure commas were all right in the arg list) a recompile got things working for me.

      Unfortunately, I can only run games as root; as a local user, the call to xmame fails (without any output as to why.)

      Well, running gxmame as root is better than just trying to remember the rom names and running xmame by hand.  :)

      For those of you that are desperate, you can download the options_strings.c that I ended up with at http://fugutabetai.com/software/gxmame/options_string.c

      Be warned that all I did was comment out the "bad" options - I just put it up because it looks like people have had trouble with this, and want a temporary fix. 

      Please let me know (email fugu at the above domain) if you have any clue about the needing to run as root thing, or if that doesn't work for you.

      Note that after a ./configure; make you need to run the "src/gxmame" executable.

       

Log in to post a comment.