GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
load_image(3) Arcan Lua API load_image(3)

load_image - synchronously load supported images

VID, fail:BADID
load_image( resource, startzv, desired width, desired height )

Sets up a new video object container and attempts to load and decode an image from the specified resource.

1
The new VID has its opacity set to 0 (hidden)
2
This routine is synchronous, so it will block until the image has been loaded
3
desired width/desired height are capped to the engine compile-time values CONST_MAX_SURFACEW , CONST_MAX_SURFACEH (2048x2048)
4
If the engine is running in conservative mode, no local copy will be kept in memory and the resource will be reloaded on every operation that manipulates the current rendering context (e.g. stack push / pop or launch_target(external).
5
supported file formats vary with platform and engine build, only ones that are guaranteed to work are PNG and JPEG .

function load_image0()
      vid = load_image("test.png");
      show_image(vid);
      vid2 = load_image("test.png", 2, 48, 48);
      show_image(vid);
end

function load_image0()
      vid = load_image();
end

function load_image1()
      vid = load_image("test.png", -1, -1, -1);
end

load_image_asynch(3)

June 2022 image

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.