2010-10-26 12:01:41 +00:00
|
|
|
#include <nall/platform.hpp>
|
|
|
|
#include <nall/stdint.hpp>
|
|
|
|
using namespace nall;
|
|
|
|
|
|
|
|
extern "C" {
|
|
|
|
void filter_size(unsigned&, unsigned&);
|
Update to v083r09 release.
byuu says:
Added frequency, latency, resampler selection to the audio settings
panel (I really only wanted it there for resampler selection ... having
three options matches the driver selection style though, so whatever.)
The linear/hermite sampler will double the framerate when running Game
Boy games, and sounds the same. Same framerate and sound quality on
SNES. But it will cause buzzing in many NES titles.
Also re-added the composition { never, fullscreen, always } modes.
I think that option is clutter, but it's just impossible to get good
audio+video on Windows 7 without it ...
Lastly, HQ2x was ported over, but not very well. I just convert source
pixels from RGB888 to RGB555, and output pixels in the opposite
direction.
Need someone good to port the diff() and blend functions over to RGB888
in a way that's not terribly slow.
2011-10-31 09:55:48 +00:00
|
|
|
void filter_render(uint32_t*, unsigned, const uint32_t*, unsigned, unsigned, unsigned);
|
2010-10-26 12:01:41 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
dllexport void filter_size(unsigned &width, unsigned &height) {
|
|
|
|
height *= 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
dllexport void filter_render(
|
Update to v083r09 release.
byuu says:
Added frequency, latency, resampler selection to the audio settings
panel (I really only wanted it there for resampler selection ... having
three options matches the driver selection style though, so whatever.)
The linear/hermite sampler will double the framerate when running Game
Boy games, and sounds the same. Same framerate and sound quality on
SNES. But it will cause buzzing in many NES titles.
Also re-added the composition { never, fullscreen, always } modes.
I think that option is clutter, but it's just impossible to get good
audio+video on Windows 7 without it ...
Lastly, HQ2x was ported over, but not very well. I just convert source
pixels from RGB888 to RGB555, and output pixels in the opposite
direction.
Need someone good to port the diff() and blend functions over to RGB888
in a way that's not terribly slow.
2011-10-31 09:55:48 +00:00
|
|
|
uint32_t *output, unsigned outputPitch,
|
|
|
|
const uint32_t *input, unsigned inputPitch,
|
2011-09-22 00:03:11 +00:00
|
|
|
unsigned width, unsigned height
|
2010-10-26 12:01:41 +00:00
|
|
|
) {
|
Update to v083r09 release.
byuu says:
Added frequency, latency, resampler selection to the audio settings
panel (I really only wanted it there for resampler selection ... having
three options matches the driver selection style though, so whatever.)
The linear/hermite sampler will double the framerate when running Game
Boy games, and sounds the same. Same framerate and sound quality on
SNES. But it will cause buzzing in many NES titles.
Also re-added the composition { never, fullscreen, always } modes.
I think that option is clutter, but it's just impossible to get good
audio+video on Windows 7 without it ...
Lastly, HQ2x was ported over, but not very well. I just convert source
pixels from RGB888 to RGB555, and output pixels in the opposite
direction.
Need someone good to port the diff() and blend functions over to RGB888
in a way that's not terribly slow.
2011-10-31 09:55:48 +00:00
|
|
|
outputPitch >>= 2, inputPitch >>= 2;
|
2010-10-26 12:01:41 +00:00
|
|
|
|
2011-09-22 00:03:11 +00:00
|
|
|
#pragma omp parallel for
|
2010-10-26 12:01:41 +00:00
|
|
|
for(unsigned y = 0; y < height; y++) {
|
Update to v083r09 release.
byuu says:
Added frequency, latency, resampler selection to the audio settings
panel (I really only wanted it there for resampler selection ... having
three options matches the driver selection style though, so whatever.)
The linear/hermite sampler will double the framerate when running Game
Boy games, and sounds the same. Same framerate and sound quality on
SNES. But it will cause buzzing in many NES titles.
Also re-added the composition { never, fullscreen, always } modes.
I think that option is clutter, but it's just impossible to get good
audio+video on Windows 7 without it ...
Lastly, HQ2x was ported over, but not very well. I just convert source
pixels from RGB888 to RGB555, and output pixels in the opposite
direction.
Need someone good to port the diff() and blend functions over to RGB888
in a way that's not terribly slow.
2011-10-31 09:55:48 +00:00
|
|
|
const uint32_t *in = input + y * inputPitch;
|
|
|
|
uint32_t *out0 = output + y * outputPitch * 2;
|
|
|
|
uint32_t *out1 = output + y * outputPitch * 2 + outputPitch;
|
2010-10-26 12:01:41 +00:00
|
|
|
|
|
|
|
for(unsigned x = 0; x < width; x++) {
|
2011-09-22 00:03:11 +00:00
|
|
|
*out0++ = *in++;
|
|
|
|
*out1++ = 0;
|
2010-10-26 12:01:41 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|