"#version 430\n"
"layout(location=0) out vec4 color;\n"
"uniform sampler2D tex;\n"
- "const int MAX = 1024;\n"
+ "const int MAX = " SS(MAX_FEATHER) "+1;\n"
"uniform float psf[MAX];\n"
"uniform int n;\n"
"uniform vec2 dxy;\n"
// command->frame->get_w(),
// command->frame->get_h(),
// command->frame->get_color_model());
-// With NVidia at least,
+#ifdef GLx4
+// With NVidia at least
if(w % 4)
{
printf("Playback3D::copy_from_sync: w=%d not supported because it is not divisible by 4.\n", w);
}
else
+#endif
// Copy to texture
if(command->want_texture)
{
if(!command->is_cleared)
{
// If we get here, the virtual console was not used.
- color_frame(command, 0,0,0,0);
+ int color = command->canvas->get_clear_color();
+ int r = (color>>16) & 0xff; // always rgb
+ int g = (color>>8) & 0xff;
+ int b = (color>>0) & 0xff;
+ color_frame(command, r/255.f, g/255.f, b/255.f, 0.f);
}
// Texture
// Using pbuffer for refresh frame.
if( command->frame ) {
command->frame->enable_opengl();
+ command->frame->set_opengl_state(VFrame::SCREEN);
color = command->frame->get_clear_color();
alpha = command->frame->get_clear_alpha();
int color_model = command->canvas->mwindow->edl->session->color_model;
is_yuv = BC_CModels::is_yuv(color_model);
}
+ else
+ color = command->canvas->get_clear_color();
int a = alpha;
int r = (color>>16) & 0xff;
int g = (color>>8) & 0xff;
if( r ) {
double sig2 = -log(255.0)/(r*r);
int n = abs((int)r) + 1;
- if( n > 1024 ) n = 1024; // MAX
+ if( n > MAX_FEATHER+1 ) n = MAX_FEATHER+1;
float psf[n]; // point spot fn
for( int i=0; i<n; ++i )
psf[i] = exp(i*i * sig2);