Skip to content
This repository was archived by the owner on Nov 4, 2023. It is now read-only.

Generic *_FILES suffix #45

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open

Generic *_FILES suffix #45

wants to merge 1 commit into from

Conversation

devolonter
Copy link
Contributor

This patch allows to use universal “SOMETHING_FILES” config setting for data files. For example, VIDEO_FILES, FONT_FILES, etc. Currently we can use BINARY_FILES for that, but I think it isn’t semantic a little, because images and sounds are also binary files, in some way. What do you think about that?

@blitz-research
Copy link
Owner

Not gonna commit this for now as I need to think through the meta data stuff a bit more!

But my first thoughts are I do think it's useful to have a BINARY_FILES var, in-so-far as I think file type filters should probably reflect the commands they are used with, ie: any files matching the BINARY_FILES filter should be loadable by DataBuffer.Load().

I think this should apply to all files - ie: by default, people shouldn't expect to be able to load png's into databuffers (although it'll probably 'just work' on most targets - although we COULD 'fix' this by checking meta data more thoroughly before loading stuff), because BINARY_FILES does not contain a .png filter. If for some reason someone does require this, they should probably have to use BINARY_FILES+=".png".

This means that any data pre-processor can take steps to ensure that the file is present in the native project in the correct format(s). It may in fact be necessary to duplicate the data in some cases, eg: XNA would probably require this as images need to be in a special format for LoadImage, while the original 'raw' data would need to be available for use with DataBuffer.Load.

@devolonter
Copy link
Contributor Author

OK, thanks for the info! Sounds interesting and more useful than my solution. Let me know, if I can help with it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants