set_allegro_resource_path(3alleg4) [debian man page]
set_allegro_resource_path(3alleg4) Allegro manual set_allegro_resource_path(3alleg4)NAME
set_allegro_resource_path - Sets a specific resource search path. Allegro game programming library.
SYNOPSIS
#include <allegro.h>
int set_allegro_resource_path(int priority, const char *path);
DESCRIPTION
Sometimes Allegro doesn't look in enough places to find a resource. For those special cases, you can call this function before loading your
resource with additional paths to search for. You set up the priorities, higher numbers are searched for first. To modify an already setup
path, call this function with the same priority and the new path. To remove an already setup path, call this function with the priority of
the path and NULL as the path parameter. Example:
set_allegro_resource_path(10, "my_game/configs");
set_allegro_resource_path(0, "users/configs/");
set_allegro_resource_path(-45, "temp");
These custom paths will be valid until you call allegro_exit(). You can call this function before install_allegro(), but after set_ufor-
mat() if you want to use a text encoding format other than the default.
RETURN VALUE
Returns non-zero on success, zero if the path could not be added or you wanted to remove a path and the priority used didn't have any asso-
ciated path. Modification of existing paths always succeeds.
SEE ALSO find_allegro_resource(3alleg4)Allegro version 4.4.2 set_allegro_resource_path(3alleg4)
Check Out this Related Man Page
find_allegro_resource(3alleg4) Allegro manual find_allegro_resource(3alleg4)NAME
find_allegro_resource - Searches for a support file in many places. Allegro game programming library.
SYNOPSIS
#include <allegro.h>
int find_allegro_resource(char *dest, const char *resource, const char *ext, const char *datafile, const char *objectname, const char
*envvar, const char *subdir, int size);
DESCRIPTION
Searches for a support file, eg. `allegro.cfg' or `language.dat'. Passed a resource string describing what you are looking for, along with
extra optional information such as the default extension, what datafile to look inside, what the datafile object name is likely to be, any
special environment variable to check, and any subdirectory that you would like to check as well as the default location, this function
looks in a hell of a lot of different places :-). Pass NULL for the parameters you are not using.
Check the documentation chapter specific to your platform for information on additional paths this function might search for. Also, don't
forget about set_allegro_resource_path() to extend the searches. Example:
char path[256];
int ret;
ret = find_allegro_resource(path, "scores.cfg", NULL, NULL,
NULL, NULL, NULL, sizeof(path));
if (ret == 0) {
/* Found system wide scores file. */
} else {
/* No previous scores, create our own file. */
}
RETURN VALUE
Returns zero on success, and stores a full path to the file (at most size bytes) into the dest buffer.
SEE ALSO set_allegro_resource_path(3alleg4)Allegro version 4.4.2 find_allegro_resource(3alleg4)
This is my path for a directory in AIX
/oracle/ab/xx/yy/data/
i dont want to type this everytime at the prompt.
instead call the path using say
cd call (6 Replies)
Hi,
There is a C program with
"check_log(log_loc,log_name,path)" in it.
It seems that this C program is calling a check_log function but I didn't see any function called check_log in it.
By the way, the C program itself is called 'check_log'
I am just trying to learn a litter bit about C.... (6 Replies)
Guys,
Pl suggest me how to ignore a path in find command... I am aware of using "!" for other option... but how can i use it like this exampl...
I want to search something for in / but not in
Pl help.
Thanks.. (2 Replies)
How do i find files in more than one directory? I searched through forums, but could not land into the right thread.
I tried something like
find dir1|dir2 -name file1
but it doesn't work. Please suggest. (5 Replies)
My input path can be either
somepath (/tmp/life )
or
../../somepath ( ../../tmp/life )
Can someone help me help me with script to always extract "somepath" on both inputs
Thanks in advance (8 Replies)
Hi all,
I've searched for this but couldn't seem to find the answer I'm looking for. I have a text file that looks like this:
sgea0447 Earnings followed the same path. earnings followed the same path
sgea0448 Economic growth slowed further. economic growth slowed further... (13 Replies)
Hi everyone :),
I need sort Cisco configs to report but i cannot do the script to made this:
#### INPUT #####
config-register 0x2102
version 12.2
!
hostname Router
!
interface Ethernet0
description Red LAN
ip address 192.168.1.1 255.255.255.0
no cdp enable
!
interface Serial0... (6 Replies)
Hi All,
I have a c program called findPath.c in a path /home/harsh/c-Programs/. How can i find the path where the program is stored at runtime?? I have given the following
#include<stdio.h>
int main()
{
system("dirname $0");
return 0;
}
This is resulting in the output as
.
<single dot... (6 Replies)
I need to implement something like this.
1) search for a file(say *.doc) from a path (say /home/user/temp)
2) if file found & if file size > 0 : yes --> file valid
else : print file not valid.
I am trying to implement something like this, but seems i am terribly wrong somewhere.. ... (1 Reply)
I wasn't sure which forum to post this in. I am trying to compile logsurfer. After I run configure and the make, I get a complaint that paths.h is not found. I see three places where there is a paths.h:
/usr/include/pgsql/server/optimizer/paths.h... (3 Replies)
Hello,
I searched the forums and didn't see a situation like this:
I cannot figure out how to parse out just the file name from the full path. The path looks like this:
\\foo\bar\filename.ext
I don't think something like 'cut' will work so I tried to whip up a regex but couldn't get it... (12 Replies)