dc v6 graphics
It is the number of the page. When no page control is present is reset to zero. In first page is zero, in next page 1, etc... You can see in idstools.c how according to the value of page, it does a different thing in the handler.phobox wrote:about the page control....
what is the value of param "page" passed to the handle function?
thans
ok thanks, i was looking into flashformat.c (or somethinglike that) that has only 2 pages...moonlight wrote:It is the number of the page. When no page control is present is reset to zero. In first page is zero, in next page 1, etc... You can see in idstools.c how according to the value of page, it does a different thing in the handler.phobox wrote:about the page control....
what is the value of param "page" passed to the handle function?
thans
Ciao! from Italy
moonlight has to complete VLF first. Its unable to be unloaded in its current state.phobox wrote:@Torch looking forward to see your program working.
@moonlight, please can you add png image format support? png images are used inside the psp: both in eboots and umds.
Can you add support for loading from PNG data in memory (Like if the file is already read into an array)?
bug:
vlfguinetconfdialog doesn't work for me... I'm calling it with something like that:
if(vlfGuiNetConfDialog() < 0)
{
vlfGuiMessageDialog("Connection error.", VLF_MD_TYPE_ERROR | VLF_MD_BUTTONS_NONE);
}
else
{
RegisterDialog(1);
}
It doesn't show the Net Dialog, but shows the register dialog :S
also, a input text and implementation of the osk plugin will be so cool...
that's my suggestion of what to do now :)
(osk plugin loaded by psputility_osk.h doesn't work, crash the vlf...)
sorry for my bad english ;)
vlfguinetconfdialog doesn't work for me... I'm calling it with something like that:
if(vlfGuiNetConfDialog() < 0)
{
vlfGuiMessageDialog("Connection error.", VLF_MD_TYPE_ERROR | VLF_MD_BUTTONS_NONE);
}
else
{
RegisterDialog(1);
}
It doesn't show the Net Dialog, but shows the register dialog :S
also, a input text and implementation of the osk plugin will be so cool...
that's my suggestion of what to do now :)
(osk plugin loaded by psputility_osk.h doesn't work, crash the vlf...)
sorry for my bad english ;)
is this the proper way to remove a fade?
(in this case for pics).
Code: Select all
vlfGuiSetPictureFade(picFocus, NULL, NULL, 0);
vlfGuiSetPictureVisibility(picFocus, 0);
Ciao! from Italy
vlfGuiLoadResources don't work:
the result of res is 0
Code: Select all
char *names[2];
void *datas[2];
int types[2], sizes[2];
names[0] = "tex_game";
names[1] = "tex_sdwn_game";
types[0] = types[1] = RCO_GRAPHIC;
int res = vlfGuiLoadResources("flash0:/vsh/resource/topmenu_plugin.rco", 2, names, types, datas, sizes, NULL);
if (res != 2)
{
char buffer [50];
int n;
n = sprintf(buffer, "Error 1: %d", res);
error1_text = vlfGuiAddText(354, 190, buffer);
if (res > 0)
{
error2_text = vlfGuiAddText(354, 190, "Error 2");
if (datas[0])
free(datas[0]);
if (datas[1])
free(datas[1]);
}
}
else
{
void *gme;
vlfGuiAddShadowedPicture(&gme, datas[0], sizes[0], datas[1], sizes[1], 441, 4, 1, 1, 1);
free(datas[0]);
free(datas[1]);
}
Since 3.71, topmenu_plugin doesn't contain that icon, but "topmenu_icon" instead. Also it is "tex_sdwf_game", not ""tex_sdwn_game"krosk wrote:vlfGuiLoadResources don't work:the result of res is 0Code: Select all
char *names[2]; void *datas[2]; int types[2], sizes[2]; names[0] = "tex_game"; names[1] = "tex_sdwn_game"; types[0] = types[1] = RCO_GRAPHIC; int res = vlfGuiLoadResources("flash0:/vsh/resource/topmenu_plugin.rco", 2, names, types, datas, sizes, NULL); if (res != 2) { char buffer [50]; int n; n = sprintf(buffer, "Error 1: %d", res); error1_text = vlfGuiAddText(354, 190, buffer); if (res > 0) { error2_text = vlfGuiAddText(354, 190, "Error 2"); if (datas[0]) free(datas[0]); if (datas[1]) free(datas[1]); } } else { void *gme; vlfGuiAddShadowedPicture(&gme, datas[0], sizes[0], datas[1], sizes[1], 441, 4, 1, 1, 1); free(datas[0]); free(datas[1]); }
Anb btw, using vlfGuiAddShadowedPictureResource directly is easier :p
-
- Posts: 23
- Joined: Sun Feb 17, 2008 12:32 am
-
- Posts: 23
- Joined: Sun Feb 17, 2008 12:32 am
Already looked in the source and no mention of that function in there.
EDIT: Found the spin stuff in the DC source, missed it first of all.
EDIT: Found the spin stuff in the DC source, missed it first of all.
Last edited by Gh0st-UPMS on Tue Sep 16, 2008 4:22 am, edited 1 time in total.
-
- Posts: 23
- Joined: Sun Feb 17, 2008 12:32 am
Looks like your trying to load a background image along with ReadFileAllocEx function. Might be wrong though as PSPlink works fine with VLF.phobox wrote:it seems not to be possible to debug a vlf app with psplink..
am i right?
trying doing that, i see on the screen strange waves (black and white), a strange effect on the battery icon and the "psplink bootstrp.. etc ect" flashing on the screen...
how to solve that?
EDIT: here the screenshot
http://www.sendspace.com/file/br9qxh
Sorry for delay, here is the version with support for termination, additionally i have included some defined types to make the prototypes more readable, and fixed a very critical bug that leaked memory each time something was loaded from a resource; also negative heaps other than -1 can now be specified.
Note: to terminate vlf, you need to stop the vlf.prx module from other thread. Because it seems that system needs some memory for that, when specifying a negative heap, don't specify -1, specify at least (mmm well is negative, so at most :p) -640.
There is included a vshmain replace sample which simply does stupid things with the waves on button presses, and exit with start. To make it work: put vlf.prx, intrafont.prx (get it from other release), and vsh_load.prx in ms0:/seplugins; change the name of real vshmain to vshmain_real.prx, and copy the vshmain.prx replacement to flash0:/vsh/module
Note for those that want to make vshmain.prx replacements: it seems that heaparea1.prx and heaparea2.prx have allocated lot of memory and leaving very small amount of memory (after vlf load, and specifying -640, you have 2 MB only, more or less). If you really need more memory, replace those modules with dummys, and load/start the real ones before loading/starting the real vshmain.prx.
Next release will be the first official one. I'll try to add the most important things that are missing: checkboxes, ip spin control, scrollbar, lateral menu, inputbox, osk (atm using utility), png support, fix the custom background code, and document everything (probably I'm missing some control :p)
Sorry for delay, here is the version with support for termination, additionally i have included some defined types to make the prototypes more readable, and fixed a very critical bug that leaked memory each time something was loaded from a resource; also negative heaps other than -1 can now be specified.
Note: to terminate vlf, you need to stop the vlf.prx module from other thread. Because it seems that system needs some memory for that, when specifying a negative heap, don't specify -1, specify at least (mmm well is negative, so at most :p) -640.
There is included a vshmain replace sample which simply does stupid things with the waves on button presses, and exit with start. To make it work: put vlf.prx, intrafont.prx (get it from other release), and vsh_load.prx in ms0:/seplugins; change the name of real vshmain to vshmain_real.prx, and copy the vshmain.prx replacement to flash0:/vsh/module
Note for those that want to make vshmain.prx replacements: it seems that heaparea1.prx and heaparea2.prx have allocated lot of memory and leaving very small amount of memory (after vlf load, and specifying -640, you have 2 MB only, more or less). If you really need more memory, replace those modules with dummys, and load/start the real ones before loading/starting the real vshmain.prx.
Next release will be the first official one. I'll try to add the most important things that are missing: checkboxes, ip spin control, scrollbar, lateral menu, inputbox, osk (atm using utility), png support, fix the custom background code, and document everything (probably I'm missing some control :p)
Thanks. Time to start coding.
mod = sceKernelLoadModule("flash0:/vsh/module/vshmain_real.prx", 0, NULL); doesn't work in a 0x800 mode module. In your sample the loader is 0x1000 mode where the above works.
Can you give some additional info on the heaparea?.prx ? At which point is it loaded? Is it safe to unload them in the replacement vshmain.prx?
mod = sceKernelLoadModule("flash0:/vsh/module/vshmain_real.prx", 0, NULL); doesn't work in a 0x800 mode module. In your sample the loader is 0x1000 mode where the above works.
Can you give some additional info on the heaparea?.prx ? At which point is it loaded? Is it safe to unload them in the replacement vshmain.prx?
This is a example of what can be done with that library:
At the moment is a really bad shell, but I think that I will do a good job :)
The developement thread:
http://www.elotrolado.net/hilo_alpha-re ... ll_1085541
At the moment is a really bad shell, but I think that I will do a good job :)
The developement thread:
http://www.elotrolado.net/hilo_alpha-re ... ll_1085541
Are all these libs required for just the wave background??
-lpsppower -lpsprtc -lvlfgui -lvlfgu -lvlfutils -lvlflibc -lpspreg -lpspsystemctrl_user -lpspkubridge -lpspwlan
And is this still required or is the path set automatically now?
In the unload thread can't I just directly load vshmain_real.prx using kuKernelLoadModule or is there some problem with that?
EDIT: OK..Just understood that your freeing all the user memory and loading vshmain_real.prx from a kernel prx so that all memory is available to vshmain on startup.
I am detecting button presses using the sceCtrl functions in another thread. It works, but should that be avoided and should I use the VLF event handlers instead?
And I still don't understand what is LIBC T_T
-lpsppower -lpsprtc -lvlfgui -lvlfgu -lvlfutils -lvlflibc -lpspreg -lpspsystemctrl_user -lpspkubridge -lpspwlan
And is this still required or is the path set automatically now?
Code: Select all
char *path = (char *)argp;
int last_trail = -1;
int i;
if (path)
{
for (i = 0; path[i]; i++)
{
if (path[i] == '/')
last_trail = i;
}
}
if (last_trail >= 0)
path[last_trail] = 0;
sceIoChdir(path);
path[last_trail] = '/';
EDIT: OK..Just understood that your freeing all the user memory and loading vshmain_real.prx from a kernel prx so that all memory is available to vshmain on startup.
Code: Select all
static int end_thread(SceSize args, void *argp)
{
sceKernelStopModule(vlf_mod, 0, NULL, NULL, NULL);
sceKernelUnloadModule(vlf_mod);
sceKernelStopModule(if_mod, 0, NULL, NULL, NULL);
sceKernelUnloadModule(if_mod);
// From here, you cannot use LIBC!
SceUID mod = sceKernelLoadModule("ms0:/seplugins/vsh_loader.prx", 0, NULL);
sceKernelStartModule(mod, MODNAME_LENGTH+1, MODNAME, NULL, NULL);
return sceKernelExitDeleteThread(0);
}
And I still don't understand what is LIBC T_T
Last edited by Torch on Wed Oct 01, 2008 2:59 pm, edited 1 time in total.