@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info


Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4 5 6



Comments:

<_pusher_> well i use .rc forms
<ki9a> oh
<ki9a> that's safe
<_pusher_> ah nice :)
<ki9a> nobody uses those.
<_pusher_> i like using them... makes small code too
<_pusher_> alot more work tho..
<Laserbeak> do all compilers convert you code into ***embler?
<_pusher_> the good ones do
<_pusher_> inlining you mean ?
<Laserbeak> i guess
<Laserbeak> lol
<Laserbeak> i'm not the most verbose in programming lingo\
<Rahly> http://www.qdb.us/62085
<_pusher_> asm begin end end; << inline
<Rahly> that works? doesn't for me
<_pusher_> heh
<Rahly> perhaps you mean begin asm end end;
<_pusher_> begin asm xor eax, eax end; end;
<Rahly> but you can shorten that to just asm end;
<ki9a> pretty useless if you ask me.
<Laserbeak> heh interesting
<Rahly> very ki9a
<_pusher_> depends..
<Rahly> no
<Rahly> doesn't depend
<Rahly> EAX is the junk register
<_pusher_> the main code are in inline even :/
<_pusher_> oh the code example you mean ?
<Laserbeak> so can i write asm directly in delphi by adding that and if so is there a specific language that delphi already includes or i need to specify what asm language im using?
<_pusher_> sure
<Rahly> Laserbeak: since delphi compiles to only 2 asms, i think those are your options
<_pusher_> try asm pop esp end; except end;
<Rahly> but i don't think delphi lets you asm MSIL
<Rahly> so i think you are stuck with only that asm
<Laserbeak> oh...
<Laserbeak> well gotta go the old lady is forcing me totake a shower so we can go school shopping for the little ones
<Laserbeak> laters
<_pusher_> yeah.. inlining direct .asm file doest work very well because of the esp ebp registers
<Rahly> yeah
<Rahly> take a shower, thats a GOOD thing
<_pusher_> i use asm INT 3 end; to debug exactly where iam :)
<_pusher_> works pretty good.. i dont understand much of the debugger that came with delphi..
<Rahly> why? when you can just put in a breakpoint ?
<Rahly> and then step through it
<_pusher_> still.. the debugger doest give me much :(
<Rahly> why not?
<_pusher_> Ollydbg is very helpfull
<ddh> i like that it optimizes all the variables away for me, so i get to guess what they contain :D
<Rahly> mouse over the variables, and it gives it to you
<Rahly> Olly allows breakpoints as well
<_pusher_> yeah :)
<Rahly> perhaps you don't know how to use Olly either
<_pusher_> eh ?
<Rahly> i only use olly when i don't have source ;-)
<_pusher_> heh ;)
<Rahly> bye vibes
<Kn00n> is there any reason for CreateIconIndirect to fail with 48x48 bitmaps? I've checked the lasterror text which says there's not enough memory to perform it, though 684 MB free should be enough imo ;).... Anything wrong with that API since 32x32 bitmap is converted with no problems
<NeWbY> uhm
<NeWbY> im not a delphi programmer but a c++ one and i was wondering if anyone could tell me what the equal to c++ of the following line is
<NeWbY> aEncr : array [0..1] of Byte absolute wEncrSize;
<NeWbY> wEncrSize = int
<Laserbeak> wEncrSize? that a function u made urself?
<NeWbY> uhm
<NeWbY> i dont know what absolute does
<NeWbY> or is
<NeWbY> im guessing aEncr is a char[3];
<NeWbY> cause byte = char
<NeWbY> but i dont know what absolute is/does
<Laserbeak> sorry but we need to trade names cause you completely lost me
<NeWbY> well
<NeWbY> what does that line do, in c++ language
<NeWbY> im trying to recode a program made in delphi to c++
<NeWbY> but im stuck @ that line
<Laserbeak> i dunno in anylanguage
<Laserbeak> but it looks like it cycles through an array
<Laserbeak> i dunno how or why tho
<NeWbY> what makes you think it cycles
<Rahly> NeWbY: not sure if C++ does
<Rahly> you could create the equiv though
<TByte> aaaaaatiishuuuuuu
<Rahly> char[2] aEncr; wEncrSize: ^Word;
<Rahly> errr
<Rahly> char[2] aEncr; short *wEncrSize;
<Rahly> egads
<Rahly> Cyan on White, who the hell thought of that scheme
<Kn00n> Rahly, you shouldn't have any idea why CreateIconIndirect can't handle 48x48 bitmaps?
<Rahly> because its ment to handle Icons?
<Kn00n> http://kn00n.dk/delphi/cidbug.txt
<Kn00n> I'm splitting a png into X images based on Height*Height
<Kn00n> it works fine with 16x16 and 32x32
<Kn00n> but with 48x48
<Kn00n> an error occures with CreateIconIndirect
<Kn00n> causing invalid pointer operation due to the HICON being NULL
<Kn00n> I've just made a dup of the normal PngToIcon function
<Kn00n> so PngToIconEx can split
<Rahly> what are you using?
<Rahly> TIconInfo ?
<Kn00n> yes
<Kn00n> it's all in the .txt
<Kn00n> happens with PngToIcon32 and PngToIcon24
<Kn00n> so it's not only the alpha bitmap
<Kn00n> the png is 384x48 and is splitted into 8 * 48x48
<Kn00n> it does split it right, but the createiconindirect is a problem
<Kn00n> I'm using that to do xp alpha icons
<Kn00n> and PngToIcon24 for older systems
<Rahly> doesn't xp already have that?
<Kn00n> delphi imagelist doesn't support 32 bit icons
<Kn00n> therefore I'm using PNG
<Kn00n> it does the alpha right now, but 48x48 makes it crash
<Kn00n> since the API fails for some reason
<Kn00n> I don't know why it does
<Rahly> did you check the error code?
<Kn00n> only the text... not enough memory
<Kn00n> 684 MB free memory
<Kn00n> so strange error
<Rahly> GetLastError() returns not enough memory?
<Kn00n> yes
<Kn00n> when using FormatMessage
<Rahly> you use that?
<Rahly> oh wow
<Kn00n> I can't find anything about limits for CreateIconIndirect
<Kn00n> so it's a bit strange
<Kn00n> and I can't think that it's the code since jumping from 16x16 to 32x32 works
<Kn00n> but not 32x32 to 48x48
<Kn00n> or wait
<Kn00n> seems like there is a bug somewhere
<Kn00n> Rahly, can you find any bugs in the .txt?
<Kn00n> just got errors with 16x16
<hundreAd_> if i do something like "with TBitmap.Create do try ... finally Free; end", is there a way to refer to the created bitmap within the try ... finally block (e.g., p*** it to a routine requiring a TBitmap parameter)?
<Mephisto> no
<Mephisto> just use a variable
<Rahly> Kn00n: didn't look, was at the store, just got back
<Rahly> i don't have a 48x48 to test
<Kn00n> well
<Kn00n> it seems like CreateIconIndirect
<Kn00n> creates 32x32
<Kn00n> no matter what
<Kn00n> 2006-08-24 00:47:09 128x16
<Kn00n> 2006-08-24 00:47:11 32x32
<Kn00n> 128x16 = png size
<Kn00n> 32x32 = TIcon.Width x TIcon.Height
<Kn00n> very strange
<Mephisto> the function probably depends on the system settings
<Rahly> you could always draw the icon yourself
<Kn00n> it's just weird that it forces size to be 32x32
<Kn00n> when the bitmap is 16x16
<Rahly> you are prolly doing something wrong
<Kn00n> Rahly
<Kn00n> http://kn00n.dk/delphi/alphabug/
<Kn00n> the toolbar has alpha now so don't get confused by the black bg


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #delphi
or
Go to some related logs:

#worldcup
#computers
#stocks
#visualbasic
Malaysia kwalalambor
#politics
#nhl
#linuxhelp
#cph
#hardware



Home  |  disclaimer  |  contact  |  submit quotes