summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2018-06-06Add versioningHEADmasterLeo (Sunpeng) Li2-3/+16
2018-06-06Change name of executable to cmdemoLeo (Sunpeng) Li3-4/+4
`demo` is too vague.
2018-05-31Use 32-bit format for CTMLeo (Sunpeng) Li1-9/+31
Using 32-bits isn't the best, but it better represents the S31.32 format than 16-bit. 64-bit is desired, since each CTM element is S31.32 format, but there's no xserver support for it. We can use the first 32 bits to represent the S31 signed- magnitude whole component, and the second 32 bits to represent the fractional component. See the comments in set_ctm() for details. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-31Add randr format enumLeo (Sunpeng) Li1-13/+23
For use when setting randr property blobs. This is sort of a revert of: 908098f30 Hardcode 16 bit format into set_output_blob() This is done in preparation of using 32-bit format for CTM. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-11Remove libdrm includesLeo (Sunpeng) Li1-9/+7
We really shouldn't be dependant on libdrm anyways. Also switch linux int types to C standard int types. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-11Revert "Use DRM's color LUT/CTM structs"Leo (Sunpeng) Li1-6/+24
We can get rid of xf86drm.h includes. It's a better way of showing that we don't depend on libdrm anymore. This reverts commit 88cb2a6ec6d4b39349c68ecd5057750d99305bdd.
2018-05-11Remove code that opens DRM file descriptorLeo (Sunpeng) Li1-63/+11
With the 2nd revision of the interface, we do not need to open the DRM fd. We were previously using it to create a DRM blob, but thats not necessary anymore. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-10Hardcode 16 bit format into set_output_blob()Leo (Sunpeng) Li1-9/+19
All blob properties are currently using 16 bits, due to some issues with the RandR extension. Just hard-code it for now, for clarity. Add some comments explaining that as well. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Use DRM's color LUT/CTM structsLeo (Sunpeng) Li1-24/+6
They're already included via xf86drm.h Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Stop managing DRM blobs, the DDX driver manages that nowLeo (Sunpeng) Li2-55/+27
The DDX driver manages creation of DRM blobs. We just pass a pointer to an array containing the LUT/CTM data. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Update docstring for set_gamma()Leo (Sunpeng) Li1-0/+2
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Ensure display is openedLeo (Sunpeng) Li1-1/+7
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Clarify help string a bit for regammaLeo (Sunpeng) Li1-4/+7
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Fix main() return values.Leo (Sunpeng) Li1-4/+5
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Add output option, modify help text accordingly.Leo (Sunpeng) Li2-4/+19
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Move help string to file, and include via preprocessor.Leo (Sunpeng) Li4-66/+87
Modify makefile to do so. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Update comments in main()Leo (Sunpeng) Li2-6/+19
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Convert to using libxrandr for changing propertiesLeo (Sunpeng) Li1-41/+72
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Define macros for property namesLeo (Sunpeng) Li1-3/+7
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Open X display via X librariesLeo (Sunpeng) Li2-12/+58
And also get screen resources using libxrandr library. Use it to open a hard-coded DisplayPort-0 output for now. Add headers and update makefile. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Add help messagesLeo (Sunpeng) Li1-4/+72
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Remove unused build dir.Leo (Sunpeng) Li1-2/+0
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Build to root dir instead.Leo (Sunpeng) Li2-4/+5
The build dir was suppose to contain any compiled objects for easy gitignoring. However, only we only ended up with one executable. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Implemented demo app for degamma, ctm, and regamma.Leo (Sunpeng) Li1-74/+434
The app currently uses a system call to xrandr to set the blob IDs. Ideally, we should include libxrandr, and use the library to do so instead. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Build everything in build dir, and ignore it.Leo (Sunpeng) Li2-3/+11
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Shorten file nameLeo (Sunpeng) Li1-0/+0
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Add code to create, get, and destroy property blobsLeo (Sunpeng) Li2-9/+95
And fix makefile. Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Remove executable from trackingLeo (Sunpeng) Li1-0/+0
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Adding makefile, Init app .c file.Leo (Sunpeng) Li3-0/+142
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
2018-05-02Init commitLeo (Sunpeng) Li1-0/+44
Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>