Dark Bit Factory & Gravity

GENERAL => Challenges & Competitions => Topic started by: pjay274 on September 29, 2008

Title: [Remakes] Vroom Cracktro
Post by: pjay274 on September 29, 2008
Hi guys, i've been working on my first ever remake for the current compo and i'm wondering how you experts are emulating the old Amiga gradient text (copperbars).

At the moment i'm using OpenGL with a stencil buffer, drawing the text & then drawing a copperbar texture over it.  This was all fine and dandy until I tried running it on my other (old) PC & the stencil function didn't work in that you'd get the gradient boxes rather than the text.

Concerned now that'll only look how I wanted it to on my own machine....

Title: [Remakes] Vroom Cracktro
Post by: stormbringer on September 29, 2008
@pjay274: excellent stuff!! except that the stencil buffer does not work on my laptop either!! don't worry about it as the solution to this problem would be simply to render your bob scroll into a RGBA 8bit buffer in memory and then update the texture of the scroll area and display (continuously).

There are really no stable ways to do this with the stencil buffer in OpenGL (you could do it with shaders, but you really do not need shaders here) .... except one way in this case.... that would be to draw your characters by horizontal slices and shade each of the slices by the color that is supposed to be in the gradient (rasters).

Once you have the characters stored as textures, drawing each character with multiple slices (quads with a width of the with of your characters and a height of 1, and of course scaled by a factor of 2 to match the 640x480 resolution).

I hope this helps.. if not let me know..
Title: [Remakes] Vroom Cracktro
Post by: Shockwave on September 30, 2008
Thats a really faithful conversion right there Pjay. If there was not a potential compatibility problem I think it would make the grade already, the only very slight inconsistency I can spot against the original is that the letters squashed a little more in the original and squashed slightly faster, but that's minor critique. It's a fine job that you can be proud of :)

Nice choice.
Title: [Remakes] Vroom Cracktro
Post by: Clyde on September 30, 2008
The screenshot looks cool Pjay, havent seen the orginal before. However I only see the copper colours as a block on my Desktop PC running Vista.
Title: [Remakes] Vroom Cracktro
Post by: stormbringer on September 30, 2008
@Clyde: yop it's the problem mentioned before with the stencil buffer not being supported by all gfxcards. I hope pjay274 fixes this using the hints I gave him, because this intro is really cooland well known.It deserves a nice remake
Title: [Remakes] Vroom Cracktro
Post by: pjay274 on September 30, 2008
Cheers for the advice, I think i've fixed an incompatability or two...... the text is visible on my old pc now & it grows & shrinks a little better (stopped it from scaling the top / bottom 2 pixels of the font).



Title: [Remakes] Vroom Cracktro
Post by: hellsangel on September 30, 2008
that works now. great !
a new little bug on the top message box : the text is "underlined" now. see screenshot

like my last remake before I fix it, this one is cpu consumer (25%).
Title: [Remakes] Vroom Cracktro
Post by: stormbringer on September 30, 2008
fantastic here! just missing a full screen mode, but besides that everything runs very fine

well done!
Title: [Remakes] Vroom Cracktro
Post by: benny! on October 01, 2008
Screeny looks good.

But have a look at attached screenshot - that's how it looks
on my laptop. The movement and music runs stable and smooth
though.
Title: [Remakes] Vroom Cracktro
Post by: stormbringer on October 01, 2008
oops...

@pjay274: I did not look into your code, but maybe you should make sure to not use any rectangular textures, only 1D and 2D would be supported by all the gfx cards. Also make sure you set the texture parameters after you bind the textures. I know that normally it should not be necessary, but on some gfx cards/drivers, you have to. So basically when you draw your stuff on screen, make sure that:

1) you properly enable the appropriate texture mode (1D/2D)
2) set the blending parameters
3) set the filtering parameters
4) turn off lighting & depth
etc..

OpenGL is a state machine, you normall if you turn off the lighting once, the should be kept all the way through the intro, until you change it. However, I observed that some drivers do not respect that and the OpenGL context is reset at every draw.. so just make sure you set these things properly before you draw, just in case.

Maybe it's also just an problem with benny!'s laptop... I'll test on more machines today and let you know..
Title: [Remakes] Vroom Cracktro
Post by: stormbringer on October 01, 2008
@pjay274: maybe you should post your remake in an appropriate thread, not to hijack this one. Have a look at how Shockwave did it. It will help people to post comments for your remake and sillsimplify voting, etc.
Title: Re: [Remakes] Vroom Cracktro
Post by: Shockwave on October 01, 2008
[Topic Split ~ SW]
Title: Re: [Remakes] Vroom Cracktro
Post by: benny! on October 01, 2008
....

Maybe it's also just an problem with benny!'s laptop... I'll test on more machines today
and let you know..

As I posted in several other threads - my laptop is definately not good for viewing demos.

It is a Sony Vaio CR21S notebook with Mobile Intel Graphics Media Accelerator X3100
as a graphic card.

On the other hand - nearly all productions by Shockwave run perfectly smooth on it. Although
it crashes sometimes in fullscreen mode - whereas the windows version works nearly fine all the
time.

In general, it should be fine enough to show standard OpenGL/DirectX stuff which are not
using any shaders and stuff. E.g. my p1nKpong (http://www.pouet.net/prod.php?which=49272) game works without any problems in
fullscreen mode.
Title: Re: [Remakes] Vroom Cracktro
Post by: Clyde on October 01, 2008
Just to let you know dude, that all I get on my machine ( see signature for system spec ) is the Vroom graphic and some blue bubble bobs, and the cractro coloured lines at the top an bottom. No scroller, and it runs very slow.
Title: Re: [Remakes] Vroom Cracktro
Post by: pjay274 on October 01, 2008
Riiighht... third time lucky?  :-[

Re-scaled to 640x480, made textures a maximum of 256 pixels wide (which fixed the issues on a mates laptop), reduced cpu usage & added a full-screen mode.

These things aren't as easy to program as they first appear :) but i suppose once you've got a working one out of the way then you have a good framework to build on for future remakes.

Thanks for all the advice & bug reports guys.
Title: Re: [Remakes] Vroom Cracktro
Post by: Clyde on October 01, 2008
Now that is stunning, awesome work there dude, and welldone. Runs very nice indeed.
For some reason on start up I get a completely white screen.

Cheers and all the best with the Judging & voting,
Clyde.
Title: Re: [Remakes] Vroom Cracktro
Post by: stormbringer on October 01, 2008
now this is a serious candidate! excellent job!!!
Title: Re: [Remakes] Vroom Cracktro
Post by: hellsangel on October 01, 2008
 :clap: wouaou
works fine. and cpu from 25% to 1% !  :xmas:
Title: Re: [Remakes] Vroom Cracktro
Post by: benny! on October 01, 2008
Awesome ... works very good and smooth and scroller is now correct.
Thanks for bugfixing. Great entry  :clap:
Title: Re: [Remakes] Vroom Cracktro
Post by: Shockwave on October 02, 2008
Works great now! :)

This can be added to Retro Remakes archive afaic.

Great job and good luck in the voting.
Title: Re: [Remakes] Vroom Cracktro
Post by: Shockwave on October 02, 2008
Added:
http://www.retro-remakes.net/viewproduction.php?prod=2a276c54a91409f938e4d0d511650aee272cd995 (http://www.retro-remakes.net/viewproduction.php?prod=2a276c54a91409f938e4d0d511650aee272cd995)
Title: Re: [Remakes] Vroom Cracktro
Post by: stormbringer on October 02, 2008
yes, this remake is really well done! it definitely deserves to be selected.

@pjay274: I hope you will release more is the very near future ;)
Title: Re: [Remakes] Vroom Cracktro
Post by: StatMat on October 02, 2008
This is indeed an excellent remake, very well done pjay274. Brings back lots of memories of firing up that release of Vroom for the first time. And of course, the game wasn't a disappointment either. It gave a good sense of speed! ;)
Title: Re: [Remakes] Vroom Cracktro
Post by: Hotshot on October 06, 2008
Excellent Demo and Good Music to Boot!  ;)
Title: Re: [Remakes] Vroom Cracktro
Post by: gooner on October 06, 2008
Excellent stuff love the rainbow scroller and the music is wicked :clap:
Title: Re: [Remakes] Vroom Cracktro
Post by: Xalthorn on October 21, 2008
Ooh,

Vibrant, smooth, slick, very very nice :D
Title: Re: [Remakes] Vroom Cracktro
Post by: Praecor on October 27, 2008
So wonderful and colourful remake. Very refreshing music, very!
Glad you got all the technical problems with stencil and texture-sizes out of the way!  :cheers:
Title: Re: [Remakes] Vroom Cracktro
Post by: Pixel_Outlaw on October 27, 2008
This is a neat entry and runs well on my Vista Home Basic operating system. Great Job!