Home › Forums › Game Frame › Game Frame Art Gallery › CONFIG.INI Documentation
Tagged: finish config.ini
- This topic has 19 replies, 8 voices, and was last updated 7 years, 3 months ago by Jeremy Williams.
-
AuthorPosts
-
March 12, 2014 at 3:31 pm #689Jeremy WilliamsKeymaster
As you might know, to show a single image on Game Frame, you just need to drop a 24-bit BMP into a folder and name it 0.bmp. To create an animation, you just add more graphics (1.bmp, 2.bmp, etc.). Optionally, you may include a text file called config.ini that unlocks additional control.
What follows is a copy and paste from a sample config.ini file. In this example, a sprite is animated at 10fps and moved across the screen from left to right, starting and ending off-screen. When it gets all the way to the right, the animation will end and the system will progress to the next folder. Please let me know what else I can clarify.
CONFIG.INI
# All of these settings are optional.
# If this file doesnโt exist, or if
# settings donโt appear in this file,
# Game Frame will use default values.[animation]
# milliseconds to hold each frame
# (1000 = 1 sec; lower is faster)
hold = 100# should the animation loop? If false,
# system will progress to next folder
# after the last frame is displayed.
loop = true[translate]
# move the animation across the screen
# this many pixels per frame. Experiment
# with positive and negative numbers for
# different directions.
moveX = 1
moveY = 0# should the movement loop?
loop = false# begin/end scroll off screen?
panoff = true# optionally dictate the next animation
# EXAMPLE: nextFolder = mspacman
# nextFolder = defend1March 12, 2014 at 6:28 pm #697foglemanParticipantInstead of “panoff” why not allow specifying an initial position in addition to the offset that is applied each frame (moveX and moveY)? Wouldn’t that be more flexible? I guess it’d look like this:
startX = -16
startY = 0moveX = 1
moveY = 0Hmm, but then you’d need to specify an ending position too, or a number of frames to run.
Basically you want to specify start, end, step.
x = -16, 16, 1 # x ranges from -16 to 16 with a step of 1
y = 0, 0, 0 # y is fixed at 0These could be separated into multiple fields if you don’t want the comma separated values.
March 12, 2014 at 6:30 pm #698foglemanParticipantIf 0.bmp is an multi-image sequence (16×64 px for example) and 1.bmp is too, do they both animate in sequence?
March 12, 2014 at 6:52 pm #699Jeremy WilliamsKeymasterRegarding a more flexible alternative to “panoff,” that sounds like a great community firmware mod. I want to start things as simple as possible, thus a binary solution. The implementation works perfectly for throwing old arcade characters on the screen that walk/drive/fly across, and everything eBoy’s wanted to do. It also works for film strips.
To your other question, if 0.bmp has a MoveX/Y value > 0, and 1.bmp is present (or more graphics), it will offset X/Y pixels each frame AND iterate through the files each frame. This combines multi-file animation with translation. Does that make sense? eBoy has put this to great use in a couple impressive animations.
If you want to sequence from one animation to another, there are two options. You can use the last entry in CONFIG.INI, or you can nest numerical folders. For instance, if you wanted to create a sequence of animations from Pacman:
/pacman/0 (includes pacman animation)
/pacman/1 (includes ghost animation)
/pacman/2 (includes blue ghost animation)
/pacman/3 (includes pacman going the other direction)This works just as well with filmstrips or multi-file animations. The only difference between the two methods (CONFIG.INI or nested folders) is how the next button works. With nested, it will skip subsequent folders. With CONFIG.INI, it will go to what’s specified.
August 15, 2014 at 7:20 pm #1184renaud.bedardParticipantHi!
Just got my GameFrame and I’m trying to port over some animated GIFs to it.
Is there any way to set a delay per frame, if my frames have different delay times to one another?If not I’ll just duplicate frames for it to work, but it’s a bit more work.
Thanks! ๐
August 15, 2014 at 7:25 pm #1185Jeremy WilliamsKeymasterNo, I’m afraid you have to duplicate frames. Game Frame runs at a constant rate… just like a movie projector! ๐
As an aside, I just posted a relevant guide here:
https://www.ledseq.com/faq-category/game-frame/#post-1165December 19, 2014 at 4:18 am #1700gnolivosParticipantIn your nested folder example, it was not clear to me: Should I include a CONFIG.INI file into each of the nested pacman folders? I would like to have specific frame rates for each of the sequences for quite legitimate reasons ๐
/pacman/0 (includes pacman animation)
/pacman/1 (includes ghost animation)
/pacman/2 (includes blue ghost animation)
/pacman/3 (includes pacman going the other direction)December 19, 2014 at 4:28 am #1701gnolivosParticipantTested it out, and YES it does support config.ini within subfolders! very nice.
December 19, 2014 at 5:12 am #1706Jeremy WilliamsKeymasterYep! And FYI this is explained in the FAQ.
Each of the numerical folders looks just like a standard image folder, and can contain its own CONFIG.INI.
March 2, 2016 at 10:58 pm #2346ian.hiltonParticipantHi,
I am trying to use the gfx2gf batch file on the following animated gif. The properties are 8bit depth dimensions 64×64 pixels. Although the image is designed as 16×16 pixel.The batch file works but there are a lot of colour artifacts introduced so the edges dont look clean. Is there any way to avoid these artifaces being introduced to retain the sharp edges of the original?
Attachments:
You must be logged in to view attached files.March 2, 2016 at 11:57 pm #2349Jeremy WilliamsKeymasterYeah, when I get home tonight I’ll provide a fix. You want to resize using nearest neighbor filtering.
March 3, 2016 at 7:46 am #2351Jeremy WilliamsKeymaster@ian.hilton: Grab the latest gfx2gf and see if that works for you:
https://www.ledseq.com/downloads/gfx2gf.zipIt now asks you if you want to use nearest neighbor on launch, and you have to answer Y or N. It will also ask if you want to crop if your source is not square.
NOTE: I had to update my copy of FFMPEG (dated 2013) for nearest neighbor to look correct. There were subtle inaccuracies in my old copy.
March 3, 2016 at 1:40 pm #2352^MuYa^ParticipantAre you sure this is the new .bat file? It’s not asking me any questions.
March 3, 2016 at 4:31 pm #2353Jeremy WilliamsKeymasterSorry, I can’t explain it — some weird caching issue. If I rename the file on the server I can download it correctly. Try this:
March 3, 2016 at 4:52 pm #2354ian.hiltonParticipantAwesome, that works a treat. Expect some additions to the art gallery. Ive got a bunch of cool stuff to process and add ๐
-
AuthorPosts
- The forum ‘Game Frame Art Gallery’ is closed to new topics and replies.