|
Home About Us A-Z Index Search * Contact Us Register Login Press ShopThe Open Brand -- Problem Reporting and Interpretations System |
Problem Report 1747 Details
Show help | Quick Search | Submit a Test Suite Support Request | Click here to view your privileges
This page provides all information on Problem Report 1747.
Report 1747 Actions
Problem Report Number 1747 Submitter's Classification Test Suite problem State Resolved Resolution Rejected (REJ) Problem Resolution ID REJ.X.0530 Raised 1970-01-01 08:00 Updated 2003-03-13 08:00 Published null Product Standard Window System Application Interface V2 Certification Program The Open Brand certification program Test Suite VSW version 5.0.0 Test Identification vsw5/tset/Xlib9/ptimg 2 Problem Summary PG4W.00054 This IR claims that the window and image sizes may be different. Problem Text
One reason for this failure is because two different GCs are used in this
test case, only the same GC should be used.
In test case 002(Test.c), there is a line of code:
gc = makegc(display, w);
w is a window type parameter, gc is a GC type parameter, display is a Display
type parameter. Later in function dset(dset.c) gc is reset, using this code:
gc = makegc(disp, d);
And then the testcase operates on the above "gc" instead of the original gc.
The required modification is to change
void dset(Dislay , Drawable , unsigned long );
passing inside a GC type variable:
void dset(Display *disp, GC gc, Drawable d, unsigned long pix);
Another problem with the testcase, is the wrong parameters are passed to the
fourth checkarea function call:
if (checkarea(display, w, &area, W_FG, W_FG, CHECK_ALL) == False ) {
In this situation, the foreground and background of the Display "display" are
both W_BG through XSetState in makegc and XSetForeground in dset, the image
pixel value is 1 before we call XPutImage, so we should expect get an image
from display whose pixel value is W_BG instead of W_FG. The above line code
should be changed to:
if (checkarea(display, w, &area, W_BG, W_BG, CHECK_ALL) == False ) {
A machine dependent error could happen which is the size of the image
scratched from the window for comparing. Here is the code in checkarea
function to create the image for comparing:
im = XGetImage(disp, d, 0, 0, width, height, AllPlanes, ZPixmap);
The "width" and "height" here are local variables, they are defined by this
line of code in checkarea function:
getsize(disp, d, &width, &height);
In getsize function, it calls XGetGeometry() to return width and height and
this is the ONLY line code to do the job:
XGetGeometry(disp, d, &root, &x, &y,
widthp? widthp: &dummy,
heightp? heightp: &dummy, &border, &depth);
The size could be 116*90 or 100*90 which depending on the visual
classes(DirectColor, TrueColor, ...). The variation could be caused by
use of differing window managers. So it is recommended just use
I_STDWIDTH * I_STDHEIGHT instead of getsize(... &width, & height).
Test Output
TEST CASE: XPutImage
TEST PURPOSE #2
Assertion XPutImage-2.(C)
When the image format is XYBitmap, then the foreground
pixel in gc defines the source for the one bits in the
image, and the background pixel defines the source for the
zero bits.
METH: Create depth 1 image in XYBitmap format.
METH: Create drawable.
METH: Set all bits in image to zero.
METH: Set every pixel in drawable to W_FG.
METH: Call XPutImage.
METH: Verify results.
METH: Set every pixel in drawable to W_BG.
METH: Call XPutImage.
METH: Verify results.
METH: Set all bits in image to one.
METH: Set every pixel in drawable to W_FG.
METH: Call XPutImage.
METH: Verify results.
METH: Set every pixel in drawable to W_BG.
METH: Call XPutImage.
METH: Verify results.
METH: Repeat for each visual.
REPORT: Pixel mismatch in image
REPORT: See file Err0000.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0001.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0002.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0003.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0004.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0005.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0006.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0007.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0008.err for details
REPORT: Area was not properly put.
REPORT: Pixel mismatch in image
REPORT: See file Err0009.err for details
REPORT: Area was not properly put.
2 FAIL
Review Information
Review Type TSMA Review Start Date null Completed null Status Complete Review Recommendation No Resolution Given Review Response
We recommend this request be refused.
We believe the test is correct. We find no basis for the window sizes
being different between XPutImage and what is received from the window.
As shown below, all of the window sizes are accounted for. The test
does the following:
image = makeimg() calls
XCreateImage() with
I_STDWIDTH, I_STDHEIGHT, W_BG (100,90,0 from xtest.h)
dsetimg() is called to set W_BG=0 explicitly.
w = makewin() calls
makewinpos() calls
XCreateWindow() with
W_STDWIDTH, W_STDHEIGHT (100,90 from xtest.h)
getgc() sets foreground,background to W_FG,W_BG
dsetimg() image to 0=W_BG
dset() window foreground to W_FG=1
XPutImage image W_BG -> display
checkarea() #1 with W_BG, W_BG
dset() window foreground to W_BG=0
XPugImage image W_BG -> display
checkarea() #2 with W_BG, W_BG
dsetimg() image to 1=W_FG
dset() window foreground to 1=W_FG
XPutImage image W_FG -> display
checkarea() #3 with W_FG, W_FG
dset() window W_BG=0
XPutImage image W_FG -> display
checkarea() #4 with W_FG, W_FG
The checkarea() function should be returning the same height and width
because makewin() creates a window of the same 100x90 size as defined by
the constants in xtest.h.
Based on the sequence of events, 4th checkarea() is correct. The image
is set to W_FG=1, and the display is set to W_BG=0. After the XPutImage,
checkarea() correctly expects W_FG=1.
The test case is not sensitive to the value of pixel 0 and 1 which are
defined to be W_BG nd W_FG respectively in xtest.h The color of the pixels
does not matter. It is the value (0 or 1) that matters.
Review Type SA Review Start Date null Completed null Status Complete Review Resolution Rejected (REJ) Review Conclusion
This request is refused.
Problem Reporting System Options:
- View Report 1747
- List All PRs
- Search Reports
- Email the System Administrator
- View the The Open Brand Interpretations Database User Manual
Contact the Certification Authority