Thanks for your replies. I'll try the grabimage tip, looks like the best way to achieve it.
LarsG :
Your function is great and will turn out useful but what i was looking for was basically to copy a sprite onto an image. As far as I know, it's not possible to make a call for displaysprite and have ...
Search found 13 matches
- Mon Feb 09, 2004 6:38 pm
- Forum: Coding Questions
- Topic: How to copy a (clipped) sprite on an image ?
- Replies: 4
- Views: 1823
- Mon Feb 09, 2004 12:28 pm
- Forum: Coding Questions
- Topic: How to copy a (clipped) sprite on an image ?
- Replies: 4
- Views: 1823
How to copy a (clipped) sprite on an image ?
Hello everyone,
My problem is the following :
I've got a sprite loaded. Basically, it's a tileset which i need to clip from to display a specific tile.
My problem is that i need to put that clipped part of the sprite tileset into an image (i'm working on a map editor and i can't display sprites in ...
My problem is the following :
I've got a sprite loaded. Basically, it's a tileset which i need to clip from to display a specific tile.
My problem is that i need to put that clipped part of the sprite tileset into an image (i'm working on a map editor and i can't display sprites in ...
- Wed Jan 28, 2004 10:13 pm
- Forum: Coding Questions
- Topic: Resize a 2D sprite ?
- Replies: 3
- Views: 1461
- Wed Jan 28, 2004 5:33 pm
- Forum: Coding Questions
- Topic: Resize a 2D sprite ?
- Replies: 3
- Views: 1461
Resize a 2D sprite ?
Hi,
I need to resize (in fact scale) a 2D sprite. I know there's a way to do it by using the Sprite3D functions but using 3d functions causes a big slowdown (at least on my computer) so i want to know if anyone has come up with a way that uses only 2D commands ?
thanks in advance,
pythagoras
I need to resize (in fact scale) a 2D sprite. I know there's a way to do it by using the Sprite3D functions but using 3d functions causes a big slowdown (at least on my computer) so i want to know if anyone has come up with a way that uses only 2D commands ?
thanks in advance,
pythagoras
- Fri Jan 16, 2004 8:11 pm
- Forum: Coding Questions
- Topic: A question for C/C++ coders
- Replies: 7
- Views: 2303
- Fri Jan 16, 2004 5:23 pm
- Forum: Coding Questions
- Topic: A question for C/C++ coders
- Replies: 7
- Views: 2303
A question for C/C++ coders
Hi,
I'm converting some C++ code to PB and, even though i have a little knowledge of C/C++, i have a doubt on the following lines :
Stack[StackTop++]=PrevPixel;
Does it mean that the variable StackTop is actually incremented by 1 or does it only refer to the value StackTop + 1 ?
If the variable ...
I'm converting some C++ code to PB and, even though i have a little knowledge of C/C++, i have a doubt on the following lines :
Stack[StackTop++]=PrevPixel;
Does it mean that the variable StackTop is actually incremented by 1 or does it only refer to the value StackTop + 1 ?
If the variable ...
- Thu Oct 30, 2003 1:10 am
- Forum: Coding Questions
- Topic: using z-lib from PB (example needed)
- Replies: 2
- Views: 1752
Thanks for your reply but i've already looked at the PBZip library which is great but doesn't really suit my needs as i'm reading from a big data file which isn't a canonical zip file. This means i can only work with memory buffers that i fill by reading inside the data file. Correct me if i'm wrong ...
- Wed Oct 29, 2003 10:44 pm
- Forum: Coding Questions
- Topic: using z-lib from PB (example needed)
- Replies: 2
- Views: 1752
using z-lib from PB (example needed)
Hello everyone,
I'm trying to use z-lib decompression functions from my PB app but i've got problems figuring out how to correctly call the functions contained in zlib.dll.
My problem is that i need to pass a zstream object as a parameter to the zlib inflate() function. How could this zstream ...
I'm trying to use z-lib decompression functions from my PB app but i've got problems figuring out how to correctly call the functions contained in zlib.dll.
My problem is that i need to pass a zstream object as a parameter to the zlib inflate() function. How could this zstream ...
- Wed Oct 08, 2003 1:56 pm
- Forum: Game Programming
- Topic: sprite outline
- Replies: 0
- Views: 1521
sprite outline
Here is a procedure i wrote to create an outline for a sprite. It can be useful for example if you want to highlight a selected sprite object. The idea is to scan the sprite in four directions (left to right, right to left, top to bottom, bottom to top) and to write a specified outline color at the ...
- Thu Oct 02, 2003 11:44 am
- Forum: Coding Questions
- Topic: How to read a pixel's color on a sprite ?
- Replies: 2
- Views: 1111
- Thu Oct 02, 2003 10:21 am
- Forum: Coding Questions
- Topic: How to read a pixel's color on a sprite ?
- Replies: 2
- Views: 1111
How to read a pixel's color on a sprite ?
Greetings,
I've been trying to retrieve the color of a pixel on a sprite by using GetPixel_(hdc,x,y) but to no avail. I guess the problem is to get the correct dc for the sprite. This is what i've been doing (wrong, probably) :
hDC = GetDC_(sprite_id)
color = GetPixel_(hDC,50,30)
Does someone ...
I've been trying to retrieve the color of a pixel on a sprite by using GetPixel_(hdc,x,y) but to no avail. I guess the problem is to get the correct dc for the sprite. This is what i've been doing (wrong, probably) :
hDC = GetDC_(sprite_id)
color = GetPixel_(hDC,50,30)
Does someone ...
- Mon Aug 25, 2003 8:59 pm
- Forum: Coding Questions
- Topic: how to get big endian / motorola value of word ?
- Replies: 2
- Views: 1306
how to get big endian / motorola value of word ?
Greetings everyone,
My problem is as follows : i'm trying to convert a word variable to its big endian / Motorola value. I've been using this function (found on this forum :wink: ) :
Procedure PeekWMotorola(address.l)
; address of value in Motorola format -> value in Intel format
b1.l ...
My problem is as follows : i'm trying to convert a word variable to its big endian / Motorola value. I've been using this function (found on this forum :wink: ) :
Procedure PeekWMotorola(address.l)
; address of value in Motorola format -> value in Intel format
b1.l ...
- Wed Aug 20, 2003 11:13 am
- Forum: Coding Questions
- Topic: maximum size of arrays ?
- Replies: 9
- Views: 3415
maximum size of arrays ?
Greetings,
I've been trying to create two big arrays in a structure and i get an error message while compiling. I'm wondering if there is a maximum limit to arrays in terms of size. This is my code :
Structure MAP
maphdr.MAPHEADER
roofTile.w[10000]
floorTile.w[10000]
EndStructure
If I only ...
I've been trying to create two big arrays in a structure and i get an error message while compiling. I'm wondering if there is a maximum limit to arrays in terms of size. This is my code :
Structure MAP
maphdr.MAPHEADER
roofTile.w[10000]
floorTile.w[10000]
EndStructure
If I only ...