[Gambas-user] gb3: recent changes to PaintImage and DrawImage

Kevin Fishburne kevinfishburne at ...1887...
Sun May 1 04:19:41 CEST 2011


On 04/30/2011 09:55 PM, Benoît Minisini wrote:
>> On 04/30/2011 09:19 PM, Kevin Fishburne wrote:
>>
>> Something like:
>>
>> If TargetWidth = SourceWidth And TargetHeight = SourceHeight Then
>>     Do_Not_Use_Scaling_Blit_Algorithm
>> Else
>> Use_Scaling_Blit_Algorithm
>> EndIf
>>
>> But in C. :) Some day I'm going to learn C, dammit. Everything I know
>> tells me so.
>
> As you use gb.image.imlib, you are directly using the imlib painting function,
> that takes all the arguments as is and does its stuff.
>
> I would be surprised if that function didn't do the check.
>

I could test that, actually.

> Before learning C, look at OpenGL to see how you can have a fast rotate and
> blit function. (But for DrawAlpha, I don't know if it possible to do it with
> OpenGL, I have no idea.)

When I do learn C it will be applied directly to GAMBAS. I have no 
reason to believe that programming a game should require the use of C. 
Highly granular languages close to the architecture are the foundation 
of all programming, but the closer you get to the architecture the 
closer you get to not completing your project without having a lot of 
resources. If, for example, I tried to program my game in C (and to a 
lesser extent OpenGL), it would probably be finished in four years. With 
GAMBAS I should have it finished in two. Ultimately, finishing it at all 
is the most important thing, which is why I chose GAMBAS in the first 
place; I knew I'd have the best chance of actually finishing it.

Learning OpenGL is a good idea, but it would only be done in the context 
of figuring out how to add functionality to gb.sdl. The most beautiful 
and long-standing buildings in history have been created with the 
simplest of tools. I don't need to render a single polygon, so in theory 
simple tools should be more than adequate. GAMBAS is right for the task, 
just a little rough around the edges because I don't think a lot of 
people use it for high-speed image processing.

Now if someone could make an open standards compliant VM environment so 
GAMBAS apps could be executed in a browser, we'd be in business! GAMBAS 
programs for Android, etc., would be the envy of every programmer. When 
gb3 is released, maybe a future milestone on the path to world domination?

-- 
Kevin Fishburne
Eight Virtues
www: http://sales.eightvirtues.com
e-mail: sales at ...1887...
phone: (770) 853-6271





More information about the User mailing list